Problem: In syslog you find a line like this:
smartd[1514]: Device: /dev/sda [SAT], Failed SMART
usage Attribute: 5 Reallocated_Sector_Ct.
But when you check with “smartctl -a” you find a reallocated sector count of zero:
# smartctl -a /dev/sda
...
ID# ATTRIBUTE_NAME FLAG TYPE UPDATED WHEN_FAILED RAW_VALUE
5 Reallocated_Sector_Ct 0x0033 Pre-fail Always - 0
...
Discussion: The harddisk had actually no reallocated sectors, but Smartctrl (Smartmontools) reported a wrong error, because when it was started a different harddisk with errors was found as /dev/sda, but with hot swapping the harddisk was changed and smartd did not recognize the change. We found this by checking the logs in “/var/lib/smartmontools”. There we found logfiles named with the old harddisk name, but not the new one.
Solution: restart smartd (“/etc/init.d/smartmontools restart”)
Versions: Devuan4/Debian11, smartmontools release 7.2