Author: glen Date: Mon Oct 5 13:06:50 2009 GMT Module: packages Tag: HEAD ---- Log message: - avoid overwriting previous raid messages
---- Files affected: packages/nagios-plugin-check_raid: check_raid (1.48 -> 1.49) ---- Diffs: ================================================================ Index: packages/nagios-plugin-check_raid/check_raid diff -u packages/nagios-plugin-check_raid/check_raid:1.48 packages/nagios-plugin-check_raid/check_raid:1.49 --- packages/nagios-plugin-check_raid/check_raid:1.48 Mon Oct 5 14:17:45 2009 +++ packages/nagios-plugin-check_raid/check_raid Mon Oct 5 15:06:45 2009 @@ -8,7 +8,7 @@ # # 2004-2006 S Shipway, university of auckland # Thanks to M Carmier for megaraid section -# 2009 Elan Ruusamäe <[email protected]> +# 2009 Elan Ruusamäe <[email protected]> # # Version 1.1 : IPS; Solaris, AIX, Linux software RAID; megaide # Version 2.0 : Added megaraid, mpt (serveraid), aacli (serveraid) @@ -345,7 +345,7 @@ } close $fh; - $message = "mpt:".join(', ', @status) if @status; + $message .= "mpt:".join(', ', @status) if @status; } # MegaRAID @@ -407,7 +407,7 @@ push(@status, "Logical Drive ".join(', ', @ld)) if @ld; } - $message = "gdth:".join(', ', @status) if @status; + $message .= "gdth:".join(', ', @status) if @status; } sub check_dpt_i2o { @@ -577,7 +577,7 @@ } close $fh; - $message = "arcconf:".join(', ', @status) if @status; + $message .= "arcconf:".join(', ', @status) if @status; } # LSI MegaRaid or Dell Perc arrays @@ -602,7 +602,7 @@ if ($lines[11] =~ /No Adapters Found/) { $status = $ERRORS{WARNING} unless $status; - $message = "megarc: No LSI adapters were found on this machine"; + $message .= "megarc: No LSI adapters were found on this machine"; return; } my @c; @@ -613,7 +613,7 @@ } unless (@c) { $status = $ERRORS{WARNING} unless $status; - $message = "megarc: No LSI adapters were found on this machine"; + $message .= "megarc: No LSI adapters were found on this machine"; return; } @@ -658,7 +658,7 @@ } } - $message = "megarc: ".join(', ', @status) if @status; + $message .= "megarc: ".join(', ', @status) if @status; } sub check_cmdtool2 { @@ -680,7 +680,7 @@ unless (@c) { $status = $ERRORS{WARNING} unless $status; - $message = "CmdTool2: No LSI adapters were found on this machine"; + $message .= "CmdTool2: No LSI adapters were found on this machine"; return; } @@ -704,7 +704,7 @@ } } - $message = "CmdTool2: ".join(', ', @status) if @status; + $message .= "CmdTool2: ".join(', ', @status) if @status; } sub which { @@ -823,7 +823,8 @@ $ERRORS{CRITICAL} = $ERRORS{WARNING}; } -$status = $ERRORS{OK}; $message = ''; +$status = $ERRORS{UNKNOWN}; +$message = ''; check_gdth if -d "/proc/scsi/gdth"; check_megaide if -d "/proc/megaide"; ================================================================ ---- CVS-web: http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/nagios-plugin-check_raid/check_raid?r1=1.48&r2=1.49&f=u _______________________________________________ pld-cvs-commit mailing list [email protected] http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit
