Use smartctl to run a SMART long self-test and inspect the results to detect disk media problems. 18.12.2025 | reading time: 2 min When a drive shows slow IO or intermittent errors, run a SMART long self-test to let the disk scan its media and record any problems; the following example uses `smartctl` (run as root) to start and then inspect the test. Start the test Identify the device and start a long test with these commands: ```smartctl -i /dev/sda``` then ```smartctl -t long /dev/sda``` which will respond with an estimated completion time and a test number. Check progress and read results After the estimated time check the self-test log and full SMART record: ```smartctl -l selftest /dev/sda``` and ```smartctl -a /dev/sda```; a typical self-test entry might look like ```# 1 Extended offline Completed without error 90% 1234 -``` indicating no media error detected in that run. Practical tips and edge cases Run tests during low load because long tests can reduce performance; on NVMe devices use the device name like `/dev/nvme0n1` and consider `nvme-cli` for extended NVMe diagnostics; remember some RAID controllers hide SMART data so you may need controller-aware tools or passthrough options. Related utilities to consider Use `smartd` to monitor drives continuously and send alerts, employ `badblocks` for surface checks when writable testing is acceptable, and use `hdparm` or vendor tools for firmware-specific diagnostics when needed. Wrap-up and next steps A SMART long self-test is a low-effort, high-value check to expose many media problems before they cause data loss; combine results with SMART attributes, logs and backups to decide whether to replace a drive, and pursue deeper automation or certification to expand diagnostics skills. Join Bits & Bytes Academy First class LINUX exam preparation. storage utilities troubleshooting