Get the disk health status with SMART monitor tools on Debian and Ubuntu Linux

Wednesday, November 2, 2011 posted by Till

Every modern disk has a internal monitoring function called SMART that keeps track on errors in that disk. There is a software package called smartmontools on Linux which can be used to query the SMART status of the disk to monitor if the disk might fail in near future.


apt-get install smartmontools


First we need to know the internal device name of the harddisks. For the first SATA disk, this is normally /dev/sda, the second is /dev/sdb etc. If you are unsure about the device names of your computer, then you can get them with:

fdisk -l

The command lists the partitions e.g. /dev/sda1. To get the device name, use the partition name without the number, e.g. the device of partition/dev/sda1 is /dev/sda.

To get a summary of the healt status of the disk, run:

smartctl --health /dev/sda

replace /dev/sda with the device name of the harddisk that you want to query.

The output will look similar to this:

~# smartctl --health /dev/sda
smartctl version 5.38 [x86_64-unknown-linux-gnu] Copyright (C) 2002-8 Bruce Allen
Home page is

SMART overall-health self-assessment test result: PASSED

To get the full detailed output of all parameters, use this command:

smartctl --all /dev/sda


Be Sociable, Share!

2 Responses to “Get the disk health status with SMART monitor tools on Debian and Ubuntu Linux”

  1. kayn says:

    smartctl ––health /dev/sda

  2. aprogrammer says:

    Thanks for the post. I was using this instruction – . It has more explanation about separate smartd log files, almost all smartd.conf options and debug all smartd process (email sending, logs output,daemon startup options). Hope it helps to improve.

Leave a Reply