diff options
author | RincewindsHat <12514511+RincewindsHat@users.noreply.github.com> | 2021-12-02 15:11:21 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-12-02 15:11:21 +0100 |
commit | df1e9e975f69c8f7965bab91684870fe509739c6 (patch) | |
tree | 526b0c77c524b2219d5a48fd78b8302f055a4a5b /plugins-scripts/check_mailq.pl | |
parent | 6246b8f1830e8a375bc656deafd28aab715b4fd9 (diff) | |
parent | 1a3a715702a5b6709fed2a1eb53ec644c9968057 (diff) | |
download | monitoring-plugins-df1e9e975f69c8f7965bab91684870fe509739c6.tar.gz |
Merge branch 'master' into mailq-add-config-dir
Diffstat (limited to 'plugins-scripts/check_mailq.pl')
-rwxr-xr-x | plugins-scripts/check_mailq.pl | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/plugins-scripts/check_mailq.pl b/plugins-scripts/check_mailq.pl index 9ef292e7..4bc9487f 100755 --- a/plugins-scripts/check_mailq.pl +++ b/plugins-scripts/check_mailq.pl @@ -539,7 +539,7 @@ elsif ( $mailq eq "nullmailer" ) { 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$/) { + if (/^[1-9][0-9]*-[01][0-9]-[0-3][0-9]\s[0-2][0-9]\:[0-5][0-9]\:[0-5][0-9]\s+[0-9]+\sbytes/) { $msg_q++ ; } } @@ -576,6 +576,8 @@ sub process_arguments(){ "t=i" => \$opt_t, "timeout=i" => \$opt_t, "s" => \$opt_s, "sudo" => \$opt_s, "d:s" => \$opt_d, "configdir:s" => \$opt_d + "W=i" => \$opt_W, # warning if above this number + "C=i" => \$opt_C, # critical if above this number ); if ($opt_V) { @@ -669,8 +671,8 @@ sub print_help () { print " Feedback/patches to support non-sendmail mailqueue welcome\n\n"; print "-w (--warning) = Min. number of messages in queue to generate warning\n"; print "-c (--critical) = Min. number of messages in queue to generate critical alert ( w < c )\n"; - print "-W (--Warning) = Min. number of messages for same domain in queue to generate warning\n"; - print "-C (--Critical) = Min. number of messages for same domain in queue to generate critical alert ( W < C )\n"; + print "-W = Min. number of messages for same domain in queue to generate warning\n"; + print "-C = Min. number of messages for same domain in queue to generate critical alert ( W < C )\n"; print "-t (--timeout) = Plugin timeout in seconds (default = $utils::TIMEOUT)\n"; print "-M (--mailserver) = [ sendmail | qmail | postfix | exim | nullmailer ] (default = autodetect)\n"; print "-s (--sudo) = Use sudo to call the mailq command\n"; |