From 3f62efe64c447821f2fbd6759d52534c275bbffc Mon Sep 17 00:00:00 2001 From: bergware Date: Sat, 29 Oct 2016 09:23:56 +0200 Subject: [PATCH] Fix array status report takes disk individual temperature thresholds in consideration --- plugins/dynamix/scripts/statuscheck | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/plugins/dynamix/scripts/statuscheck b/plugins/dynamix/scripts/statuscheck index ccc6401c6..e33a6f713 100755 --- a/plugins/dynamix/scripts/statuscheck +++ b/plugins/dynamix/scripts/statuscheck @@ -12,17 +12,18 @@ */ ?> =$max) { $fail = ' (disk is overheated'; $error0++; - } else if ($temp>=$hot) { + } elseif ($temp>=$hot) { $fail = ' (disk is hot'; $error1++; } else { @@ -162,9 +165,9 @@ if ($mdResync>0) { if ($var['sbSyncExit']!=0) { $data[] = "Last check incomplete on ".my_time($sbSynced2).", finding $sbSyncErrs error".($sbSyncErrs==1?'.':'s.'); $data[] = "Error code: ".$var['sbSyncExit']; - } else if ($sbSynced==0) { + } elseif ($sbSynced==0) { $data[] = "Parity has not been checked yet"; - } else if ($sbSynced2>0) { + } elseif ($sbSynced2>0) { if (strstr($var['mdResyncAction'],"recon")) { $data[] = 'Parity or Data is invalid'; } else {