[Nagiosplug-devel] check_mailq for qmail

Jan Reilink digiover at dsinet.org
Tue Apr 6 07:36:26 CEST 2004


Hi,

One of the advantages of Nagios, plugins incluis, is that you can monitor 
servers and services remotely. Looking at the source, check_mailq can only 
be run locally and in the --help I read:
	"Feedback/patches to support non-sendmail mailqueue welcome"

I am absolutely no programmer (I can read Perl/Bash/C and that's it :$), but 
I do think I have an option for the qmail mailqueue (and, DBJ himself has it 
too):
	/var/qmail/bin/qmail-qstat

It is an auto-generated Bash shell script, created during the qmail 
installation:
	/var/qmail/bin# file qmail-qstat
	qmail-qstat: Bourne shell script text executable

I do have a version which is ported to Perl, it's not completely correct, 
sometimes it prints out some slightly different number of messages, but the 
difference between both is not that big.

Because, to my knowledge, check_mailq can only be run localy, it *might* be 
a nice addition to the Nagios plugins, eventhough it is still a disadvantage 
you can only use it localy. Fortunaly we have a -qmail based- hack for this 
too which involves the use of 'tcpserver' and a tiny Bash script.

If interested, we can email the sources, they are scripts we made at the 
office, therefor my different Reply-To address.

-- 
Met vriendelijke groet / Best regards,

Jan Reilink
VEVIDA Nederland BV - Abuse & Security desk
Postbus 329, 9700 AH GRONINGEN, +31(0)50 - 5492234

Private: Dutch Security Information Network, http://www.dsinet.org/






More information about the Devel mailing list