smartd is a utility to check on the Self-Monitoring, Analysis and Reporting Technology or S.M.A.R.T. of a physical storage device like a hard drive or solid state drive.
-
Configure
/usr/local/etc/smartd.confDEFAULT -a -d scsi -m me@example.com -s S/../.././03 /dev/da0 /dev/da1 /dev/da2 /dev/da3 /dev/da4 /dev/da5 DEFAULT -a -d scsi -m me@example.com -s S/../.././04 /dev/da6 /dev/da7 /dev/da8 /dev/da9 DEFAULT -a -d scsi -m me@example.com -s S/../.././05 /dev/da10 /dev/da11 /dev/da12 /dev/da13 DEFAULT -a -d scsi -m me@example.com -s S/../.././06 /dev/da14 /dev/da15 /dev/da16 /dev/da17 DEFAULT -a -d scsi -m me@example.com -s S/../.././07 /dev/da18 /dev/da19 /dev/da20 /dev/da21The
DEFAULTstatements allow you to set default settings for the disks defined below. The porperties will remain the same until the nextDEFAULTstatement is defined.- The
-amonitors all SMART properties. -didentifies the device type (mine are all SATA).-mdenotes where you want failure emails sent.-ssets a REGEX for how and when you want the test performed.Sis a short test.Lis a long test.- The when statement is month/day-of-week/day/hour all represented in two-digit format.
- The
-
Enable the service to start and start it
sysrc smartd_enable=YES -f /etc/rc.conf.local service smartd start
That's it!