packages: nagios-plugin-check_raid/check_raid, nagios-plugin-check_raid/t/m...
glen
glen at pld-linux.org
Tue Feb 28 15:31:57 CET 2012
Author: glen Date: Tue Feb 28 14:31:57 2012 GMT
Module: packages Tag: HEAD
---- Log message:
mdstat: some setups do not include space in separator lines (md3 in the sample)
patch by Shingo Hisakawa <shingohisakawa#gmail.com>
Hi glen,
I found my CentOS6.2 uses blank line (/^$/) as delimiter for /proc/mdstat.please refer attached "mdstat.txt".
so i made a simple patch for 2.1.1.105 as "check_raid_patch.txt".
it works well for my server.
Thank you very much for your effort.
Shingo
---- Files affected:
packages/nagios-plugin-check_raid:
check_raid (1.106 -> 1.107)
packages/nagios-plugin-check_raid/t:
mdstat-centos6.2 (NONE -> 1.1) (NEW)
---- Diffs:
================================================================
Index: packages/nagios-plugin-check_raid/check_raid
diff -u packages/nagios-plugin-check_raid/check_raid:1.106 packages/nagios-plugin-check_raid/check_raid:1.107
--- packages/nagios-plugin-check_raid/check_raid:1.106 Sun Feb 5 14:41:17 2012
+++ packages/nagios-plugin-check_raid/check_raid Tue Feb 28 15:31:52 2012
@@ -211,7 +211,7 @@
}
# we need empty line denoting end of one md
- next unless /^\s+$/;
+ next unless /^\s*$/;
next unless valid($md);
================================================================
Index: packages/nagios-plugin-check_raid/t/mdstat-centos6.2
diff -u /dev/null packages/nagios-plugin-check_raid/t/mdstat-centos6.2:1.1
--- /dev/null Tue Feb 28 15:31:57 2012
+++ packages/nagios-plugin-check_raid/t/mdstat-centos6.2 Tue Feb 28 15:31:52 2012
@@ -0,0 +1,20 @@
+Personalities : [raid1] [raid0]
+md4 : active raid1 sda6[0] sdb6[1]
+ 238456700 blocks super 1.1 [2/2] [UU]
+ bitmap: 0/2 pages [0KB], 65536KB chunk
+
+md3 : active raid1 sda5[0] sdb5[1]
+ 471858044 blocks super 1.1 [2/2] [UU]
+ bitmap: 2/4 pages [8KB], 65536KB chunk
+
+md0 : active raid1 sda3[0] sdb3[1]
+ 102388 blocks super 1.0 [2/2] [UU]
+
+md1 : active raid0 sdb2[1] sda2[0]
+ 8386560 blocks super 1.1 512k chunks
+
+md2 : active raid1 sdb1[1] sda1[0]
+ 262142844 blocks super 1.1 [2/2] [UU]
+ bitmap: 1/2 pages [4KB], 65536KB chunk
+
+unused devices: <none>
================================================================
---- CVS-web:
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/nagios-plugin-check_raid/check_raid?r1=1.106&r2=1.107&f=u
More information about the pld-cvs-commit
mailing list