[Feature Request] Add Smart Failing Now status to email status


Squid

Recommended Posts

Code change for monitor to be some thing like this:

 

// process disk SMART notifications. Give messages only when changes occur!
  unset($codes);
  exec("awk '$1~/^(5|184|187|188|197|198)$/{print $1,$10,$2,$9}' /var/local/emhttp/smart/{$disk['name']}", $codes);
  $item = 'smart';
  foreach ($codes as $code) {
    if (!$code) continue;
    $warn = explode(' ',$code);
    $attr = "$name.{$warn[0]}";
    $word = str_replace('_',' ',strtolower($warn[2]));
    $last = isset($saved[$item][$attr]) ? $saved[$item][$attr] : 0;

    if ($warn[1]>0) {
      if ($warn[1]>$last) {
        exec("$notify -e \"unRAID $text SMART health [{$warn[0]}]\" -s \"Warning {$warn[3]} $word is {$warn[1]}\" -d \"$info\" -i \"warning\"");
        $saved[$item][$attr] = $warn[1];
      }
    } else {
      if ($last>0) {
        exec("$notify -e \"unRAID $text SMART message [{$warn[0]}]\" -s \"Notice: $word returned to nominal value\" -d \"$info\" -i \"normal\"");
        unset($saved[$item][$attr]);
      }
    }
  }
}

 

This adds the status (either "-" or "FAILING_NOW") from smartctl for each email sent out.  Easily lets the user know that immediate action is required.

 

Email Produced from this:

 

Event: unRAID Disk 9 SMART health [184]
Subject: Warning FAILING_NOW end-to-end error is 6
Description: ST2000DM001-1CH164_Z1E5FT2H (sdk)
Importance: warning

 

Email Produced from a non-failing attribute:

 

Event: unRAID Disk 8 SMART health [5]
Subject: Warning - reallocated sector ct is 1
Description: ST31000333AS_9TE0E411 (sdi)
Importance: warning

 

Email as currently sent out does not reflect the failing status:

 

Event: unRAID Disk 9 SMART health [184]
Subject: Warning: end-to-end error is 6
Description: ST2000DM001-1CH164_Z1E5FT2H (sdk)
Importance: warning

Link to comment

FWIW.

 

https://www.backblaze.com/blog/hard-drive-smart-stats/

From experience, we have found the following 5 SMART metrics indicate impending disk drive failure:

SMART 5 – Reallocated_Sector_Count.

SMART 187 – Reported_Uncorrectable_Errors.

SMART 188 – Command_Timeout.

SMART 197 – Current_Pending_Sector_Count.

SMART 198 – Offline_Uncorrectable.

We chose these 5 stats based on our experience and input from others in the industry because they are consistent across manufacturers and they are good predictors of failure.

Link to comment

All well and good.  But, when I see an attribute in FAILING_NOW status, and the drive is under warranty I don't hesitate to RMA it, and Seagate has never declined an RMA for me with 184 Failing.

 

But, finding any information on the attribute itself is difficult at best.  The best information I've been able to find online states that the controller found a checksum error between the information transmitted from the heads to the cache.  Those 6 errors all happened at the same time (~2 years ago), and have not happened since, but I do watch it like a hawk.

 

Seagate sets the threshold of failure for the attribute at 99 (single fault = failure).  But, admittedly the error is rare.

 

In my mind, ANY attribute in failure status should be reported to the user, whether or not they are one of the big 5 or not.  After all, I believe its the manufacturers that are setting the threshold levels for the attributes.

Link to comment

In my mind, ANY attribute in failure status should be reported to the user, whether or not they are one of the big 5 or not.  After all, I believe its the manufacturers that are setting the threshold levels for the attributes.

 

I'm not disputing it, Only presenting more data for review.

Any drive with a FAILING_NOW attribute is candidate for RMA.

 

What I found interesting is that Backblaze said they replace a drive when attribute 187 is > 0.

Link to comment

Also, I would like to add how important the FAILING_NOW status is in comparison to the Overall-health self-assessment test result.

I.E. I've seen many drives report "SMART overall-health self-assessment test result: PASSED" even when there were FAILING_NOW attributes.

Case in point:

 

Model Family:	Seagate Barracuda 7200.14 (AF)
Device Model:	ST2000DM001-1CH164
Serial Number:	
LU WWN Device Id:	5 000c50 064ca0c7d
Firmware Version:	CC27
User Capacity:	2,000,398,934,016 bytes [2.00 TB]
Sector Sizes:	512 bytes logical, 4096 bytes physical
Rotation Rate:	7200 rpm
Device is:	In smartctl database [for details use: -P show]
ATA Version is:	ACS-2, ACS-3 T13/2161-D revision 3b
SATA Version is:	SATA 3.1, 6.0 Gb/s (current: 3.0 Gb/s)
Local Time is:	Wed Jan 28 00:34:50 2015 EST
SMART support is:	Available - device has SMART capability.
SMART support is:	Enabled
SMART overall-health :	PASSED

 

SMART Attributes Data Structure revision number: 10
Vendor Specific SMART Attributes with Thresholds:
ID# ATTRIBUTE_NAME          FLAG     VALUE WORST THRESH TYPE      UPDATED  WHEN_FAILED RAW_VALUE
  1 Raw_Read_Error_Rate     0x000f   111   099   006    Pre-fail  Always       -       37567392
  3 Spin_Up_Time            0x0003   096   095   000    Pre-fail  Always       -       0
  4 Start_Stop_Count        0x0032   099   099   020    Old_age   Always       -       1746
  5 Reallocated_Sector_Ct   0x0033   100   100   010    Pre-fail  Always       -       0
  7 Seek_Error_Rate         0x000f   067   060   030    Pre-fail  Always       -       6260701
  9 Power_On_Hours          0x0032   091   091   000    Old_age   Always       -       8083
10 Spin_Retry_Count        0x0013   100   100   097    Pre-fail  Always       -       0
12 Power_Cycle_Count       0x0032   100   100   020    Old_age   Always       -       75
183 Runtime_Bad_Block       0x0032   100   100   000    Old_age   Always       -       0
184 End-to-End_Error        0x0032   094   094   099    Old_age   Always   FAILING_NOW 6
187 Reported_Uncorrect      0x0032   100   100   000    Old_age   Always       -       0
188 Command_Timeout         0x0032   100   100   000    Old_age   Always       -       0 0 6
189 High_Fly_Writes         0x003a   100   100   000    Old_age   Always       -       0
190 Airflow_Temperature_Cel 0x0022   080   067   045    Old_age   Always       -       20 (Min/Max 19/26)
191 G-Sense_Error_Rate      0x0032   100   100   000    Old_age   Always       -       0
192 Power-Off_Retract_Count 0x0032   100   100   000    Old_age   Always       -       40
193 Load_Cycle_Count        0x0032   090   090   000    Old_age   Always       -       21175
194 Temperature_Celsius     0x0022   020   040   000    Old_age   Always       -       20 (0 18 0 0 0)
197 Current_Pending_Sector  0x0012   100   100   000    Old_age   Always       -       0
198 Offline_Uncorrectable   0x0010   100   100   000    Old_age   Offline      -       0
199 UDMA_CRC_Error_Count    0x003e   200   200   000    Old_age   Always       -       0
240 Head_Flying_Hours       0x0000   100   253   000    Old_age   Offline      -       942h+52m+48.283s
241 Total_LBAs_Written      0x0000   100   253   000    Old_age   Offline      -       24310929789
242 Total_LBAs_Read         0x0000   100   253   000    Old_age   Offline      -       103627587944

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.