.\" Automatically generated by Pod::Man 2.28 (Pod::Simple 3.28) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is turned on, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{ . if \nF \{ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" .\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2). .\" Fear. Run. Save yourself. No user-serviceable parts. . \" fudge factors for nroff and troff .if n \{\ . ds #H 0 . ds #V .8m . ds #F .3m . ds #[ \f1 . ds #] \fP .\} .if t \{\ . ds #H ((1u-(\\\\n(.fu%2u))*.13m) . ds #V .6m . ds #F 0 . ds #[ \& . ds #] \& .\} . \" simple accents for nroff and troff .if n \{\ . ds ' \& . ds ` \& . ds ^ \& . ds , \& . ds ~ ~ . ds / .\} .if t \{\ . ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u" . ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u' . ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u' . ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u' . ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u' . ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u' .\} . \" troff and (daisy-wheel) nroff accents .ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V' .ds 8 \h'\*(#H'\(*b\h'-\*(#H' .ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#] .ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H' .ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u' .ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#] .ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#] .ds ae a\h'-(\w'a'u*4/10)'e .ds Ae A\h'-(\w'A'u*4/10)'E . \" corrections for vroff .if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u' .if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u' . \" for low resolution devices (crt and lpr) .if \n(.H>23 .if \n(.V>19 \ \{\ . ds : e . ds 8 ss . ds o a . ds d- d\h'-1'\(ga . ds D- D\h'-1'\(hy . ds th \o'bp' . ds Th \o'LP' . ds ae ae . ds Ae AE .\} .rm #[ #] #H #V #F C .\" ======================================================================== .\" .IX Title "EXIMSTATS 8" .TH EXIMSTATS 8 "2018-03-06" "perl v5.20.2" "EXIM4" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" eximstats \- generates statistics from Exim mainlog or syslog files. .SH "SYNOPSIS" .IX Header "SYNOPSIS" .Vb 2 \& eximstats [Output] [Options] mainlog1 mainlog2 ... \& eximstats \-merge [Options] report.1.txt report.2.txt ... > weekly_report.txt .Ve .SS "Output:" .IX Subsection "Output:" .IP "\fB\-txt\fR" 4 .IX Item "-txt" Output the results in plain text to \s-1STDOUT.\s0 .IP "\fB\-txt\fR=\fIfilename\fR" 4 .IX Item "-txt=filename" Output the results in plain text. Filename '\-' for \s-1STDOUT\s0 is accepted. .IP "\fB\-html\fR" 4 .IX Item "-html" Output the results in \s-1HTML\s0 to \s-1STDOUT.\s0 .IP "\fB\-html\fR=\fIfilename\fR" 4 .IX Item "-html=filename" Output the results in \s-1HTML.\s0 Filename '\-' for \s-1STDOUT\s0 is accepted. .IP "\fB\-xls\fR" 4 .IX Item "-xls" Output the results in Excel compatible Format to \s-1STDOUT.\s0 Requires the Spreadsheet::WriteExcel \s-1CPAN\s0 module. .IP "\fB\-xls\fR=\fIfilename\fR" 4 .IX Item "-xls=filename" Output the results in Excel compatible format. Filename '\-' for \s-1STDOUT\s0 is accepted. .SS "Options:" .IX Subsection "Options:" .IP "\fB\-h\fR\fInumber\fR" 4 .IX Item "-hnumber" histogram divisions per hour. The default is 1, and 0 suppresses histograms. Valid values are: .Sp 0, 1, 2, 3, 5, 10, 15, 20, 30 or 60. .IP "\fB\-ne\fR" 4 .IX Item "-ne" Don't display error information. .IP "\fB\-nr\fR" 4 .IX Item "-nr" Don't display relaying information. .IP "\fB\-nr\fR\fI/pattern/\fR" 4 .IX Item "-nr/pattern/" Don't display relaying information that matches. .IP "\fB\-nt\fR" 4 .IX Item "-nt" Don't display transport information. .IP "\fB\-nt\fR\fI/pattern/\fR" 4 .IX Item "-nt/pattern/" Don't display transport information that matches .IP "\fB\-q\fR\fIlist\fR" 4 .IX Item "-qlist" List of times for queuing information single 0 item suppresses. .IP "\fB\-t\fR\fInumber\fR" 4 .IX Item "-tnumber" Display top sources/destinations default is 50, 0 suppresses top listing. .IP "\fB\-tnl\fR" 4 .IX Item "-tnl" Omit local sources/destinations in top listing. .IP "\fB\-t_remote_users\fR" 4 .IX Item "-t_remote_users" Include remote users in the top source/destination listings. .IP "\fB\-include_original_destination\fR" 4 .IX Item "-include_original_destination" Include the original destination email addresses rather than just using the final ones. Useful for finding out which of your mailing lists are receiving mail. .IP "\fB\-show_dt\fR\fIlist\fR" 4 .IX Item "-show_dtlist" Show the delivery times (\fB\s-1DT\s0\fR)for all the messages. .Sp Exim must have been configured to use the +deliver_time logging option for this option to work. .Sp \&\fIlist\fR is an optional list of times. Eg \-show_dt1,2,4,8 will show the number of messages with delivery times under 1 second, 2 seconds, 4 seconds, 8 seconds, and over 8 seconds. .IP "\fB\-show_rt\fR\fIlist\fR" 4 .IX Item "-show_rtlist" Show the receipt times for all the messages. The receipt time is defined as the Completed hh:mm:ss \- queue_time_overall \- the Receipt hh:mm:ss. These figures will be skewed by pipelined messages so might not be that useful. .Sp Exim must have been configured to use the +queue_time_overall logging option for this option to work. .Sp \&\fIlist\fR is an optional list of times. Eg \-show_rt1,2,4,8 will show the number of messages with receipt times under 1 second, 2 seconds, 4 seconds, 8 seconds, and over 8 seconds. .IP "\fB\-byhost\fR" 4 .IX Item "-byhost" Show results by sending host. This may be combined with \&\fB\-bydomain\fR and/or \fB\-byemail\fR and/or \fB\-byedomain\fR. If none of these options are specified, then \fB\-byhost\fR is assumed as a default. .IP "\fB\-bydomain\fR" 4 .IX Item "-bydomain" Show results by sending domain. May be combined with \fB\-byhost\fR and/or \fB\-byemail\fR and/or \fB\-byedomain\fR. .IP "\fB\-byemail\fR" 4 .IX Item "-byemail" Show results by sender's email address. May be combined with \fB\-byhost\fR and/or \fB\-bydomain\fR and/or \fB\-byedomain\fR. .IP "\fB\-byemaildomain\fR or \fB\-byedomain\fR" 4 .IX Item "-byemaildomain or -byedomain" Show results by sender's email domain. May be combined with \fB\-byhost\fR and/or \fB\-bydomain\fR and/or \fB\-byemail\fR. .IP "\fB\-pattern\fR \fIDescription\fR \fI/Pattern/\fR" 4 .IX Item "-pattern Description /Pattern/" Look for the specified pattern and count the number of lines in which it appears. This option can be specified multiple times. Eg: .Sp .Vb 1 \& \-pattern \*(AqRefused connections\*(Aq \*(Aq/refused connection/\*(Aq .Ve .IP "\fB\-merge\fR" 4 .IX Item "-merge" This option allows eximstats to merge old eximstat reports together. Eg: .Sp .Vb 9 \& eximstats mainlog.sun > report.sun.txt \& eximstats mainlog.mon > report.mon.txt \& eximstats mainlog.tue > report.tue.txt \& eximstats mainlog.wed > report.web.txt \& eximstats mainlog.thu > report.thu.txt \& eximstats mainlog.fri > report.fri.txt \& eximstats mainlog.sat > report.sat.txt \& eximstats \-merge report.*.txt > weekly_report.txt \& eximstats \-merge \-html report.*.txt > weekly_report.html .Ve .RS 4 .IP "\(bu" 4 You can merge text or html reports and output the results as text or html. .IP "\(bu" 4 You can use all the normal eximstat output options, but only data included in the original reports can be shown! .IP "\(bu" 4 When merging reports, some loss of accuracy may occur in the top \fIn\fR lists. This will be towards the ends of the lists. .IP "\(bu" 4 The order of items in the top \fIn\fR lists may vary when the data volumes round to the same value. .RE .RS 4 .RE .IP "\fB\-charts\fR" 4 .IX Item "-charts" Create graphical charts to be displayed in \s-1HTML\s0 output. Only valid in combination with \fI\-html\fR. .Sp This requires the following modules which can be obtained from http://www.cpan.org/modules/01modules.index.html .RS 4 .IP "\s-1GD\s0" 4 .IX Item "GD" .PD 0 .IP "GDTextUtil" 4 .IX Item "GDTextUtil" .IP "GDGraph" 4 .IX Item "GDGraph" .RE .RS 4 .PD .Sp To install these, download and unpack them, then use the normal perl installation procedure: .Sp .Vb 4 \& perl Makefile.PL \& make \& make test \& make install .Ve .Sp On \fBDebian GNU/Linux\fR you can use \&\f(CW\*(C`apt\-get install libgd\-perl libgd\-text\-perl libgd\-graph\-perl\*(C'\fR instead. .RE .IP "\fB\-chartdir\fRI " 4 .IX Item "-chartdirI " Create the charts in the directory .IP "\fB\-chartrel\fRI " 4 .IX Item "-chartrelI " Specify the relative directory for the \*(L"img src=\*(R" tags from where to include the charts .IP "\fB\-emptyok\fR" 4 .IX Item "-emptyok" Specify that it's \s-1OK\s0 to not find any valid log lines. Without this we will output an error message if we don't find any. .IP "\fB\-d\fR" 4 .IX Item "-d" Debug flag. This outputs the \fIeval()\fR'd parser onto \s-1STDOUT\s0 which makes it easier to trap errors in the eval section. Remember to add 1 to the line numbers to allow for the title! .SH "DESCRIPTION" .IX Header "DESCRIPTION" Eximstats parses exim mainlog and syslog files to output a statistical analysis of the messages processed. By default, a text analysis is generated, but you can request other output formats using flags. See the help (\fB\-help\fR) to learn about how to create charts from the tables. .SH "AUTHOR" .IX Header "AUTHOR" There is a web site at http://www.exim.org .SH "TO DO" .IX Header "TO DO" This program does not perfectly handle messages whose received and delivered log lines are in different files, which can happen when you have multiple mail servers and a message cannot be immediately delivered. Fixing this could be tricky... .PP Merging of xls files is not (yet) possible. Be free to implement :)