.ig
- Copyright (C) 2002-10 Bruce Allen <smartmontools-support@lists.sourceforge.net>
-
- $Id: smartctl.8.in 3283 2011-03-04 20:13:57Z chrfranke $
-
- This program is free software; you can redistribute it and/or modify it
- under the terms of the GNU General Public License as published by the Free
- Software Foundation; either version 2, or (at your option) any later
- version.
-
- You should have received a copy of the GNU General Public License (for
- example COPYING); if not, write to the Free Software Foundation, Inc., 675
- Mass Ave, Cambridge, MA 02139, USA.
-
- This code was originally developed as a Senior Thesis by Michael Cornwell
- at the Concurrent Systems Laboratory (now part of the Storage Systems
- Research Center), Jack Baskin School of Engineering, University of
- California, Santa Cruz. http://ssrc.soe.ucsc.edu/
+Copyright (C) 2002-10 Bruce Allen
+Copyright (C) 2004-15 Christian Franke
+
+$Id: smartctl.8.in 4120 2015-08-27 16:12:21Z samm2 $
+
+This program is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+You should have received a copy of the GNU General Public License
+(for example COPYING); If not, see <http://www.gnu.org/licenses/>.
+
+This code was originally developed as a Senior Thesis by Michael Cornwell
+at the Concurrent Systems Laboratory (now part of the Storage Systems
+Research Center), Jack Baskin School of Engineering, University of
+California, Santa Cruz. http://ssrc.soe.ucsc.edu/
..
-.TH SMARTCTL 8 CURRENT_SVN_DATE CURRENT_SVN_VERSION CURRENT_SVN_DATE
+.TH SMARTCTL 8 "CURRENT_SVN_DATE" "CURRENT_SVN_VERSION" "SMART Monitoring Tools"
.SH NAME
\fBsmartctl\fP \- Control and Monitor Utility for SMART Disks
.SH SYNOPSIS
.B smartctl [options] device
-.SH FULL PATH
-.B /usr/local/sbin/smartctl
-
-.SH PACKAGE VERSION
-CURRENT_SVN_VERSION CURRENT_SVN_DATE CURRENT_SVN_REV
-
.SH DESCRIPTION
-\fBsmartctl\fP controls the Self\-Monitoring, Analysis and Reporting
-Technology (SMART) system built into many ATA\-3 and later ATA, IDE and
-SCSI\-3 hard drives. The purpose of SMART is to monitor the reliability
-of the hard drive and predict drive failures, and to carry out
-different types of drive self\-tests. This version of \fBsmartctl\fP
-is compatible with ATA/ATAPI\-7 and earlier standards (see REFERENCES
-below)
-
-\fBsmartctl\fP is a command line utility designed to perform SMART
-tasks such as printing the SMART self\-test and error logs, enabling
-and disabling SMART automatic testing, and initiating device
-self\-tests. Note: if the user issues a SMART command that is
-(apparently) not implemented by the device, \fBsmartctl\fP will print
-a warning message but issue the command anyway (see the \fB\-T,
-\-\-tolerance\fP option below). This should not cause problems: on
-most devices, unimplemented SMART commands issued to a drive are
-ignored and/or return an error.
+.\" %IF NOT OS ALL
+.\"! [This man page is generated for the OS_MAN_FILTER version of smartmontools.
+.\"! It does not contain info specific to other platforms.]
+.\"! .PP
+.\" %ENDIF NOT OS ALL
+\fBsmartctl\fP controls the Self-Monitoring, Analysis and
+Reporting Technology (SMART) system built into most ATA/SATA and SCSI/SAS
+hard drives and solid-state drives.
+The purpose of SMART is to monitor the reliability of the hard drive
+and predict drive failures, and to carry out different types of drive
+self-tests.
+\fBsmartctl\fP also supports some features not related to SMART.
+This version of \fBsmartctl\fP is compatible with
+ACS-3, ACS-2, ATA8-ACS, ATA/ATAPI-7 and earlier standards
+(see \fBREFERENCES\fP below).
\fBsmartctl\fP also provides support for polling TapeAlert messages
from SCSI tape drives and changers.
is often derived from the device path but may need help with the \'\-d\'
option (for more information see the section on "ATA, SCSI command sets
and SAT" below). Device paths are as follows:
+.\" %IF OS Linux
.IP \fBLINUX\fP: 9
-Use the forms \fB"/dev/hd[a\-t]"\fP for IDE/ATA devices, and
-\fB"/dev/sd[a\-z]"\fP for SCSI devices. For SCSI Tape Drives and
-Changers with TapeAlert support use the devices \fB"/dev/nst*"\fP and
-\fB"/dev/sg*"\fP. For SATA disks accessed with libata, use
-\fB"/dev/sd[a\-z]"\fP and append \fB"\-d ata"\fP. For disks behind
+Use the forms \fB"/dev/sd[a\-z]"\fP for ATA/SATA and SCSI/SAS devices.
+For SCSI Tape Drives and Changers with TapeAlert support use the
+devices \fB"/dev/nst*"\fP and \fB"/dev/sg*"\fP. For disks behind
3ware controllers you may need \fB"/dev/sd[a\-z]"\fP or
\fB"/dev/twe[0\-9]"\fP, \fB"/dev/twa[0\-9]"\fP or \fB"/dev/twl[0\-9]"\fP: see details
below. For disks behind HighPoint RocketRAID controllers you may need
\fB"/dev/sd[a\-z]"\fP. For disks behind Areca SATA RAID controllers,
you need \fB"/dev/sg[2\-9]"\fP (note that smartmontools interacts with
the Areca controllers via a SCSI generic device which is different
-than the SCSI device used for reading and writing data)!
+than the SCSI device used for reading and writing data)! For HP Smart
+Array RAID controllers, there are three currently supported drivers: cciss,
+hpsa, and hpahcisr. For disks accessed via the cciss driver the device nodes
+are of the form \fB"/dev/cciss/c[0\-9]d0"\fP. For disks accessed via
+the hpahcisr and hpsa drivers, the device nodes you need are \fB"/dev/sg[0\-9]*"\fP.
+("lsscsi \-g" is helpful in determining which scsi generic device node corresponds
+to which device.) Use the nodes corresponding to the RAID controllers,
+not the nodes corresponding to logical drives. See the \fB\-d\fP option below, as well.
+.\" %ENDIF OS Linux
+.\" %IF OS Darwin
.IP \fBDARWIN\fP: 9
Use the forms \fB/dev/disk[0\-9]\fP or equivalently \fBdisk[0\-9]\fP or equivalently
\fB/dev/rdisk[0\-9]\fP. Long forms are also available: please use \'\-h\' to see some
examples. Note that there is currently no Darwin SCSI support.
+
+Use the OS X SAT SMART Driver to access SMART data on SAT capable USB and
+Firewire devices (see INSTALL file).
+.\" %ENDIF OS Darwin
+.\" %IF OS FreeBSD
.IP \fBFREEBSD\fP: 9
Use the forms \fB"/dev/ad[0\-9]+"\fP for IDE/ATA
devices and \fB"/dev/da[0\-9]+"\fP or \fB"/dev/pass[0\-9]+"\fP for SCSI devices.
-For SATA devices on AHCI bus use \fB"/dev/ada[0\-9]+"\fP format.
+For SATA devices on AHCI bus use \fB"/dev/ada[0\-9]+"\fP format. For HP Smart
+Array RAID controllers, use \fB"/dev/ciss[0\-9]"\fP (and see the \fB-d\fP option,
+below).
+.\" %ENDIF OS FreeBSD
+.\" %IF OS NetBSD OpenBSD
.IP \fBNETBSD/OPENBSD\fP: 9
Use the form \fB"/dev/wd[0\-9]+c"\fP for IDE/ATA
devices. For SCSI disk and tape devices, use the device names
\fB"/dev/sd[0\-9]+c"\fP and \fB"/dev/st[0\-9]+c"\fP respectively.
Be sure to specify the correct "whole disk" partition letter for
your architecture.
+.\" %ENDIF OS NetBSD OpenBSD
+.\" %IF OS Solaris
.IP \fBSOLARIS\fP: 9
Use the forms \fB"/dev/rdsk/c?t?d?s?"\fP for IDE/ATA and SCSI disk
devices, and \fB"/dev/rmt/*"\fP for SCSI tape devices.
-.IP \fBWINDOWS\ 9x/ME\fP: 9
-Use the forms \fB"/dev/hd[a\-d]"\fP for standard IDE/ATA devices
-accessed via SMARTVSD.VXD, and \fB"/dev/hd[e\-h]"\fP for additional devices
-accessed via a patched SMARTVSE.VXD (see INSTALL file for details).
-Use the form \fB"/dev/scsi[0\-9][0\-f]"\fP for SCSI devices via an aspi dll
-on ASPI adapter 0\-9, ID 0\-15. The prefix \fB"/dev/"\fP is optional.
-.IP \fBWINDOWS\ NT4/2000/XP/2003/Vista/Win7/2008\fP: 9
+.\" %ENDIF OS Solaris
+.\" %IF OS Windows Cygwin
+.IP \fBWINDOWS\fP: 9
Use the forms \fB"/dev/sd[a\-z]"\fP for IDE/(S)ATA and SCSI disks
"\\\\.\\PhysicalDrive[0\-25]" (where "a" maps to "0").
+Use \fB"/dev/sd[a\-z][a\-z]"\fP for "\\\\.\\PhysicalDrive[26\-...]".
These disks can also be referred to as \fB"/dev/pd[0\-255]"\fP for
"\\\\.\\PhysicalDrive[0\-255]".
ATA disks can also be referred to as \fB"/dev/hd[a\-z]"\fP for
to parse CLI or 3DM output from standard input or clipboard.
The option \'\-d 3ware,N\' is not necessary on Windows.
-[NEW EXPERIMENTAL SMARTCTL FEATURE] For disks behind Intel Matrix RAID
-driver use \fB"/dev/csmi[0\-9],N"\fP where N specifies the port behind
-the logical scsi controller "\\\\.\\Scsi[0\-9]:".
+For disks behind an Intel ICHxR controller with RST driver use
+\fB"/dev/csmi[0\-9],N"\fP where N specifies the port behind the logical
+scsi controller "\\\\.\\Scsi[0\-9]:".
+
+For SATA or SAS disks behind an Areca controller use
+\fB"/dev/arcmsr[0\-9]"\fP, see \'\-d areca,N[/E]\' below.
+
The prefix \fB"/dev/"\fP is optional.
-.IP \fBCYGWIN\fP: 9
-See "WINDOWS NT4/2000/XP/2003/Vista/Win7/2008" above.
+.\" %ENDIF OS Windows Cygwin
+.\" %IF OS OS2
.IP \fBOS/2,eComStation\fP: 9
Use the form \fB"/dev/hd[a\-z]"\fP for IDE/ATA devices.
+.\" %ENDIF OS OS2
.PP
if \'\-\' is specified as the device path, \fBsmartctl\fP reads and
interprets it's own debug output from standard input.
See \'\-r ataioctl\' below for details.
.PP
Based on the device path, \fBsmartctl\fP will guess the device type
-(ATA or SCSI). If necessary, the \'\-d\' option can be used to over\-ride
+(ATA or SCSI). If necessary, the \'\-d\' option can be used to override
this guess
Note that the printed output of \fBsmartctl\fP displays most numerical
displayed with a leading \fB"0x"\fP, for example: "0xff". This man
page follows the same convention.
-.PP
.SH OPTIONS
-.PP
The options are grouped below into several categories. \fBsmartctl\fP
will execute the corresponding commands in the order: INFORMATION,
ENABLE/DISABLE, DISPLAY DATA, RUN/ABORT TESTS.
drive model family may also be printed. If \'\-n\' (see below) is
specified, the power mode of the drive is printed.
.TP
+.B \-\-identify[=[w][nvb]]
+[ATA only] Prints an annotated table of the IDENTIFY DEVICE data.
+By default, only valid words (words not equal to 0x0000 or 0xffff)
+and nonzero bits and bit fields are printed.
+This can be changed by the optional argument which consists of one or
+two characters from the set \'wnvb\'.
+The character \'w\' enables printing of all 256 words. The character
+\'n\' suppresses printing of bits, \'v\' enables printing of all bits
+from valid words, \'b\' enables printing of all bits.
+For example \'\-\-identify=n\' (valid words, no bits) produces the
+shortest output and \'\-\-identify=wb\' (all words, all bits) produces
+the longest output.
+.TP
.B \-a, \-\-all
Prints all SMART information about the disk, or TapeAlert information
about the tape drive or changer. For ATA devices this is equivalent
Prints all SMART and non-SMART information about the device. For ATA
devices this is equivalent to
.nf
-\'\-H \-i \-c \-A \-l xerror,error \-l xselftest,selftest \-l selective
-\-l directory \-l scttemp \-l scterc \-l sataphy\'.
+\'\-H \-i \-g all \-c \-A \-f brief \-l xerror,error \-l xselftest,selftest
+\-l selective \-l directory \-l scttemp \-l scterc \-l devstat \-l sataphy\'.
.fi
and for SCSI, this is equivalent to
.nf
All options after \'\-\-\' are appended to each output line.
For example:
.nf
-smartctl --scan-open -- -a -W 4,45,50 -m admin@work > smartd.conf
+smartctl \-\-scan\-open \-\- \-a \-W 4,45,50 \-m admin@work > smartd.conf
.fi
+.TP
+.B \-g NAME, \-\-get=NAME
+Get non-SMART device settings. See \'\-s, \-\-set\' below for further info.
.TP
-.B RUN\-TIME BEHAVIOR OPTIONS:
+.B RUN-TIME BEHAVIOR OPTIONS:
.TP
.B \-q TYPE, \-\-quietmode=TYPE
Specifies that \fBsmartctl\fP should run in one of the two quiet modes
.I errorsonly
\- only print: For the \'\-l error\' option, if nonzero, the number
-of errors recorded in the SMART error log and the power\-on time when
+of errors recorded in the SMART error log and the power-on time when
they occurred; For the \'\-l selftest\' option, errors recorded in the device
-self\-test log; For the \'\-H\' option, SMART "disk failing" status or device
-Attributes (pre\-failure or usage) which failed either now or in the
-past; For the \'\-A\' option, device Attributes (pre\-failure or usage)
+self-test log; For the \'\-H\' option, SMART "disk failing" status or device
+Attributes (pre-failure or usage) which failed either now or in the
+past; For the \'\-A\' option, device Attributes (pre-failure or usage)
which failed either now or in the past.
.I silent
\- print no output. The only way to learn about what was found is to
-use the exit status of \fBsmartctl\fP (see RETURN VALUES below).
+use the exit status of \fBsmartctl\fP (see EXIT STATUS below).
.I noserial
\- Do not print the serial number of the device.
The valid arguments to this option are:
.I auto
-- attempt to guess the device type from the device name or from
+\- attempt to guess the device type from the device name or from
controller type info provided by the operating system or from
a matching USB ID entry in the drive database.
This is the default.
.I test
-- prints the guessed type, then opens the device and prints the
+\- prints the guessed type, then opens the device and prints the
(possibly changed) TYPE name and then exists without performing
any further commands.
\fBsmartctl\fP
from issuing SCSI commands to an ATA device.
+.\" %IF NOT OS Darwin
.I scsi
\- the device type is SCSI. This prevents
\fBsmartctl\fP
from issuing ATA commands to a SCSI device.
-.I sat
+.I sat[,auto][,N]
\- the device type is SCSI to ATA Translation (SAT).
This is for ATA disks that have a SCSI to ATA Translation (SAT) Layer
(SATL) between the disk and the operating system.
the other 16 bytes long. The default is the 16 byte variant which can be
overridden with either \'\-d sat,12\' or \'\-d sat,16\'.
+If \'\-d sat,auto\' is specified, device type SAT (for ATA/SATA disks) is
+only used if the SCSI INQUIRY data reports a SATL (VENDOR: "ATA ").
+Otherwise device type SCSI (for SCSI/SAS disks) is used.
+
.I usbcypress
\- this device type is for ATA disks that are behind a Cypress USB to PATA
bridge. This will use the ATACB proprietary scsi pass through command.
with \'\-d usbcypress,0xN\', where N is the scsi operation code,
you're running the risk of damage to the device or filesystems on it.
-.I usbjmicron
-- this device type is for SATA disks that are behind a JMicron USB to
+.I usbjmicron[,p][,x][,PORT]
+\- this device type is for SATA disks that are behind a JMicron USB to
PATA/SATA bridge. The 48-bit ATA commands (required e.g. for \'\-l xerror\',
see below) do not work with all of these bridges and are therefore disabled by
default. These commands can be enabled by \'\-d usbjmicron,x\'.
in I/O errors and may disconnect the drive. The same applies if the specified
PORT does not exist or is not connected to a disk.
+The Prolific PL2507/3507 USB bridges with older firmware support a pass-through
+command similar to JMicron and work with \'\-d usbjmicron,0\'.
+Newer Prolific firmware requires a modified command which can be selected by
+\'\-d usbjmicron,p\'.
+Note that this does not yet support the SMART status command.
+
+.I usbprolific
+\- [NEW EXPERIMENTAL SMARTCTL FEATURE]
+this device type is for SATA disks that are behind a Prolific PL2571/2771/2773/2775
+USB to SATA bridge.
+
.I usbsunplus
\- this device type is for SATA disks that are behind a SunplusIT USB to SATA
bridge.
+.\" %ENDIF NOT OS Darwin
+.\" %IF OS Linux
.I marvell
\- [Linux only] interact with SATA disks behind Marvell chip-set
controllers (using the Marvell rather than libata driver).
.nf
\fBsmartctl \-a \-d megaraid,0 /dev/sdb\fP
.fi
+.nf
+\fBsmartctl \-a \-d megaraid,0 /dev/bus/0\fP
+.fi
This interface will also work for Dell PERC controllers.
-The following /dev/XXX entry must exist:
+It is possible to set RAID device name as /dev/bus/N, where N is a SCSI bus
+number.
+
+The following entry in /proc/devices must exist:
+.br
+For PERC2/3/4 controllers: \fBmegadevN\fP
+.br
+For PERC5/6 controllers: \fBmegaraid_sas_ioctlN\fP
+
+.\" %ENDIF OS Linux
+.\" %IF OS Linux Windows Cygwin
+.I aacraid,H,L,ID
+\- [Linux, Windows and Cygwin only] [NEW EXPERIMENTAL SMARTCTL FEATURE]
+the device consists of one or more SCSI/SAS disks connected to an AacRaid controller.
+The non-negative integers H,L,ID (Host number, Lun, ID) denote which disk
+on the controller is monitored.
+Use syntax such as:
+.nf
+\fBsmartctl \-a \-d aacraid,0,0,2 /dev/sda\fP
.fi
-For PERC2/3/4 controllers: \fB/dev/megadev0\fP
+.nf
+\fBsmartctl \-a \-d aacraid,1,0,4 /dev/sdb\fP
.fi
-For PERC5/6 controllers: \fB/dev/megaraid_sas_ioctl_node\fP
+.\" %ENDIF OS Linux Windows Cygwin
+.\" %IF OS Linux
+On Linux, the following entry in /proc/devices must exist: \fBaac\fP.
+Character device nodes /dev/aacH (H=Host number) are created if required.
+
+.\" %ENDIF OS Linux
+.\" %IF OS Windows Cygwin
+On Windows, the device name parameter /dev/sdX is ignored if \'-d aacraid\'
+is specified.
+
+.\" %ENDIF OS Windows Cygwin
+.\" %IF OS FreeBSD Linux
.I 3ware,N
\- [FreeBSD and Linux only] the device consists of one or more ATA disks
connected to a 3ware RAID controller. The non-negative integer N
is monitored.
Use syntax such as:
.nf
-\fBsmartctl \-a \-d 3ware,2 /dev/sda\fP
+\fBsmartctl \-a \-d 3ware,2 /dev/sda\fP [Linux only]
.fi
.nf
\fBsmartctl \-a \-d 3ware,0 /dev/twe0\fP
\fBsmartctl \-a \-d 3ware,1 /dev/twa0\fP
.fi
.nf
-\fBsmartctl \-a \-d 3ware,1 /dev/twl0\fP
+\fBsmartctl \-a \-d 3ware,1 /dev/twl0\fP [Linux only]
+.fi
+.nf
+\fBsmartctl \-a \-d 3ware,1 /dev/tws0\fP [FreeBSD only]
.fi
The first two forms, which refer to devices /dev/sda\-z and /dev/twe0\-15,
may be used with 3ware series 6000, 7000, and 8000 series controllers
-that use the 3x\-xxxx driver.
+that use the 3x-xxxx driver.
\fBNote that the /dev/sda\-z form is deprecated\fP starting with
the Linux 2.6 kernel series and may not be supported by the Linux
kernel in the near future. The final form, which refers to devices
/dev/twa0\-15, must be used with 3ware 9000 series controllers, which
use the 3w\-9xxx driver.
-The devices /dev/twl0\-15 must be used with the 3ware/LSI 9750 series
+The devices /dev/twl0\-15 [Linux] or /dev/tws0\-15 [FreeBSD] must be used with the 3ware/LSI 9750 series
controllers which use the 3w-sas driver.
-Note that if the special character device nodes /dev/twl?, /dev/twa?
+Note that if the special character device nodes /dev/tw[ls]?, /dev/twa?
and /dev/twe? do not exist, or exist with the incorrect major or minor
numbers, smartctl will recreate them on the fly. Typically /dev/twa0
-refers to the first 9000\-series controller, /dev/twa1 refers to the
+refers to the first 9000-series controller, /dev/twa1 refers to the
second 9000 series controller, and so on. The /dev/twl0 devices refers
to the first 9750 series controller, /dev/twl1 resfers to the second
9750 series controller, and so on. Likewise /dev/twe0 refers to
-the first 6/7/8000\-series controller, /dev/twe1 refers to the second
+the first 6/7/8000-series controller, /dev/twe1 refers to the second
6/7/8000 series controller, and so on.
Note that for the 6/7/8000 controllers, \fBany\fP of the physical
specific controller model, firmware, Linux kernel and platform. In
some cases you will get a warning message that the device does not
exist. In other cases you will be presented with \'void\' data for a
-non\-existent device.
+non-existent device.
-Note that if the /dev/sd? addressing form is used, then older 3w\-xxxx
+Note that if the /dev/sd? addressing form is used, then older 3w-xxxx
drivers do not pass the "Enable Autosave"
(\'\fB\-S on\fP\') and "Enable Automatic Offline" (\'\fB\-o on\fP\')
commands to the disk, and produce these types of harmless syslog error
-messages instead: "\fB3w\-xxxx: tw_ioctl(): Passthru size (123392) too
+messages instead: "\fB3w-xxxx: tw_ioctl(): Passthru size (123392) too
big\fP". This can be fixed by upgrading to version 1.02.00.037 or
-later of the 3w\-xxxx driver, or by applying a patch to older
+later of the 3w-xxxx driver, or by applying a patch to older
versions. Alternatively, use the character device /dev/twe0\-15 interface.
-The selective self\-test functions (\'\-t select,A\-B\') are only supported
-using the character device interface /dev/twl0\-15, /dev/twa0\-15 and /dev/twe0\-15.
+The selective self-test functions (\'\-t select,A\-B\') are only supported
+using the character device interface /dev/twl0\-15, /dev/tws0\-15, /dev/twa0\-15 and /dev/twe0\-15.
The necessary WRITE LOG commands can not be passed through the SCSI
interface.
+.\" %ENDIF OS FreeBSD Linux
+.\" %IF OS FreeBSD Linux Windows Cygwin
.I areca,N
-\- [Linux only] the device consists of one or more SATA disks connected to an
-Areca SATA RAID controller. The positive integer N (in the range from 1 to
-24 inclusive) denotes which disk on the controller is monitored.
-Use syntax such as:
+\- [FreeBSD, Linux, Windows and Cygwin only] the device consists of one or more SATA disks
+connected to an Areca SATA RAID controller. The positive integer N (in the range
+from 1 to 24 inclusive) denotes which disk on the controller is monitored.
+.\" %ENDIF OS FreeBSD Linux Windows Cygwin
+.\" %IF OS Linux
+On Linux use syntax such as:
.nf
\fBsmartctl \-a \-d areca,2 /dev/sg2\fP
.fi
.nf
\fBsmartctl \-a \-d areca,3 /dev/sg3\fP
.fi
+.\" %ENDIF OS Linux
+.\" %IF OS FreeBSD
+On FreeBSD use syntax such as:
+.nf
+\fBsmartctl \-a \-d areca,2 /dev/arcmsr1\fP
+.fi
+.nf
+\fBsmartctl \-a \-d areca,3 /dev/arcmsr2\fP
+.fi
+.\" %ENDIF OS FreeBSD
+.\" %IF OS Windows Cygwin
+On Windows and Cygwin use syntax such as:
+.nf
+\fBsmartctl \-a \-d areca,2 /dev/arcmsr0\fP
+.fi
+.nf
+\fBsmartctl \-a \-d areca,3 /dev/arcmsr1\fP
+.fi
+.\" %ENDIF OS Windows Cygwin
+.\" %IF OS FreeBSD Linux Windows Cygwin
The first line above addresses the second disk on the first Areca RAID controller.
The second line addresses the third disk on the second Areca RAID
-controller. To help identify the correct device, use the command:
+controller.
+.\" %ENDIF OS FreeBSD Linux Windows Cygwin
+.\" %IF OS Linux
+To help identify the correct device on Linux, use the command:
.nf
\fBcat /proc/scsi/sg/device_hdr /proc/scsi/sg/devices\fP
.fi
smartmontools are the ones with the type field equal to 3. If the
incorrect device is addressed, please read the warning/error messages
carefully. They should provide hints about what devices to use.
+.\" %ENDIF OS Linux
+.\" %IF OS FreeBSD Linux Windows Cygwin
Important: the Areca controller must have firmware version 1.46 or
later. Lower-numbered firmware versions will give (harmless) SCSI
error messages and no SMART information.
+.I areca,N/E
+\- [FreeBSD, Linux, Windows and Cygwin only] the device consists of one
+or more SATA or SAS disks connected to an Areca SAS RAID controller.
+The integer N (range 1 to 128) denotes the channel (slot) and E (range
+1 to 8) denotes the enclosure.
+Important: This requires Areca SAS controller firmware version 1.51 or later.
+
+.\" %ENDIF OS FreeBSD Linux Windows Cygwin
+.\" %IF OS FreeBSD Linux
.I cciss,N
-\- [FreeBSD and Linux only] the device consists of one or more SCSI/SAS disks
+\- [FreeBSD and Linux only] the device consists of one or more SCSI/SAS or SATA disks
connected to a cciss RAID controller. The non-negative integer N (in the range
from 0 to 15 inclusive) denotes which disk on the controller is monitored.
-If the controller firmware or driver provides a SAT Layer it may be possible
-to monitor also SATA disks by specifiying \'\-d sat+cciss,N\'.
+To look at disks behind HP Smart Array controllers, use syntax
+such as:
+.\" %ENDIF OS FreeBSD Linux
+.\" %IF OS Linux
+.nf
+\fBsmartctl \-a \-d cciss,0 /dev/cciss/c0d0\fP (cciss driver under Linux)
+.fi
+.nf
+\fBsmartctl \-a \-d cciss,0 /dev/sg2\fP (hpsa or hpahcisr drivers under Linux)
+.fi
+.\" %ENDIF OS Linux
+.\" %IF OS FreeBSD
+.nf
+\fBsmartctl \-a \-d cciss,0 /dev/ciss0\fP (under FreeBSD)
+.fi
+.\" %ENDIF OS FreeBSD
+.\" %IF OS FreeBSD Linux
.I hpt,L/M/N
\- [FreeBSD and Linux only] the device consists of one or more ATA disks
connected to a HighPoint RocketRAID controller. The integer L is the
controller id, the integer M is the channel number, and the integer N
is the PMPort number if it is available. The allowed values of L are
-from 1 to 4 inclusive, M are from 1 to 8 inclusive and N from 1 to 4
+from 1 to 4 inclusive, M are from 1 to 128 inclusive and N from 1 to 4
if PMPort available. And also these values are limited by the model
of the HighPoint RocketRAID controller.
Use syntax such as:
+.\" %ENDIF OS FreeBSD Linux
+.\" %IF OS Linux
.nf
\fBsmartctl \-a \-d hpt,1/3 /dev/sda\fP (under Linux)
.fi
.nf
\fBsmartctl \-a \-d hpt,1/2/3 /dev/sda\fP (under Linux)
.fi
+.\" %ENDIF OS Linux
+.\" %IF OS FreeBSD
.nf
\fBsmartctl \-a \-d hpt,1/3 /dev/hptrr\fP (under FreeBSD)
.fi
.nf
\fBsmartctl \-a \-d hpt,1/2/3 /dev/hptrr\fP (under FreeBSD)
.fi
+.\" %ENDIF OS FreeBSD
+.\" %IF OS FreeBSD Linux
Note that the /dev/sda\-z form should be the device node which stands for
the disks derived from the HighPoint RocketRAID controllers under Linux and
under FreeBSD, it is the character device which the driver registered (eg,
/dev/hptrr, /dev/hptmv6).
+.\" %ENDIF OS FreeBSD Linux
.TP
.B \-T TYPE, \-\-tolerance=TYPE
[ATA only] Specifies how tolerant \fBsmartctl\fP should be of ATA and SMART
The behavior of \fBsmartctl\fP depends upon whether the command is
"\fBoptional\fP" or "\fBmandatory\fP". Here "\fBmandatory\fP" means
-"required by the ATA/ATAPI\-5 Specification if the device implements
+"required by the ATA Specification if the device implements
the SMART command set" and "\fBoptional\fP" means "not required by the
-ATA/ATAPI\-5 Specification even if the device implements the SMART
+ATA Specification even if the device implements the SMART
command set." The "\fBmandatory\fP" ATA and SMART commands are: (1)
ATA IDENTIFY DEVICE, (2) SMART ENABLE/DISABLE ATTRIBUTE AUTOSAVE, (3)
SMART ENABLE/DISABLE, and (4) SMART RETURN STATUS.
\- ignore failure(s) of \fBmandatory\fP SMART commands. This option
may be given more than once. Each additional use of this option will
cause one more additional failure to be ignored. Note that the use of
-this option can lead to messages like "Feature X not implemented",
-followed shortly by "Error: unable to enable Feature X". In a few
+this option can lead to messages like "Feature X not supported",
+followed shortly by "Feature X enable failed". In a few
such cases, contrary to the final message, Feature X \fBis\fP enabled.
.I verypermissive
.B \-b TYPE, \-\-badsum=TYPE
[ATA only] Specifies the action \fBsmartctl\fP should take if a checksum
error is detected in the: (1) Device Identity Structure, (2) SMART
-Self\-Test Log Structure, (3) SMART Attribute Value Structure, (4) SMART
+Self-Test Log Structure, (3) SMART Attribute Value Structure, (4) SMART
Attribute Threshold Structure, or (5) ATA Error Log Structure.
The valid arguments to this option are:
.TP
.B \-r TYPE, \-\-report=TYPE
Intended primarily to help \fBsmartmontools\fP developers understand
-the behavior of \fBsmartmontools\fP on non\-conforming or poorly
+the behavior of \fBsmartmontools\fP on non-conforming or poorly
conforming hardware. This option reports details of \fBsmartctl\fP
transactions with the device. The option can be used multiple times.
When used just once, it shows a record of the ioctl() transactions
.TP
.B \-n POWERMODE, \-\-nocheck=POWERMODE
[ATA only] Specifies if \fBsmartctl\fP should exit before performing any
-checks when the device is in a low\-power mode. It may be used to prevent
-a disk from being spun\-up by \fBsmartctl\fP. The power mode is ignored by
+checks when the device is in a low-power mode. It may be used to prevent
+a disk from being spun-up by \fBsmartctl\fP. The power mode is ignored by
default. A nonzero exit status is returned if the device is in one of the
-specified low\-power modes (see RETURN VALUES below).
+specified low-power modes (see EXIT STATUS below).
Note: If this option is used it may also be necessary to specify the device
-type with the \'-d\' option. Otherwise the device may spin up due to
+type with the \'\-d\' option. Otherwise the device may spin up due to
commands issued during device type autodetection.
The valid arguments to this option are:
Enables or disables SMART on device. The valid arguments to
this option are \fIon\fP and \fIoff\fP. Note that the command \'\-s on\'
(perhaps used with with the \'\-o on\' and \'\-S on\' options) should be
-placed in a start\-up script for your machine, for example in rc.local or
+placed in a start-up script for your machine, for example in rc.local or
rc.sysinit. In principle the SMART feature settings are preserved over
-power\-cycling, but it doesn\'t hurt to be sure. It is not necessary (or
+power-cycling, but it doesn\'t hurt to be sure. It is not necessary (or
useful) to enable SMART to see the TapeAlert messages.
.TP
.B \-o VALUE, \-\-offlineauto=VALUE
Note that the SMART automatic offline test command is listed as
"Obsolete" in every version of the ATA and ATA/ATAPI Specifications.
-It was originally part of the SFF\-8035i Revision 2.0 specification,
+It was originally part of the SFF-8035i Revision 2.0 specification,
but was never part of any ATA specification. However it is
-implemented and used by many vendors. [Good documentation can be found
-in IBM\'s Official Published Disk Specifications. For example the IBM
-Travelstar 40GNX Hard Disk Drive Specifications (Revision 1.1, 22
-April 2002, Publication # 1541, Document S07N\-7715\-02) page 164. You
-can also read the SFF\-8035i Specification \-\- see REFERENCES below.]
+implemented and used by many vendors.
You can tell if automatic offline testing is supported by seeing if
this command enables and disables it, as indicated by the \'Auto
Offline Data Collection\' part of the SMART capabilities report
automatically, on a regular scheduled basis. Normally, the disk will
suspend offline testing while disk accesses are taking place, and then
automatically resume it when the disk would otherwise be idle, so in
-practice it has little effect. Note that a one\-time offline test can
+practice it has little effect. Note that a one-time offline test can
also be carried out immediately upon receipt of a user command. See
-the \'\-t offline\' option below, which causes a one\-time offline test
+the \'\-t offline\' option below, which causes a one-time offline test
to be carried out immediately.
-The choice (made by the SFF\-8035i and ATA specification authors) of
+The choice (made by the SFF-8035i and ATA specification authors) of
the word \fItesting\fP for these first two categories is unfortunate,
and often leads to confusion. In fact these first two categories of
online and offline testing could have been more accurately described
errors may also appear in the SMART error log. These are visible with
the \'\-A\' and \'\-l error\' options respectively.
-Some SMART attribute values are updated only during off\-line data
+Some SMART attribute values are updated only during off-line data
collection activities; the rest are updated during normal operation of
-the device or during both normal operation and off\-line testing. The
+the device or during both normal operation and off-line testing. The
Attribute value table produced by the \'\-A\' option indicates this in
the UPDATED column. Attributes of the first type are labeled
"Offline" and Attributes of the second type are labeled "Always".
which the word \'testing\' is really an appropriate choice) is "self"
testing. This third type of test is only performed (immediately) when
a command to run it is issued. The \'\-t\' and \'\-X\' options can be
-used to carry out and abort such self\-tests; please see below for
+used to carry out and abort such self-tests; please see below for
further details.
Any errors detected in the self testing will be shown in the
-SMART self\-test log, which can be examined using the \'\-l selftest\'
+SMART self-test log, which can be examined using the \'\-l selftest\'
option.
\fBNote:\fP in this manual page, the word \fB"Test"\fP is used in
connection with the second category just described, e.g. for the
-"offline" testing. The words \fB"Self\-test"\fP are used in
+"offline" testing. The words \fB"Self-test"\fP are used in
connection with the third category.
.TP
.B \-S VALUE, \-\-saveauto=VALUE
-[ATA] Enables or disables SMART autosave of device vendor\-specific
+[ATA] Enables or disables SMART autosave of device vendor-specific
Attributes. The valid arguments to this option are \fIon\fP
and \fIoff\fP. Note that this feature is preserved across disk power
cycles, so you should only need to issue it once.
[SCSI] For SCSI devices this toggles the value of the Global Logging
Target Save Disabled (GLTSD) bit in the Control Mode Page. Some disk
manufacturers set this bit by default. This prevents error counters,
-power\-up hours and other useful data from being placed in non\-volatile
+power-up hours and other useful data from being placed in non-volatile
storage, so these values may be reset to zero the next time the device
-is power\-cycled. If the GLTSD bit is set then \'smartctl \-a\' will
+is power-cycled. If the GLTSD bit is set then \'smartctl \-a\' will
issue a warning. Use \fIon\fP to clear the GLTSD bit and thus enable
-saving counters to non\-volatile storage. For extreme streaming\-video
+saving counters to non-volatile storage. For extreme streaming-video
type applications you might consider using \fIoff\fP to set the GLTSD
bit.
+.TP
+.B \-g NAME, \-\-get=NAME, \-s NAME[,VALUE], \-\-set=NAME[,VALUE]
+Gets/sets non-SMART device settings.
+Note that the \'\-\-set\' option shares its short option \'\-s\' with
+\'\-\-smart\'. Valid arguments are:
+
+.I all
+\- Gets all values. This is equivalent to
+.nf
+\'-g aam -g apm -g lookahead -g security -g wcache\'
+.fi
+
+.I aam[,N|off]
+\- [ATA only] Gets/sets the Automatic Acoustic Management (AAM) feature
+(if supported). A value of 128 sets the most quiet (slowest) mode and 254
+the fastest (loudest) mode, \'off\' disables AAM. Devices may support
+intermediate levels. Values below 128 are defined as vendor specific (0)
+or retired (1 to 127). Note that the AAM feature was declared obsolete in
+ATA ACS-2 Revision 4a (Dec 2010).
+
+.I apm[,N|off]
+\- [ATA only] Gets/sets the Advanced Power Management (APM) feature on
+device (if supported). If a value between 1 and 254 is provided, it will
+attempt to enable APM and set the specified value, \'off\' disables APM.
+Note the actual behavior depends on the drive, for example some drives disable
+APM if their value is set above 128. Values below 128 are supposed to allow
+drive spindown, values 128 and above adjust only head-parking frequency,
+although the actual behavior defined is also vendor-specific.
+
+.I lookahead[,on|off]
+\- [ATA only] Gets/sets the read look-ahead feature (if supported).
+Read look-ahead is usually enabled by default.
+
+.I security
+\- [ATA only] Gets the status of ATA Security feature (if supported).
+If ATA Security is enabled an ATA user password is set. The drive will be
+locked on next reset then.
+
+.I security-freeze
+\- [ATA only] Sets ATA Security feature to frozen mode. This prevents that
+the drive accepts any security commands until next reset. Note that the
+frozen mode may already be set by BIOS or OS.
+
+.I standby,[N|off]
+\- [ATA only] Sets the standby (spindown) timer and places the drive in the
+IDLE mode. A value of 0 or \'off\' disables the standby timer.
+Values from 1 to 240 specify timeouts from 5 seconds to 20 minutes in 5
+second increments. Values from 241 to 251 specify timeouts from 30 minutes
+to 330 minutes in 30 minute increments. Value 252 specifies 21 minutes.
+Value 253 specifies a vendor specific time between 8 and 12 hours. Value
+255 specifies 21 minutes and 15 seconds. Some drives may use a vendor
+specific interpretation for the values. Note that there is no get option
+because ATA standards do not specify a method to read the standby timer.
+
+.I standby,now
+\- [ATA only] Places the drive in the STANDBY mode. This usually spins down
+the drive. The setting of the standby timer is not affected.
+
+.I wcache[,on|off]
+\- [ATA] Gets/sets the volatile write cache feature (if supported).
+The write cache is usually enabled by default.
+
+.I wcache[,on|off]
+\- [SCSI] Gets/sets the \'Write Cache Enable\' (WCE) bit (if supported).
+The write cache is usually enabled by default.
+
+.I wcreorder[,on|off]
+\- [ATA only] Gets/sets Write Cache Reordering.
+If it is disabled (off), disk write scheduling is executed on a
+first-in-first-out (FIFO) basis. If Write Cache Reordering is enabled (on),
+then disk write scheduling may be reordered by the drive. If write cache is
+disabled, the current Write Cache Reordering state is remembered but has
+no effect on non-cached writes, which are always written in the order received.
+The state of Write Cache Reordering has no effect on either NCQ or LCQ queued
+commands.
+
+.I rcache[,on|off]
+\- [SCSI only] Gets/sets the \'Read Cache Disable\' (RCE) bit.
+\'Off\' value disables read cache (if supported).
+The read cache is usually enabled by default.
.TP
.B SMART READ AND DISPLAY DATA OPTIONS:
.TP
.B \-H, \-\-health
-Check: Ask the device to report its SMART health status or pending
-TapeAlert messages. SMART status is based on
-information that it has gathered from online and offline
-tests, which were used to determine/update its
-SMART vendor\-specific Attribute values. TapeAlert status is obtained
-by reading the TapeAlert log page.
+Prints the health status of the device or pending TapeAlert messages.
If the device reports failing health status, this means
.B either
that it is predicting its own failure within the next 24 hours. If
this happens, use the \'\-a\' option to get more information, and
.B get your data off the disk and to someplace safe as soon as you can.
+
+[ATA] Health status is obtained by checking the (boolean) result returned
+by the SMART RETURN STATUS command.
+The return value of this ATA command may be unknown due to limitations or
+bugs in some layer (e.g. RAID controller or USB bridge firmware) between
+disk and operating system.
+In this case, \fBsmartctl\fP prints a warning and checks whether any
+Prefailure SMART Attribute value is less than or equal to its threshold
+(see \'\-A\' below).
+
+[SCSI] Health status is obtained by checking the Additional Sense Code
+(ASC) and Additional Sense Code Qualifier (ASCQ) from Informal Exceptions
+(IE) log page (if supported) and/or from SCSI sense data.
+
+[SCSI tape drive or changer] TapeAlert status is obtained by reading the
+TapeAlert log page.
+Please note that the TapeAlert log page flags are cleared for the initiator
+when the page is read.
+This means that each alert condition is reported only once by \fBsmartctl\fP
+for each initiator for each activation of the condition.
.TP
.B \-c, \-\-capabilities
[ATA only] Prints only the generic SMART capabilities. These
show what SMART features are implemented and how the device will
respond to some of the different SMART commands. For example it
shows if the device logs errors, if it supports offline surface
-scanning, and so on. If the device can carry out self\-tests, this
+scanning, and so on. If the device can carry out self-tests, this
option also shows the estimated time required to run those tests.
-Note that the time required to run the Self\-tests (listed in minutes)
+Note that the time required to run the Self-tests (listed in minutes)
are fixed. However the time required to run the Immediate Offline
Test (listed in seconds) is variable. This means that if you issue a
command to perform an Immediate Offline test with the \'\-t offline\' option,
Each Attribute has a "Raw" value, printed under the heading
"RAW_VALUE", and a "Normalized" value printed under the heading
-"VALUE". [Note: \fBsmartctl\fP prints these values in base\-10.] In
+"VALUE". [Note: \fBsmartctl\fP prints these values in base-10.] In
the example just given, the "Raw Value" for Attribute 12 would be the
-actual number of times that the disk has been power\-cycled, for
+actual number of times that the disk has been power-cycled, for
example 365 if the disk has been turned on once per day for exactly
one year. Each vendor uses their own algorithm to convert this "Raw"
value to a "Normalized" value in the range from 1 to 254. Please keep
by \fBsmartctl\fP are sensible. For example the temperature Attribute
generally has its raw value equal to the temperature in Celsius.
However in some cases vendors use unusual conventions. For example
-the Hitachi disk on my laptop reports its power\-on hours in minutes,
+the Hitachi disk on my laptop reports its power-on hours in minutes,
not hours. Some IBM disks track three temperatures rather than one, in
their raw values. And so on.
Each Attribute also has a Threshold value (whose range is 0 to 255)
which is printed under the heading "THRESH". If the Normalized value
is \fBless than or equal to\fP the Threshold value, then the Attribute
-is said to have failed. If the Attribute is a pre\-failure Attribute,
+is said to have failed. If the Attribute is a pre-failure Attribute,
then disk failure is imminent.
Each Attribute also has a "Worst" value shown under the heading
"WORST". This is the smallest (closest to failure) value that the
disk has recorded at any time during its lifetime when SMART was
enabled. [Note however that some vendors firmware may actually
-\fBincrease\fP the "Worst" value for some "rate\-type" Attributes.]
+\fBincrease\fP the "Worst" value for some "rate-type" Attributes.]
The Attribute table printed out by \fBsmartctl\fP also shows the
"TYPE" of the Attribute. Attributes are one of two possible types:
-Pre\-failure or Old age. Pre\-failure Attributes are ones which, if
+Pre-failure or Old age. Pre-failure Attributes are ones which, if
less than or equal to their threshold values, indicate pending disk
failure. Old age, or usage Attributes, are ones which indicate
-end\-of\-product life from old\-age or normal aging and wearout, if
+end-of-product life from old-age or normal aging and wearout, if
the Attribute value is less than or equal to the threshold. \fBPlease
-note\fP: the fact that an Attribute is of type 'Pre\-fail' does
+note\fP: the fact that an Attribute is of type 'Pre-fail' does
\fBnot\fP mean that your disk is about to fail! It only has this
meaning if the Attribute\'s current Normalized value is less than or
equal to the threshold value.
also never failed in the past.
The table column labeled "UPDATED" shows if the SMART Attribute values
-are updated during both normal operation and off\-line testing, or
+are updated during both normal operation and off-line testing, or
only during offline testing. The former are labeled "Always" and the
latter are labeled "Offline".
So to summarize: the Raw Attribute values are the ones that might have
a real physical interpretation, such as "Temperature Celsius",
-"Hours", or "Start\-Stop Cycles". Each manufacturer converts these,
+"Hours", or "Start-Stop Cycles". Each manufacturer converts these,
using their detailed knowledge of the disk\'s operations and failure
modes, to Normalized Attribute values in the range 1\-254. The
current and worst (lowest measured) of these Normalized Attribute
thresholds, or types, it merely reports them from the SMART data on
the device.
-Note that starting with ATA/ATAPI\-4, revision 4, the meaning of these
-Attribute fields has been made entirely vendor\-specific. However most
-ATA/ATAPI\-5 disks seem to respect their meaning, so we have retained
+Note that starting with ATA/ATAPI-4, revision 4, the meaning of these
+Attribute fields has been made entirely vendor-specific. However most
+newer ATA/SATA disks seem to respect their meaning, so we have retained
the option of printing the Attribute values.
+Solid-state drives use different meanings for some of the attributes.
+In this case the attribute name printed by smartctl is incorrect unless
+the drive is already in the smartmontools drive database.
+
[SCSI] For SCSI devices the "attributes" are obtained from the temperature
-and start\-stop cycle counter log pages. Certain vendor specific
+and start-stop cycle counter log pages. Certain vendor specific
attributes are listed if recognised. The attributes are output in a
relatively free format (compared with ATA disk attributes).
.TP
+.B \-f FORMAT, \-\-format=FORMAT
+[ATA only] Selects the output format of the attributes:
+
+.I old
+\- Old smartctl format. This is the default unless the \'\-x\' option is
+specified.
+
+.I brief
+\- New format which fits into 80 colums (except in some rare cases).
+This format also decodes four additional attribute flags.
+This is the default if the '\-x\' option is specified.
+
+.I hex,id
+\- Print all attribute IDs as hexadecimal numbers.
+
+.I hex,val
+\- Print all normalized values as hexadecimal numbers.
+
+.I hex
+\- Same as \'\-f hex,id \-f hex,val\'.
+.TP
.B \-l TYPE, \-\-log=TYPE
-Prints either the SMART Error Log, the SMART Self\-Test Log, the SMART
-Selective Self\-Test Log [ATA only], the Log Directory [ATA only], or
+Prints either the SMART Error Log, the SMART Self-Test Log, the SMART
+Selective Self-Test Log [ATA only], the Log Directory [ATA only], or
the Background Scan Results Log [SCSI only].
The valid arguments to this option are:
.I error
\- [ATA] prints the Summary SMART error log. SMART disks maintain a log
-of the most recent five non\-trivial errors. For each of these errors, the
-disk power\-on lifetime at which the error occurred is recorded, as is
+of the most recent five non-trivial errors. For each of these errors, the
+disk power-on lifetime at which the error occurred is recorded, as is
the device status (idle, standby, etc) at the time of the error. For
some common types of errors, the Error Register (ER) and Status
Register (SR) values are decoded and printed as text. The meanings of these
\fBEOM\fP: \fBE\fPnd \fBO\fPf \fBM\fPedia
\fBICRC\fP: \fBI\fPnterface \fBC\fPyclic \fBR\fPedundancy \fBC\fPode (CRC) error
\fBIDNF\fP: \fBID\fPentity \fBN\fPot \fBF\fPound
- \fBILI\fP: (packet command\-set specific)
+ \fBILI\fP: (packet command-set specific)
\fBMC\fP: \fBM\fPedia \fBC\fPhanged
\fBMCR\fP: \fBM\fPedia \fBC\fPhange \fBR\fPequest
\fBNM\fP: \fBN\fPo \fBM\fPedia
minutes, SS is seconds and msec is milliseconds. [Note: this time
stamp wraps after 2^32 milliseconds, or 49 days 17 hours 2 minutes and
47.296 seconds.] The key ATA disk registers are also recorded in the
-log. The final column of the error log is a text\-string description
+log. The final column of the error log is a text-string description
of the ATA command defined by the Command Register (CR) and Feature
Register (FR) values. Commands that are obsolete in the most current
-(ATA\-7) spec are listed like this: \fBREAD LONG (w/ retry) [OBS\-4]\fP,
-indicating that the command became obsolete with or in the ATA\-4
+spec are listed like this: \fBREAD LONG (w/ retry) [OBS-4]\fP,
+indicating that the command became obsolete with or in the ATA-4
specification. Similarly, the notation \fB[RET\-\fP\fIN\fP\fB]\fP is
-used to indicate that a command was retired in the ATA\-\fIN\fP
+used to indicate that a command was retired in the ATA-\fIN\fP
specification. Some commands are not defined in any version of the
ATA specification but are in common use nonetheless; these are marked
-\fB[NS]\fP, meaning non\-standard.
-
-The ATA Specification (ATA\-5 Revision 1c, Section 8.41.6.8.2) says:
-\fB"Error log structures shall include UNC errors, IDNF errors for
-which the address requested was valid, servo errors, write fault
-errors, etc. Error log data structures shall not include errors
-attributed to the receipt of faulty commands such as command codes not
-implemented by the device or requests with invalid parameters or
-invalid addresses."\fP The definitions of these terms are:
+\fB[NS]\fP, meaning non-standard.
+
+The ATA Specification (ATA ACS-2 Revision 7, Section A.7.1) says:
+\fB"Error log data structures shall include, but are not limited to,
+Uncorrectable errors, ID Not Found errors for which the LBA requested was
+valid, servo errors, and write fault errors. Error log data structures
+shall not include errors attributed to the receipt of faulty commands."\fP
+The definitions of these terms are:
.br
\fBUNC\fP (\fBUNC\fPorrectable): data is uncorrectable. This refers
to data which has been read from the disk, but for which the Error
Checking and Correction (ECC) codes are inconsistent. In effect, this
means that the data can not be read.
.br
-\fBIDNF\fP (\fBID N\fPot \fBF\fPound): user\-accessible address could
+\fBIDNF\fP (\fBID N\fPot \fBF\fPound): user-accessible address could
not be found. For READ LOG type commands, \fBIDNF\fP can also indicate
that a device data log structure checksum was incorrect.
If the command that caused the error was a READ or WRITE command, then
the Logical Block Address (LBA) at which the error occurred will be
printed in base 10 and base 16. The LBA is a linear address, which
-counts 512\-byte sectors on the disk, starting from zero. (Because of
+counts 512-byte sectors on the disk, starting from zero. (Because of
the limitations of the SMART error log, if the LBA is greater than
0xfffffff, then either no error log entry will be made, or the error
log entry will have an incorrect LBA. This may happen for drives with
the contents of the 48-bit LBA register set introduced with ATA-6.
It also supports logs with more than one sector. Each sector holds
up to 4 log entries. The actual number of log sectors is vendor
-specific, typical values for HDD are 2 (Samsung), 5 (Seagate) or
-6 (WD). Some recent SSD devices have much larger error logs.
+specific.
Only the 8 most recent error log entries are printed by default.
This number can be changed by the optional parameter NUM.
If ',error' is appended and the Extended Comprehensive SMART error
log is not supported, the Summary SMART self-test log is printed.
-Please note that some recent (e.g. Samsung) drives report errors only
-in the Extended Comprehensive SMART error log. The Summary SMART error
-log can be read but is always empty.
+Please note that recent drives may report errors only in the Extended
+Comprehensive SMART error log. The Summary SMART error log may be reported
+as supported but is always empty then.
.I selftest
-\- [ATA] prints the SMART self\-test log. The disk maintains a self\-test
+\- [ATA] prints the SMART self-test log. The disk maintains a self-test
log showing the results of the self tests, which can be run using the
\'\-t\' option described below. For each of the most recent
-twenty\-one self\-tests, the log shows the type of test (short or
-extended, off\-line or captive) and the final status of the test. If
+twenty-one self-tests, the log shows the type of test (short or
+extended, off-line or captive) and the final status of the test. If
the test did not complete successfully, then the percentage of the
test remaining is shown. The time at which the test took place,
measured in hours of disk lifetime, is also printed. [Note: this time
address to the name of the disk file containing the erroneous block.
.I selftest
-\- [SCSI] the self\-test log for a SCSI device has a slightly different
+\- [SCSI] the self-test log for a SCSI device has a slightly different
format than for an ATA device. For each of the most recent twenty
-self\-tests, it shows the type of test and the status (final or in
+self-tests, it shows the type of test and the status (final or in
progress) of the test. SCSI standards use the terms "foreground" and
"background" (rather than ATA\'s corresponding "captive" and
-"off\-line") and "short" and "long" (rather than ATA\'s corresponding
+"off-line") and "short" and "long" (rather than ATA\'s corresponding
"short" and "extended") to describe the type of the test. The printed
segment number is only relevant when a test fails in the third or
later test segment. It identifies the test that failed and consists
of either the number of the segment that failed during the test, or
the number of the test that failed and the number of the segment in
-which the test was run, using a vendor\-specific method of putting both
+which the test was run, using a vendor-specific method of putting both
numbers into a single byte. The Logical Block Address (LBA) of the
first error is printed in hexadecimal notation. On Linux systems the
smartmontools web page has instructions about how to convert this LBA
test terminology).
.I xselftest[,NUM][,selftest]
-\- [ATA only] prints the Extended SMART self\-test log (General Purpose
-Log address 0x07). Unlike the SMART self\-test log (see \'\-l selftest\'
+\- [ATA only] prints the Extended SMART self-test log (General Purpose
+Log address 0x07). Unlike the SMART self-test log (see \'\-l selftest\'
above), it supports 48-bit LBA and logs with more than one sector.
Each sector holds up to 19 log entries. The actual number of log sectors
-is vendor specific, typical values are 1 (Seagate) or 2 (Samsung).
+is vendor specific.
Only the 25 most recent log entries are printed by default. This number
can be changed by the optional parameter NUM.
.I selective
\- [ATA only] Please see the \'\-t select\' option below for a
-description of selective self\-tests. The selective self\-test log
+description of selective self-tests. The selective self-test log
shows the start/end Logical Block Addresses (LBA) of each of the five
test spans, and their current test status. If the span is being
-tested or the remainder of the disk is being read\-scanned, the
-current 65536\-sector block of LBAs being tested is also displayed.
-The selective self\-test log also shows if a read\-scan of the
+tested or the remainder of the disk is being read-scanned, the
+current 65536-sector block of LBAs being tested is also displayed.
+The selective self-test log also shows if a read-scan of the
remainder of the disk will be carried out after the selective
-self\-test has completed (see \'\-t afterselect\' option) and the time
-delay before restarting this read\-scan if it is interrupted (see
-\'\-t pending\' option). This is a new smartmontools feature; please
-report unusual or incorrect behavior to the smartmontools\-support
-mailing list.
+self-test has completed (see \'\-t afterselect\' option) and the time
+delay before restarting this read-scan if it is interrupted (see
+\'\-t pending\' option).
.I directory[,gs]
\- [ATA only] if the device supports the General Purpose Logging feature
-set (ATA\-6 and above) then this prints the Log Directory (the log at
+set (ATA-6 and above) then this prints the Log Directory (the log at
address 0). The Log Directory shows what logs are available and their
length in sectors (512 bytes). The contents of the logs at address 1
-[Summary SMART error log] and at address 6 [SMART self\-test log] may
-be printed using the previously\-described
+[Summary SMART error log] and at address 6 [SMART self-test log] may
+be printed using the previously-described
.I error
and
.I selftest
.I background
\- [SCSI only] the background scan results log outputs information derived
-from Background Media Scans (BMS) done after power up and/or periodocally
+from Background Media Scans (BMS) done after power up and/or periodically
(e.g. every 24 hours) on recent SCSI disks. If supported, the BMS status
is output first, indicating whether a background scan is currently
underway (and if so a progress percentage), the amount of time the disk
is a header and a line for each background scan "event". These will
typically be either recovered or unrecoverable errors. That latter group
may need some attention. There is a description of the background scan
-mechansim in section 4.18 of SBC\-3 revision 6 (see www.t10.org ).
+mechanism in section 4.18 of SBC-3 revision 6 (see www.t10.org ).
.I scttemp, scttempsts, scttemphist
\- [ATA only] prints the disk temperature information provided by the
temperature limits and the temperature history table returned by
the SCT Data Table command, and \'scttemp\' prints both.
The temperature values are preserved across power cycles.
-The default temperature logging interval is 1 minute and can be
-configured with the \'\-t scttempint,N[,p]\' option, see below.
-The SCT commands are specified in the proposed ATA\-8 Command Set
-(ACS), and are already implemented in some recent ATA\-7 disks.
+The logging interval can be configured with the
+\'\-l scttempint,N[,p]\' option, see below.
+The SCT commands were introduced in ATA8-ACS and were also
+supported by many ATA-7 disks.
+
+.I scttempint,N[,p]
+\- [ATA only] clears the SCT temperature history table and sets the
+time interval for temperature logging to N minutes.
+If \',p\' is specified, the setting is preserved across power cycles.
+Otherwise, the setting is volatile and will be reverted to the last
+non-volatile setting by the next hard reset. The default interval
+is vendor specific, typical values are 1, 2, or 5 minutes.
.I scterc[,READTIME,WRITETIME]
-\- [ATA only] [NEW EXPERIMENTAL SMARTCTL FEATURE] prints values
-and descriptions of the SCT Error Recovery Control settings. These
-are equivalent to TLER (as used by Western Digital), CCTL (as used
-by Samsung and Hitachi) and ERC (as used by Seagate). READTIME and
-WRITETIME arguments (deciseconds) set the specified values. Values of 0
-disable the feature, other values less than 65 are probably not
-supported. For RAID configurations, this is typically set to
-70,70 deciseconds.
+\- [ATA only] prints values and descriptions of the SCT Error Recovery
+Control settings. These are equivalent to TLER (as used by Western
+Digital), CCTL (as used by Samsung and Hitachi/HGST) and ERC (as used by
+Seagate). READTIME and WRITETIME arguments (deciseconds) set the
+specified values. Values of 0 disable the feature, other values less
+than 65 are probably not supported. For RAID configurations, this is
+typically set to 70,70 deciseconds.
+
+.I devstat[,PAGE]
+\- [ATA only] prints values and descriptions of the ATA Device Statistics
+log pages (General Purpose Log address 0x04). If no PAGE number is specified,
+entries from all supported pages are printed. If PAGE 0 is specified,
+the list of supported pages is printed. Device Statistics was
+introduced in ACS-2 and is only supported by some recent devices.
.I sataphy[,reset]
\- [SATA only] prints values and descriptions of the SATA Phy Event
Counters (General Purpose Log address 0x11). If \'\-l sataphy,reset\'
is specified, all counters are reset after reading the values.
+This also works for SATA devices with Packet interface like CD/DVD
+drives.
.I sasphy[,reset]
\- [SAS (SCSI) only] prints values and descriptions of the SAS (SSP)
.fi
writes a binary representation of the one sector log 0x11
(SATA Phy Event Counters) to file log.bin.
+
+.I ssd
+\- [ATA] prints the Solid State Device Statistics log page.
+This has the same effect as \'\-l devstat,7\', see above.
+
+.I ssd
+\- [SCSI] prints the Solid State Media percentage used endurance
+indicator. A value of 0 indicates as new condition while 100
+indicates the device is at the end of its lifetime as projected by the
+manufacturer. The value may reach 255.
.TP
.B \-v ID,FORMAT[:BYTEORDER][,NAME], \-\-vendorattribute=ID,FORMAT[:BYTEORDER][,NAME]
-[ATA only] Sets a vendor\-specific raw value print FORMAT, an optional
+[ATA only] Sets a vendor-specific raw value print FORMAT, an optional
BYTEORDER and an optional NAME for Attribute ID.
This option may be used multiple times.
The optional BYTEORDER consists of 1 to 8 characters from the
set \'012345rvwz\'. The characters \'0\' to \'5\' select the byte 0
-to 5 from the 48\-bit raw value, \'r\' selects the reserved byte of
+to 5 from the 48-bit raw value, \'r\' selects the reserved byte of
the attribute data block, \'v\' selects the normalized value, \'w\'
selects the worst value and \'z\' inserts a zero byte.
-The default BYTEORDER is \'543210\' for all 48\-bit formats, \'r543210\'
-for the 54\-bit formats, and \'543210wv\' for the 64\-bit formats.
+The default BYTEORDER is \'543210\' for all 48-bit formats, \'r543210\'
+for the 54-bit formats, and \'543210wv\' for the 64-bit formats.
For example, \'\-v 5,raw48:012345\' prints the raw value of
attribute 5 with big endian instead of little endian
byte ordering.
-The NAME is a string of letters, digits and underscore.
+The NAME is a string of letters, digits and underscore. Its length should
+not exceed 23 characters. The \'\-P showall\' option reports an error if
+this is the case.
.I \-v help
\- Prints (to STDOUT) a list of all valid arguments to this option,
Valid arguments for FORMAT are:
.I raw8
-\- Print the Raw value as six 8\-bit unsigned base\-10 integers.
+\- Print the Raw value as six 8-bit unsigned base-10 integers.
This may be useful for decoding the meaning of the Raw value.
.I raw16
-\- Print the Raw value as three 16\-bit unsigned base\-10 integers.
+\- Print the Raw value as three 16-bit unsigned base-10 integers.
This may be useful for decoding the meaning of the Raw value.
.I raw48
-\- Print the Raw value as a 48\-bit unsigned base\-10 integer.
+\- Print the Raw value as a 48-bit unsigned base-10 integer.
This is the default for most attributes.
.I hex48
\- Print the Raw value as a 12 digit hexadecimal number.
This may be useful for decoding the meaning of the Raw value.
+.I raw56
+\- Print the Raw value as a 54-bit unsigned base-10 integer.
+This includes the reserved byte which follows the 48-bit raw value.
+
+.I hex56
+\- Print the Raw value as a 14 digit hexadecimal number.
+This includes the reserved byte which follows the 48-bit raw value.
+
.I raw64
-\- Print the Raw value as a 64\-bit unsigned base\-10 integer.
+\- Print the Raw value as a 64-bit unsigned base-10 integer.
This includes two bytes from the normalized and worst attribute value.
-This new raw format is used by some recent SSD devices.
+This raw format is used by some SSD devices with Indilinx controller.
.I hex64
\- Print the Raw value as a 16 digit hexadecimal number.
This includes two bytes from the normalized and worst attribute value.
-This new raw format is used by some recent SSD devices.
+This raw format is used by some SSD devices with Indilinx controller.
.I min2hour
-\- Raw Attribute is power\-on time in minutes. Its raw value
+\- Raw Attribute is power-on time in minutes. Its raw value
will be displayed in the form "Xh+Ym". Here X is hours, and Y is
minutes in the range 0\-59 inclusive. Y is always printed with two
digits, for example "06" or "31" or "00".
.I sec2hour
-\- Raw Attribute is power\-on time in seconds. Its raw value
+\- Raw Attribute is power-on time in seconds. Its raw value
will be displayed in the form "Xh+Ym+Zs". Here X is hours, Y is
minutes in the range 0\-59 inclusive, and Z is seconds in the range
0\-59 inclusive. Y and Z are always printed with two digits, for
example "06" or "31" or "00".
.I halfmin2hour
-\- Raw Attribute is power\-on time, measured in units of 30
+\- Raw Attribute is power-on time, measured in units of 30
seconds. This format is used by some Samsung disks. Its raw value
will be displayed in the form "Xh+Ym". Here X is hours, and Y is
minutes in the range 0\-59 inclusive. Y is always printed with two
digits, for example "06" or "31" or "00".
.I msec24hour32
-\- Raw Attribute is power\-on time measured in 32\-bit hours and 24\-bit
+\- Raw Attribute is power-on time measured in 32-bit hours and 24-bit
milliseconds since last hour update. It will be displayed in the form
"Xh+Ym+Z.Ms". Here X is hours, Y is minutes, Z is seconds and M is
milliseconds.
\- Raw Attribute is ten times the disk temperature in Celsius.
.I raw16(raw16)
-\- Print the raw attribute as a 16\-bit value and two optional
-16\-bit values if these words are nonzero. This is the default
+\- Print the raw attribute as a 16-bit value and two optional
+16-bit values if these words are nonzero. This is the default
for Attributes 5 and 196.
.I raw16(avg16)
and an optional "Average" 16-bit value if the word is nonzero.
This is the default for Attribute 3.
+.I raw24(raw8)
+\- Print the raw attribute as a 24-bit value and three optional
+8-bit values if these bytes are nonzero. This is the default
+for Attribute 9.
+
.I raw24/raw24
-\- Raw Attribute contains two 24\-bit values. The first is the
+\- Raw Attribute contains two 24-bit values. The first is the
number of load cycles. The second is the number of unload cycles.
The difference between these two values is the number of times that
the drive was unexpectedly powered off (also called an emergency
unloads.
.I raw24/raw32
-\- Raw attribute is an error rate which consists of a 24\-bit error
-count and a 32\-bit total count.
+\- Raw attribute is an error rate which consists of a 24-bit error
+count and a 32-bit total count.
The following old arguments to \'\-v\' are also still valid:
.I 220,temp
\- same as:
-.I 220,raw48,Temperature_Celsius.
-
-Note: a table of hard drive models, listing which Attribute
-corresponds to temperature, can be found at:
-\fBhttp://www.guzu.net/linux/hddtemp.db\fP
+.I 220,tempminmax,Temperature_Celsius.
.TP
.B \-F TYPE, \-\-firmwarebug=TYPE
[ATA only] Modifies the behavior of \fBsmartctl\fP to compensate for some
-known and understood device firmware or driver bug. Except \'swapid\',
-the arguments to this option are exclusive, so that only the final
-option given is used. The valid values are:
+known and understood device firmware or driver bug. This option may be used
+multiple times. The valid arguments are:
.I none
\- Assume that the device firmware obeys the ATA specifications. This
is the default, unless the device has presets for \'\-F\' in the
-device database (see note below).
+drive database. Using this option on the command line will override any
+preset values.
+
+.I nologdir
+\- Suppresses read attempts of SMART or GP Log Directory.
+Support for all standard logs is assumed without an actual check.
+Some Intel SSDs may freeze if log address 0 is read.
.I samsung
\- In some Samsung disks (example: model SV4012H Firmware Version:
-RM100\-08) some of the two\- and four\-byte quantities in the SMART data
-structures are byte\-swapped (relative to the ATA specification).
+RM100-08) some of the two- and four-byte quantities in the SMART data
+structures are byte-swapped (relative to the ATA specification).
Enabling this option tells \fBsmartctl\fP to evaluate these quantities
-in byte\-reversed order. Some signs that your disk needs this option
-are (1) no self\-test log printed, even though you have run self\-tests;
+in byte-reversed order. Some signs that your disk needs this option
+are (1) no self-test log printed, even though you have run self-tests;
(2) very large numbers of ATA errors reported in the ATA error log;
(3) strange and impossible values for the ATA error log timestamps.
.I samsung2
\- In some Samsung disks the number of ATA errors reported is byte swapped.
Enabling this option tells \fBsmartctl\fP to evaluate this quantity in
-byte\-reversed order. An indication that your Samsung disk needs this
-option is that the self\-test log is printed correctly, but there are a
+byte-reversed order. An indication that your Samsung disk needs this
+option is that the self-test log is printed correctly, but there are a
very large number of errors in the SMART error log. This is because
the error count is byte swapped. Thus a disk with five errors
(0x0005) will appear to have 20480 errors (0x5000).
.I samsung3
-\- Some Samsung disks (at least SP2514N with Firmware VF100\-37) report
-a self\-test still in progress with 0% remaining when the test was already
-completed. Enabling this option modifies the output of the self\-test
+\- Some Samsung disks (at least SP2514N with Firmware VF100-37) report
+a self-test still in progress with 0% remaining when the test was already
+completed. Enabling this option modifies the output of the self-test
execution status (see options \'\-c\' or \'\-a\' above) accordingly.
-Note that an explicit \'\-F\' option on the command line will
-over\-ride any preset values for \'\-F\' (see the \'\-P\' option
-below).
+.I xerrorlba
+\- Fixes LBA byte ordering in Extended Comprehensive SMART error log.
+Some disks use little endian byte ordering instead of ATA register
+ordering to specifiy the LBA addresses in the log entries.
.I swapid
\- Fixes byte swapped ATA identify strings (device name, serial number,
that are available for this drive. By default, if the drive is recognized
in the \fBsmartmontools\fP database, then the presets are used.
-\fBsmartctl\fP can automatically set appropriate options for known
-drives. For example, the Maxtor 4D080H4 uses Attribute 9 to stores
-power\-on time in minutes whereas most drives use that Attribute to
-store the power\-on time in hours. The command\-line option \'\-v
-9,minutes\' ensures that \fBsmartctl\fP correctly interprets Attribute
-9 in this case, but that option is preset for the Maxtor 4D080H4 and
-so need not be specified by the user on the \fBsmartctl\fP command
-line.
-
The argument
.I show
will show any preset options for your drive and the argument
.I use
\- if a drive is recognized, then use the stored presets for it. This
-is the default. Note that presets will NOT over\-ride additional
-Attribute interpretation (\'\-v N,something\') command\-line options or
-explicit \'\-F\' command\-line options..
+is the default. Note that presets will NOT override additional
+Attribute interpretation (\'\-v N,something\') command-line options or
+explicit \'\-F\' command-line options..
.I ignore
\- do not use presets.
.I showall
\- list all recognized drives, and the presets that are set for them,
-then exit.
+then exit. This also checks the drive database regular expressions
+and settings for syntax errors.
The \'\-P showall\' option takes up to two optional arguments to
match a specific drive type and firmware version. The command:
the built in database by default. If \'+\' is specified, then the new
entries prepend the built in entries.
-If this option is not specified, optional entries are read from the file
-\fB/usr/local/etc/smart_drivedb.h\fP (Windows: \fBEXEDIR/drivedb-add.h\fP).
-.\" BEGIN ENABLE_DRIVEDB
-If \fB/usr/local/share/smartmontools/drivedb.h\fP
-(Windows: \fBEXEDIR/drivedb.h\fP) is present, the
-contents of this file is used instead of the built in table.
-
-Run the script \fB/usr/local/sbin/update-smart-drivedb\fP to update this
-file from the smartmontools SVN repository.
-.\" END ENABLE_DRIVEDB
+Optional entries are read from the file
+.\" %IF NOT OS Windows
+\fB/usr/local/etc/smart_drivedb.h\fP
+.\" %ENDIF NOT OS Windows
+.\" %IF OS ALL
+ (Windows: \fBEXEDIR/drivedb-add.h\fP)
+.\" %ENDIF OS ALL
+.\" %IF OS Windows
+.\"! \fBEXEDIR/drivedb-add.h\fP.
+.\" %ENDIF OS Windows
+.\" %IF ENABLE_DRIVEDB
+if this option is not specified.
+
+If
+.\" %IF NOT OS Windows
+\fB/usr/local/share/smartmontools/drivedb.h\fP
+.\" %ENDIF NOT OS Windows
+.\" %IF OS ALL
+(Windows: \fBEXEDIR/drivedb.h\fP)
+.\" %ENDIF OS ALL
+.\" %IF OS Windows
+.\"! \fBEXEDIR/drivedb.h\fP
+.\" %ENDIF OS Windows
+is present, the contents of this file is used instead of the built in table.
+
+Run
+.\" %IF NOT OS Windows
+\fB/usr/local/sbin/update-smart-drivedb\fP
+.\" %ENDIF NOT OS Windows
+.\" %IF OS ALL
+(Windows: \fBEXEDIR/update-smart-drivedb.exe\fP)
+.\" %ENDIF OS ALL
+.\" %IF OS Windows
+.\"! \fBEXEDIR/update-smart-drivedb.exe\fP
+.\" %ENDIF OS Windows
+to update this file from the smartmontools SVN repository.
+.\" %ENDIF ENABLE_DRIVEDB
The database files use the same C/C++ syntax that is used to initialize
the built in database array. C/C++ style comments are allowed.
.fi
.TP
-.B SMART RUN/ABORT OFFLINE TEST AND SELF\-TEST OPTIONS:
+.B SMART RUN/ABORT OFFLINE TEST AND self-test OPTIONS:
.TP
.B \-t TEST, \-\-test=TEST
Executes TEST immediately. The \'\-C\' option can be used in
conjunction with this option to run the short or long (and also for
-ATA devices, selective or conveyance) self\-tests in captive mode
+ATA devices, selective or conveyance) self-tests in captive mode
(known as "foreground mode" for SCSI devices). Note that only one
test type can be run at a time, so only one test type should be
specified per command line. Note also that if a computer is shutdown
-or power cycled during a self\-test, no harm should result. The
-self\-test will either be aborted or will resume automatically.
+or power cycled during a self-test, no harm should result. The
+self-test will either be aborted or will resume automatically.
+
+All \'\-t TEST\' commands can be given during normal system operation
+unless captive mode (\'\-C\' option) is used.
+A running self-test can, however, degrade performance of the drive.
+Frequent I/O requests from the operating system increase the duration
+of a test. These impacts may vary from device to device.
-The valid arguments to this option are:
+If a test failure occurs then the device may discontinue the testing
+and report the result immediately.
+
+The valid arguments to this option are:
.I offline
\- [ATA] runs SMART Immediate Offline Test. This immediately
performance as well as the read performance of the disk. Their
results are reported in the Self Test Error Log, readable with
the \'\-l selftest\' option. Note that on some disks the progress of the
-self\-test can be monitored by watching this log during the self\-test; with other disks
+self-test can be monitored by watching this log during the self-test; with other disks
use the \'\-c\' option to monitor progress.
.I short
-\- [SCSI] runs the "Background short" self\-test.
+\- [SCSI] runs the "Background short" self-test.
.I long
\- [ATA] runs SMART Extended Self Test (tens of minutes). This is a
system operation (unless run in captive mode \- see the \'\-C\' option below).
.I long
-\- [SCSI] runs the "Background long" self\-test.
+\- [SCSI] runs the "Background long" self-test.
.I conveyance
\- [ATA only] runs a SMART Conveyance Self Test (minutes). This
-self\-test routine is intended to identify damage incurred during
-transporting of the device. This self\-test routine should take on the
+self-test routine is intended to identify damage incurred during
+transporting of the device. This self-test routine should take on the
order of minutes to complete. Note that this command can be given
during normal system operation (unless run in captive mode \- see the
\'\-C\' option below).
For example the commands:
.nf
- smartctl \-t select,10\-20 /dev/hda
- smartctl \-t select,10+11 /dev/hda
+ smartctl \-t select,10\-20 /dev/sda
+ smartctl \-t select,10+11 /dev/sda
.fi
both runs a self test on one span consisting of LBAs ten to twenty
(inclusive). The command:
.nf
- smartctl \-t select,100000000\-max /dev/hda
+ smartctl \-t select,100000000\-max /dev/sda
.fi
run a self test from LBA 100000000 up to the end of the disk.
The \'\-t\' option can be given up to five times, to test
up to five spans. For example the command:
.nf
- smartctl \-t select,0\-100 \-t select,1000\-2000 /dev/hda
+ smartctl \-t select,0\-100 \-t select,1000\-2000 /dev/sda
.fi
runs a self test on two spans. The first span consists of 101 LBAs
and the second span consists of 1001 LBAs. Note that the spans can
overlap partially or completely, for example:
.nf
- smartctl \-t select,0\-10 \-t select,5\-15 \-t select,10\-20 /dev/hda
+ smartctl \-t select,0\-10 \-t select,5\-15 \-t select,10\-20 /dev/sda
.fi
-The results of the selective self\-test can be obtained (both during
-and after the test) by printing the SMART self\-test log, using the
+The results of the selective self-test can be obtained (both during
+and after the test) by printing the SMART self-test log, using the
\'\-l selftest\' option to smartctl.
Selective self tests are particularly useful as disk capacities
increase: an extended self test (smartctl \-t long) can take several
-hours. Selective self\-tests are helpful if (based on SYSLOG error
-messages, previous failed self\-tests, or SMART error log entries) you
+hours. Selective self-tests are helpful if (based on SYSLOG error
+messages, previous failed self-tests, or SMART error log entries) you
suspect that a disk is having problems at a particular range of
Logical Block Addresses (LBAs).
-Selective self\-tests can be run during normal system operation (unless
+Selective self-tests can be run during normal system operation (unless
done in captive mode \- see the \'\-C\' option below).
-The following variants of the selective self\-test command use spans based
+The following variants of the selective self-test command use spans based
on the ranges from past tests already stored on the disk:
.I select,redo[+SIZE]
For example the commands:
.nf
- smartctl \-t select,10\-20 /dev/hda
- smartctl \-t select,redo /dev/hda
- smartctl \-t select,redo+20 /dev/hda
+ smartctl \-t select,10\-20 /dev/sda
+ smartctl \-t select,redo /dev/sda
+ smartctl \-t select,redo+20 /dev/sda
.fi
have the same effect as:
.nf
- smartctl \-t select,10\-20 /dev/hda
- smartctl \-t select,10\-20 /dev/hda
- smartctl \-t select,10\-29 /dev/hda
+ smartctl \-t select,10\-20 /dev/sda
+ smartctl \-t select,10\-20 /dev/sda
+ smartctl \-t select,10\-29 /dev/sda
.fi
.I select,next[+SIZE]
For example the commands:
.nf
- smartctl \-t select,0\-999 /dev/hda
- smartctl \-t select,next /dev/hda
- smartctl \-t select,next+2000 /dev/hda
+ smartctl \-t select,0\-999 /dev/sda
+ smartctl \-t select,next /dev/sda
+ smartctl \-t select,next+2000 /dev/sda
.fi
have the same effect as:
.nf
- smartctl \-t select,0\-999 /dev/hda
- smartctl \-t select,1000\-1999 /dev/hda
- smartctl \-t select,2000\-3999 /dev/hda
+ smartctl \-t select,0\-999 /dev/sda
+ smartctl \-t select,1000\-1999 /dev/sda
+ smartctl \-t select,2000\-3999 /dev/sda
.fi
If the last test ended at the last LBA of the disk, the new range starts
(above) test.
.I afterselect,on
-\- [ATA only] perform an offline read scan after a Selective Self\-test
+\- [ATA only] perform an offline read scan after a Selective self-test
has completed. This option must be used together with one or more of
the \fIselect,N\-M\fP options above. If the LBAs that have been
-specified in the Selective self\-test pass the test with no errors
+specified in the Selective self-test pass the test with no errors
found, then read scan the \fBremainder\fP of the disk. If the device
-is powered\-cycled while this read scan is in progress, the read scan
+is powered-cycled while this read scan is in progress, the read scan
will be automatically resumed after a time specified by the pending
timer (see below). The value of this option is preserved between
-selective self\-tests.
+selective self-tests.
.I afterselect,off
\- [ATA only] do not read scan the remainder of the disk after a
-Selective self\-test has completed. This option must be use together
+Selective self-test has completed. This option must be use together
with one or more of the \fIselect,N\-M\fP options above. The value of this
-option is preserved between selective self\-tests.
+option is preserved between selective self-tests.
.I pending,N
\- [ATA only] set the pending offline read scan timer to N minutes.
Here N is an integer in the range from 0 to 65535 inclusive. If the
-device is powered off during a read scan after a Selective self\-test,
-then resume the test automatically N minutes after power\-up. This
+device is powered off during a read scan after a Selective self-test,
+then resume the test automatically N minutes after power-up. This
option must be use together with one or more of the \fIselect,N\-M\fP
options above. The value of this option is preserved between selective
-self\-tests.
-
-.I scttempint,N[,p]
-\- [ATA only] set the time interval for SCT temperature logging to N
-minutes. If \',p\' is specified, the setting is preserved across power
-cycles. Otherwise, the setting is volatile and will be reverted to
-default (1 minute), or last non-volatile setting by the next hard reset.
-This command also clears the temperature history table. See
-\'\-l scttemp\' above for more information about SCT temperature logging.
+self-tests.
.I vendor,N
\- [ATA only] issues the ATA command SMART EXECUTE OFF-LINE IMMEDIATE
with subcommand N in LBA LOW register. The subcommand is specified as
-a hex value in the range 0x00 to 0xff. Subcommands 0x40-0x7f and
+a hex value in the range 0x00 to 0xff. Subcommands 0x40-0x7e and
0x90-0xff are reserved for vendor specific use, see table 61 of
-T13/1699-D Revision 6a (ATA8-ACS).
+T13/1699-D Revision 6a (ATA8-ACS). Note that the subcommands
+0x00-0x04,0x7f,0x81-0x84 are supported by other smartctl options
+(e.g. 0x01: \'\-t short\', 0x7f: \'\-X\', 0x82: \'\-C \-t long\').
\fBWARNING: Only run subcommands documented by the vendor of the
device.\fP
-Example for Intel X18\-M/X25\-M G2 SSDs only: The subcommand 0x40
-(\'\-t vendor,0x40\') clears the timed workload related SMART
-attributes (226, 227, 228).
+Example for some Intel SSDs only:
+The subcommand 0x40 (\'\-t vendor,0x40\') clears the timed workload
+related SMART attributes (226, 227, 228). Note that the raw values of
+these attributes are held at 65535 (0xffff) until the workload timer
+reaches 60 minutes.
+
+.I force
+\- start new self-test even if another test is already running.
+By default a running self-test will not be interrupted to begin another
+test.
.TP
.B \-C, \-\-captive
-[ATA] Runs self\-tests in captive mode. This has no effect with \'\-t
+[ATA] Runs self-tests in captive mode. This has no effect with \'\-t
offline\' or if the \'\-t\' option is not used.
\fBWARNING: Tests run in captive mode may busy out the drive for the
length of the test. Only run captive tests on drives without any
mounted partitions!\fP
-[SCSI] Runs the self\-test in "Foreground" mode.
+[SCSI] Runs the self-test in "Foreground" mode.
.TP
.B \-X, \-\-abort
-Aborts non\-captive SMART Self Tests. Note that this
+Aborts non-captive SMART Self Tests. Note that this
command will abort the Offline Immediate Test routine only if your
disk has the "Abort Offline collection upon new command" capability.
-.PP
+
.SH ATA, SCSI command sets and SAT
In the past there has been a clear distinction between storage devices
that used the ATA and SCSI command sets. This distinction was often
approach is running a tool like smartmontools inside the RAID 1 box (e.g.
a Network Attached Storage (NAS) box) and fetching the logs via a
browser.
-.PP
+
.SH EXAMPLES
.nf
-.B smartctl \-a /dev/hda
-.fi
-Print a large amount of SMART information for drive /dev/hda which is
-typically an ATA (IDE) or SATA disk in Linux.
-.PP
-.nf
-.B smartctl \-a /dev/sdb
+.B smartctl \-a /dev/sda
.fi
-Print a large amount of SMART information for drive /dev/sdb . This may
-be a SCSI disk or an ATA (SATA) disk.
+Print a large amount of SMART information for drive /dev/sda .
.PP
.nf
-.B smartctl \-s off /dev/hdd
+.B smartctl \-s off /dev/sdd
.fi
-Disable SMART monitoring and data log collection on drive /dev/hdd .
+Disable SMART monitoring and data log collection on drive /dev/sdd .
.PP
.nf
-.B smartctl \-\-smart=on \-\-offlineauto=on \-\-saveauto=on /dev/hda
+.B smartctl \-\-smart=on \-\-offlineauto=on \-\-saveauto=on /dev/sda
.fi
-Enable SMART on drive /dev/hda, enable automatic offline
+Enable SMART on drive /dev/sda, enable automatic offline
testing every four hours, and enable autosaving of
-SMART Attributes. This is a good start\-up line for your system\'s
+SMART Attributes. This is a good start-up line for your system\'s
init files. You can issue this command on a running system.
.PP
.nf
-.B smartctl \-t long /dev/hdc
+.B smartctl \-t long /dev/sdc
.fi
-Begin an extended self\-test of drive /dev/hdc. You can issue this
-command on a running system. The results can be seen in the self\-test
+Begin an extended self-test of drive /dev/sdc. You can issue this
+command on a running system. The results can be seen in the self-test
log visible with the \'\-l selftest\' option after it has completed.
.PP
.nf
-.B smartctl \-s on \-t offline /dev/hda
+.B smartctl \-s on \-t offline /dev/sda
.fi
Enable SMART on the disk, and begin an immediate offline test of
-drive /dev/hda. You can issue this command on a running system. The
+drive /dev/sda. You can issue this command on a running system. The
results are only used to update the SMART Attributes, visible
with the \'\-A\' option. If any device errors occur, they are logged to
the SMART error log, which can be seen with the \'\-l error\' option.
.PP
.nf
-.B smartctl \-A \-v 9,minutes /dev/hda
+.B smartctl \-A \-v 9,minutes /dev/sda
.fi
-Shows the vendor Attributes, when the disk stores its power\-on time
+Shows the vendor Attributes, when the disk stores its power-on time
internally in minutes rather than hours.
.PP
.nf
-.B smartctl \-q errorsonly \-H \-l selftest /dev/hda
+.B smartctl \-q errorsonly \-H \-l selftest /dev/sda
.fi
Produces output only if the device returns failing SMART status,
-or if some of the logged self\-tests ended with errors.
+or if some of the logged self-tests ended with errors.
.PP
.nf
-.B smartctl \-q silent \-a /dev/hda
+.B smartctl \-q silent \-a /dev/sda
.fi
-Examine all SMART data for device /dev/hda, but produce no
+Examine all SMART data for device /dev/sda, but produce no
printed output. You must use the exit status (the
.B $?
shell variable) to learn if any Attributes are out of bound, if the
SMART status is failing, if there are errors recorded in the
-self\-test log, or if there are errors recorded in the disk error log.
+self-test log, or if there are errors recorded in the disk error log.
.PP
.nf
.B smartctl \-a \-d 3ware,0 /dev/sda
.nf
.B smartctl \-t short \-d 3ware,3 /dev/sdb
.fi
-Start a short self\-test on the fourth ATA disk connected to the 3ware RAID
+Start a short self-test on the fourth ATA disk connected to the 3ware RAID
controller card which is the second SCSI device /dev/sdb.
.PP
.nf
.B smartctl \-t long \-d areca,4 /dev/sg2
.fi
-Start a long self\-test on the fourth SATA disk connected to an Areca RAID
+Start a long self-test on the fourth SATA disk connected to an Areca RAID
controller addressed by /dev/sg2.
.PP
.nf
.B smartctl \-t short \-d hpt,1/1/2 /dev/sda (under Linux)
.B smartctl \-t short \-d hpt,1/1/2 /dev/hptrr (under FreeBSD)
.fi
-Start a short self\-test on the (S)ATA disk connected to second pmport on the
+Start a short self-test on the (S)ATA disk connected to second pmport on the
first channel of the first HighPoint RocketRAID controller card.
.PP
.nf
-.B smartctl \-t select,10\-100 \-t select,30\-300 \-t afterselect,on \-t pending,45 /dev/hda
+.B smartctl \-t select,10\-100 \-t select,30\-300 \-t afterselect,on \-t pending,45 /dev/sda
.fi
-Run a selective self\-test on LBAs 10 to 100 and 30 to 300. After the
-these LBAs have been tested, read\-scan the remainder of the disk. If the disk is
-power\-cycled during the read\-scan, resume the scan 45 minutes after power to the
+Run a selective self-test on LBAs 10 to 100 and 30 to 300. After the
+these LBAs have been tested, read-scan the remainder of the disk. If the disk is
+power-cycled during the read-scan, resume the scan 45 minutes after power to the
device is restored.
.PP
.nf
.fi
Examine all SMART data for the first SCSI disk connected to a cciss
RAID controller card.
-.PP
-.SH RETURN VALUES
-The return values of \fBsmartctl\fP are defined by a bitmask. If all
-is well with the disk, the return value (exit status) of
+
+.SH EXIT STATUS
+The exit statuses of \fBsmartctl\fP are defined by a bitmask.
+If all is well with the disk, the exit status (return value) of
\fBsmartctl\fP is 0 (all bits turned off). If a problem occurs, or an
-error, potential error, or fault is detected, then a non\-zero status
-is returned. In this case, the eight different bits in the return
-value have the following meanings for ATA disks; some of these values
+error, potential error, or fault is detected, then a non-zero status
+is returned. In this case, the eight different bits in the exit status
+have the following meanings for ATA disks; some of these values
may also be returned for SCSI disks.
.TP
.B Bit 0:
or device is in a low-power mode (see \'\-n\' option above).
.TP
.B Bit 2:
-Some SMART command to the disk failed, or there was a checksum error
-in a SMART data structure (see \'\-b\' option above).
+Some SMART or other ATA command to the disk failed, or there was a checksum
+error in a SMART data structure (see \'\-b\' option above).
.TP
.B Bit 3:
SMART status check returned "DISK FAILING".
The device error log contains records of errors.
.TP
.B Bit 7:
-The device self\-test log contains records of errors.
+The device self-test log contains records of errors.
[ATA only] Failed self-tests outdated by a newer successful extended
-self\-test are ignored.
-
+self-test are ignored.
+.PP
To test within the shell for whether or not the different bits are
-turned on or off, you can use the following type of construction (this
-is bash syntax):
+turned on or off, you can use the following type of construction
+(which should work with any POSIX compatible shell):
.nf
.B smartstat=$(($? & 8))
.fi
(since 8=2^3). The shell variable
$smartstat will be nonzero if SMART status check returned "disk
failing" and zero otherwise.
-
-.PP
-.SH NOTES
-The TapeAlert log page flags are cleared for the initiator when the
-page is read. This means that each alert condition is reported only
-once by \fBsmartctl\fP for each initiator for each activation of the
-condition.
-
.PP
-.SH AUTHOR
-\fBBruce Allen\fP smartmontools\-support@lists.sourceforge.net
+This shell script prints all status bits:
+.nf
+val=$?; mask=1
+for i in 0 1 2 3 4 5 6 7; do
+ echo "Bit $i: $(((val & mask) && 1))"
+ mask=$((mask << 1))
+done
.fi
-University of Wisconsin \- Milwaukee Physics Department
-.PP
-.SH CONTRIBUTORS
-The following have made large contributions to smartmontools:
-.nf
-\fBCasper Dik\fP (Solaris SCSI interface)
-\fBChristian Franke\fP (Windows interface, C++ redesign, USB support, ...)
-\fBDouglas Gilbert\fP (SCSI subsystem)
-\fBGuido Guenther\fP (Autoconf/Automake packaging)
-\fBGeoffrey Keating\fP (Darwin ATA interface)
-\fBEduard Martinescu\fP (FreeBSD interface)
-\fBFr\*'ed\*'eric L. W. Meunier\fP (Web site and Mailing list)
-\fBGabriele Pohl\fP (Web site and Wiki, conversion from CVS to SVN)
-\fBKeiji Sawada\fP (Solaris ATA interface)
-\fBManfred Schwarb\fP (Drive database)
-\fBSergey Svishchev\fP (NetBSD interface)
-\fBDavid Snyder and Sergey Svishchev\fP (OpenBSD interface)
-\fBPhil Williams\fP (User interface and drive database)
-\fBYuri Dario\fP (OS/2, eComStation interface)
-\fBShengfeng Zhou\fP (Linux/FreeBSD HighPoint RocketRAID interface)
-.fi
-Many other individuals have made smaller contributions and corrections.
+.\" %IF NOT OS Windows
+.SH FILES
+.TP
+.B /usr/local/sbin/smartctl
+full path of this executable.
+.\" %IF ENABLE_DRIVEDB
+.TP
+.B /usr/local/share/smartmontools/drivedb.h
+drive database (see \'\-B\' option).
+.\" %ENDIF ENABLE_DRIVEDB
+.TP
+.B /usr/local/etc/smart_drivedb.h
+optional local drive database (see \'\-B\' option).
+
+.\" %ENDIF NOT OS Windows
+.SH AUTHORS
+\fBBruce Allen\fP (project initiator),
+.br
+\fBChristian Franke\fP (project manager, Windows port and all sort of things),
+.br
+\fBDouglas Gilbert\fP (SCSI subsystem),
+.br
+\fBVolker Kuhlmann\fP (moderator of support and database mailing list),
+.br
+\fBGabriele Pohl\fP (wiki & development team support),
+.br
+\fBAlex Samorukov\fP (FreeBSD port and more, new Trac wiki).
+
+Many other individuals have made contributions and corrections,
+see AUTHORS, ChangeLog and repository files.
+
+The first smartmontools code was derived from the smartsuite package,
+written by Michael Cornwell and Andre Hedrick.
+
+.SH REPORTING BUGS
+To submit a bug report, create a ticket in smartmontools wiki:
+.br
+<\fBhttp://www.smartmontools.org/\fP>.
+.br
+Alternatively send the info to the smartmontools support mailing list:
+.br
+<\fBhttps://lists.sourceforge.net/lists/listinfo/smartmontools-support\fB>.
+
+.SH SEE ALSO
+\fBsmartd\fP(8), \fBupdate-smart-drivedb\fP(8).
+
+.SH REFERENCES
+Please see the following web site for more info:
+\fBhttp://www.smartmontools.org/\fP
-.PP
-.SH CREDITS
-.fi
-This code was derived from the smartsuite package, written by Michael
-Cornwell, and from the previous UCSC smartsuite package. It extends
-these to cover ATA\-5 disks. This code was originally developed as a
-Senior Thesis by Michael Cornwell at the Concurrent Systems Laboratory
-(now part of the Storage Systems Research Center), Jack Baskin School
-of Engineering, University of California, Santa
-Cruz. \fBhttp://ssrc.soe.ucsc.edu/\fP .
-.SH
-HOME PAGE FOR SMARTMONTOOLS:
-.fi
-Please see the following web site for updates, further documentation, bug
-reports and patches: \fBhttp://smartmontools.sourceforge.net/\fP
-
-.SH
-SEE ALSO:
-\fBsmartd\fP(8), \fBbadblocks\fP(8), \fBide\-smart\fP(8).
-.SH
-REFERENCES FOR SMART
-.fi
An introductory article about smartmontools is \fIMonitoring Hard
Disks with SMART\fP, by Bruce Allen, Linux Journal, January 2004,
-pages 74\-77. This is \fBhttp://www.linuxjournal.com/article/6983\fP
+pages 74-77. This is \fBhttp://www.linuxjournal.com/article/6983\fP
online.
If you would like to understand better how SMART works, and what it
does, a good place to start is with Sections 4.8 and 6.54 of the first
-volume of the \'AT Attachment with Packet Interface\-7\' (ATA/ATAPI\-7)
+volume of the \'AT Attachment with Packet Interface-7\' (ATA/ATAPI-7)
specification Revision 4b. This documents the SMART functionality which the
\fBsmartmontools\fP utilities provide access to.
-This and other versions of this Specification are available from
-the T13 web site \fBhttp://www.t13.org/\fP .
-.fi
-The functioning of SMART was originally defined by the SFF\-8035i
-revision 2 and the SFF\-8055i revision 1.4 specifications. These are
+The functioning of SMART was originally defined by the SFF-8035i
+revision 2 and the SFF-8055i revision 1.4 specifications. These are
publications of the Small Form Factors (SFF) Committee.
Links to these and other documents may be found on the Links page of the
-\fBsmartmontools\fP Wiki at
-\fBhttp://sourceforge.net/apps/trac/smartmontools/wiki/Links\fP .
+\fBsmartmontools\fP Wiki at \fBhttp://www.smartmontools.org/wiki/Links\fP .
-.SH
-SVN ID OF THIS PAGE:
-$Id: smartctl.8.in 3283 2011-03-04 20:13:57Z chrfranke $
+.SH PACKAGE VERSION
+CURRENT_SVN_VERSION CURRENT_SVN_DATE CURRENT_SVN_REV
+.br
+$Id: smartctl.8.in 4120 2015-08-27 16:12:21Z samm2 $