Full Version: Using smartmontools / smartctl to test for a faulty drive in Linux
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Smartmontools is a utility that allows to monitor the status of your storage devices by using the S.M.A.R.T (Self-Monitoring, Analysis, and Reporting Technology) monitoring system.

In this guide, we will see how to install Smartmontools on Debian

run this command to install Smartmontools:

sudo apt-get install smartmontools

yum install smartmontools

After you finish the installation of Smartmontools, you have to enable S.M.A.R.T on your hard drive. Therefore, launch the terminal as root, then issue this command:

smartctl --saveauto=on --smart=on --offlineauto=on /dev/sda

To launch a quick check of your hard drive status, run simply this command:

smartctl -t short /dev/sda

To launch a deep check of your hard drive status, run this command:

smartctl -t long /dev/sda

To view results of the test, run this command:

smartctl -l selftest /dev/sda

You can also issue this command to view information about your hard disk:

smartctl -a /dev/sda
Reference URL's