Saturday, 2005-10-08 23:53

Sendmail delivery stats

Recently I had to bear with mail server analyze, serving traffic on level +10k messages a day. And there were some degradation of services felt by users, but there was no stright pattern what mails are delivered with bigger latency. Since this was Sendmail powered site I wrote simple tool in Perl to help with analysis.

Current version:1.4a (2005-11-06)

You can it download from nhw.pl/blg/download/sstats-1.4a.tgz.

I hope it is simple to use. What it does ? It collects all log entries, which are related to successful mail delivery. Groups it by domain and calculates average delivery time (time to leave queue - I is rather impossible to estimate time spend in others servers queues ;-))) ). Most useful (for me) is -a option, which makes all output in CSV format, for easy use in further analysis.

It was not tested on animals... eee hold on, this not right disclaimer ! It was tested on logs from Sendmail 8.13.x and I belive it calculates proper values. YMMV ;-))

UPDATES:

2005-10-11
v1.1 - I've added new switch, which allows to drop entries with few mails only.

2005-10-13
v1.2 - Now sstats drops local delivery, does not count this as 'unknown/bad regexp'

2005-10-23
v1.3 - New data displayed - max and min delivery times. Maybe std. deviation would be nice, but this requires storing all data to compute result. Not now ;-)

2005-11-06
v1.4a - HTML output, with templates. Sorted output (domain name) and minor bugfixes and cleanup.