i got a problem with the nullmailer-part in check_mailq. It always reports 0 mails in queue even if there are some..
These are lines 520-525 from latest check_mailq (example output from mailq and the regex) :
First problem i see is that the regex for minutes and seconds is wrong - both only match from 00-29!? Unfortunate if your queued mail has a timestamp of 16:43:52...while (<MAILQ>) {
#2006-06-22 16:00:00 282 bytes
if (/^[1-9][0-9]*-[01][0-9]-[0-3][0-9]\s[0-2][0-9]\:[0-2][0-9]\:[0-2][0-9]\s{2}[0-9]+\sbytes$/) {
$msg_q++ ;
Second problem that example string from mailq is a bit different on (all of) my machines. I hope someone could reproduce that. This is how mailq output looks here:
2 small differences:2014-09-04 21:42:36 19997323 bytes from <root@domain..>
- - there is only one space between time and size
--> i replaced \s{2} with only \s
- - the line doesn't end after "bytes"
-> i replaced "$" at the end with a "*"