packages: nagios-plugin-check_raid/check_raid fix cciss_vol_status check, a...

glen glen at pld-linux.org
Mon May 23 11:58:49 CEST 2011


Author: glen                         Date: Mon May 23 09:58:49 2011 GMT
Module: packages                      Tag: HEAD
---- Log message:
fix cciss_vol_status check, a patch by François Deppierraz
# cciss_vol_status -v
cciss_vol_status version 1.09
# cciss_vol_status /dev/cciss/c0d0
/dev/cciss/c0d0: (Smart Array 6i) RAID 5 Volume 0 status: OK.   At least one spare drive designated.  At least one spare drive remains available.
/dev/cciss/c0d0: (Smart Array 6i) Enclosure PROLIANT 6L6I (S/N: ) on Bus 1, Physical Port J2 status: OK.
# diff -u check_raid.old check_raid
--- check_raid.old      2011-05-13 15:59:25.000000000 +0200
+++ check_raid  2011-05-13 16:00:14.000000000 +0200
@@ -921,7 +921,7 @@
                        # /dev/cciss/c0d0: (Smart Array P400i) RAID 1
Volume 0 status: OK
                        if (my($s) = /status: (.*?)$/) {
-                               if ($s ne 'OK') {
+                               if ($s !~ '^OK') {
                                        $status = $ERRORS{CRITICAL};
                                }
                                push(@status, $_);

---- Files affected:
packages/nagios-plugin-check_raid:
   check_raid (1.91 -> 1.92) 

---- Diffs:

================================================================
Index: packages/nagios-plugin-check_raid/check_raid
diff -u packages/nagios-plugin-check_raid/check_raid:1.91 packages/nagios-plugin-check_raid/check_raid:1.92
--- packages/nagios-plugin-check_raid/check_raid:1.91	Mon Apr 18 09:54:12 2011
+++ packages/nagios-plugin-check_raid/check_raid	Mon May 23 11:58:44 2011
@@ -923,7 +923,7 @@
 
 			# /dev/cciss/c0d0: (Smart Array P400i) RAID 1 Volume 0 status: OK
 			if (my($s) = /status: (.*?)$/) {
-				if ($s ne 'OK') {
+				if ($s !~ '^OK') {
 					$status = $ERRORS{CRITICAL};
 				}
 				push(@status, $_);
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/nagios-plugin-check_raid/check_raid?r1=1.91&r2=1.92&f=u



More information about the pld-cvs-commit mailing list