Disk Error Reporting

For instance, in OpenBSD, start by figuring out the disk name.

Figure out the device name of the disklabel entry for the drive that will be checked. The section on Detecting disk devices (in BSD) will likely help with that. Then add a “c” to the end of the drive name. So, if the drive name is wd0 then the disklabel entry will be wd0c. That used to be the most common drive name: Perhaps sd0 has started to become more common. If there are multiple disk storage devices, then a name like sd1 may be used.

SMART monitoring can be enabled with:

sudo atactl /dev/wd0c smartenable

That may also be put into a bootup sequence. Note that this example is rather OpenBSD-specific. Back up the startup file before changing it, and then run:

echo echo -n \" SMARTenable\"\;atactl /dev/wd0c smartenable | sudo -n tee -a /etc/rc.local

People using other operating systems should check that the command seems to work, and then may wish to check automatically started files for details.

Calomel's guide to SMART handling states, “If an error is found then an email will be sent to root by means of the "smartenable" argument. It only sends out an email if an error is found” [which was a design that is used] “to reduce the spam.”

(For further details on how to test a disk, see hardware testing on a disk. For a similar topic, see: testing/repairing filesystems.)