Răsfoiți Sursa

This patch fixes the regular expression for the array recovery
completion percentage to detect the percentage when there is more than
one space between between "recovery =" and the percentage. (When
the percentage is less than 10%, /proc/mdstat shows it left-padded
with an extra space: "recovery = 7.6%".)

Alex Bradley 13 ani în urmă
părinte
comite
9703858ba3
1 a modificat fișierele cu 1 adăugiri și 1 ștergeri
  1. 1 1
      contrib/check_linux_raid.pl

+ 1 - 1
contrib/check_linux_raid.pl

@@ -61,7 +61,7 @@ while(defined $nextdev){
 		if (defined $device) {
 			if (/(\[[_U]+\])/) {
 				$status{$device} = $1;
-			} elsif (/recovery = (.*?)\s/) {  
+			} elsif (/recovery =\s+(.*?)\s/) {
 				$recovery{$device} = $1;
 				($finish{$device}) = /finish=(.*?min)/;
 				$device=undef;