1. Summary
  2. Files
  3. Support
  4. Report Spam
  5. Create account
  6. Log in

root/trunk/sm5/smartctl.8 @ 8

Revision 8, 10.3 KB (checked in by ballen4705, 12 years ago)

Put in CVS version strings that I forgot...

Line 
1\# Copyright (C) 2002 Bruce Allen <ballen@uwm.edu>
2\#
3\# $Id: smartctl.8,v 1.2 2002/10/09 18:07:17 ballen4705 Exp $
4\#
5\# This program is free software; you can redistribute it and/or modify it
6\# under the terms of the GNU General Public License as published by the Free
7\# Software Foundation; either version 2, or (at your option) any later
8\# version.
9\#
10\# You should have received a copy of the GNU General Public License (for
11\# example COPYING); if not, write to the Free Software Foundation, Inc., 675
12\# Mass Ave, Cambridge, MA 02139, USA.
13.TH SMARTCTL 8  "October 9, 2002" "smartmontools-5.0"
14.SH NAME
15smartctl \- S.M.A.R.T. control utility
16.SH SYNOPSIS
17.B smartctl 
18[\-\icavglLdeOSXsxAtTfF] [device]
19
20.SH DESCRIPTION
21.B smartctl
22controls the Self-Monitoring, Analysis and Reporting Technology
23(S.M.A.R.T.) system built into many ATA-3 and later ATA, IDE and
24SCSI-3 hard drives. The purpose of S.M.A.R.T. is to monitor the
25reliability of the hard drive and predict drive failures, and to carry
26out different types of drive self-tests.  This version of smartctl is
27compatible with ATA/ATAPI-5 and earlier standards (see REFERENCES
28below)
29
30.B smartctl
31is a command line utility designed to perform S.M.A.R.T. tasks such as
32printing the S.M.A.R.T. self-test and error logs, and enabling and
33disabling S.M.A.R.T. automatic testing.
34
35.B smartctl
36also provides limited TapeAlerts support for some SCSI tape drives and
37changers.
38.PP
39.SH SYNTAX
40.PP
41.B smartctl
42takes two arguments, options and device. Examples are given below.
43
44The first argument, options, begins with a '\-' followed by
45letters. Multiple options must begin with a single '\-'.
46
47The second argument is the device to be controlled. ATA device use the
48form "/dev/hd*" and SCSI devices use the form "/dev/sd*".
49
50SCSI devices only accept the options a,i,c,e,d, and p. For SCSI Tape
51Drives and Changers with TapeAlerts support use the devices "/dev/st*"
52and "/dev/sg*". TapeAlerts devices accept the options a,i,c,e,d, and
53p.
54.PP
55.SH OPTIONS
56.TP
57.B Read-only options:
58.TP
59p
60Print: Prints Copyright and License information.
61.TP
62i
63Information: Check if the device supports S.M.A.R.T.  Prints the
64device model number, the ATA version and revision supported, and the
65device serial number and firmware version.
66.TP
67c
68Check: See if the device has any S.M.A.R.T. Warranty Failures. If so,
69this either means that the device has already failed, or that it is
70predicting its own failure within the next 24 hours.  If this happens,
71use the '\-a' option to get more information.
72.TP
73g
74Generic: Prints only the generic S.M.A.R.T. attributes.  This shows the
75S.M.A.R.T.  capabilities of the device (can it log errors, does it
76support offline surface scanning, and so on).  If the device can carry
77out self-tests, it also lists the estimated time required to run those
78tests.  See REFERENCES below for further information about their
79meaning.
80.TP
81v
82Vendor: Prints only the vendor specific S.M.A.R.T. attributes.  The
83attributes are numbered from 1 to 253 and have specific names. For
84example attribute 12 is \'power cycle count\': how many times has the
85disk been powered up.  Each attribute has a 'Raw' value, printed under
86the heading 'Raw Value', and a 'Normalized' value printed under the
87heading 'Value'.  Each vendor uses their own magic to convert the Raw
88value to a Normalized value.  If the Normalized value is
89.B smaller
90than the value given under the 'Threshold' column, then disk failure
91is imminent.  The column labeled 'Worst' shows the lowest (closest to
92failure) value that the disk has recorded at any time during its
93lifetime when S.M.A.R.T.  was enabled.
94
95Note that the conversion from 'Raw' value to physical units is not
96specified by the S.M.A.R.T. standard. In most cases, the values printed by
97.B smartctl
98are sensible.  However in some cases a vendor uses unusual
99conventions.  For example the Hitachi disk on my laptop reports its
100power-on hours in minutes, not hours. Some IBM disks track three
101temperatures rather than one, in their raw values.  And so on.
102.TP
103l
104Log: Prints only the S.M.A.R.T. error log.  S.M.A.R.T. disks maintain
105a log of the most recent five non-trivial errors.  For each of these
106errors, the disk power-on lifetime at which the error occurred is
107recorded, as is the device status (idle, standby, etc) at the time of
108the error.  Finally, up to the last five commands that preceded the
109error are also recorded, along with a timestamp measured in seconds
110from when the disk was powered up during the session where the error
111took place.  The key ATA disk registers are also recorded in the log.
112.TP
113L
114Log: Prints only the S.M.A.R.T. self-test log.  The disk maintains a
115log showing the results of the self tests, which can be run using the
116 '\-S', '\-s', '\-X', and '\-x' options.  The log will show, for each
117of the most recent twenty-one self-tests, the type of test (short or
118extended, off-line or captive) and the final status of the test.  If
119the test did not complete successfully, the percentage of the test
120remaining is show.  The time at which the test took place, measured in
121hours of disk lifetime, is shown.  If any errors were detected, the
122Logical Blobk Address (LBA) of the first error is also indicated.
123.TP
124a
125All: Prints all parameters for c,i,g,v,t,l,L (for SCSI c,i).  This prints all
126S.M.A.R.T. information about the disk.
127.TP
128.B Enable/Disable Options:
129.TP
130e
131Enable: Enables S.M.A.R.T. on device.  Note that this command (perhaps
132with the '\-t' and '\-f' options also enabled) should be placed in a
133start-up script for your machine, for example in rc.local or
134rc.sysinit.
135.TP
136d
137Disable: Disables S.M.A.R.T. on device.  This turns off all
138S.M.A.R.T. functionality.  I can't imagine why you would want to do
139this.  [Or do you cover up the oil-pressure warning light on your car?]
140.TP
141t
142Test: Enables S.M.A.R.T. automatic offline test timer which scans the drive
143every four hours for disk defects. This command can be given during normal
144system operation.
145
146S.M.A.R.T. provides three basic classes of testing.  The so-called
147'online' testing has no effect on the performance of the device.  It
148is turned on by the '\-e' option. The offline testing, enabled by this
149 '\-t' option, can, in principle, degrade the device performance.  Normally,
150the disk will suspend any offline testing while disk accesses are
151taking place, then automatically resume them when the disk would
152otherwise be idle, so in practice it has little effect.  The third
153class of testing is the 'self' testing; see below.
154
155Any errors detected in the automatic offline testing will be shown in
156the S.M.A.R.T. error log, and will be reflected in the values of the
157S.M.A.R.T. attributes.  These are visible with the '\-l' and '\-v'
158options.
159.TP
160T
161unTest: Disables S.M.A.R.T. automatic offline test timer.
162.TP
163f
164File: Enables S.M.A.R.T. autosave of device vendor-specific attributes.
165.TP
166F
167unFile: Disables S.M.A.R.T. autosave of device vendor-specific attributes.
168.TP
169.B Run a Test Immediately Options:
170.TP
171O
172Offline: Runs S.M.A.R.T. Immediate offline Test.  This immediately
173starts the test describe above.  This command can be given during
174normal system operation.
175.TP
176S Selftest: Runs S.M.A.R.T. Short Self Test (usually under ten
177minutes).  This is a test in a different category than the automatic
178offline tests.  The 'Self' tests check the electrical and mechanical
179performance as well as the read performance of the disk.  Their
180results are reported in the Self Test Error Log, readable with the
181 '\-L' option. Note that this command can be given during normal system
182operation.
183.TP
184s
185Selftest: Runs S.M.A.R.T. Short Self Test in Captive Mode.  (WARNING: This test
186will busy out drive for length of test. Only run this on drives
187without any mounted partitions.)
188.TP
189X
190eXtended: Runs S.M.A.R.T. Extended Self Test (tens of minutes).  This is a
191longer and more thorough version of the Short Self Test described
192under the '\-x' option.  Note that this command can be given during normal
193system operation.
194.TP
195x
196eXtended: Runs S.M.A.R.T. Extended Self Test in Captive Mode.  (WARNING: This
197test will busy out drive for length of test. Only run this on drives
198without any mounted partitions.)
199.TP
200A
201Abort: Aborts Non-Captive S.M.A.R.T. Self Tests.
202.PP
203.SH EXAMPLES
204.nf
205.B smartctl -a /dev/hda
206.fi
207prints all S.M.A.R.T. information for drive /dev/hda (Primary Master).
208.PP
209.nf
210.B smartctl -d /dev/hdd
211.fi
212disable S.M.A.R.T. on drive /dev/hdd (Secondary Slave).
213.PP
214.nf
215.B smartctl -etf /dev/hda
216.fi
217enables S.M.A.R.T. on drive /dev/hda, enables automatic offline
218testing every four hours, and enables autosaving of
219S.M.A.R.T. attributes.  This is a good start-up line for your system's
220init files.  You can issue this command on a running system.
221.PP
222.nf
223.B smartctl -X /dev/hdc
224.fi
225begin an extended self-test of drive /dev/hdc.  The results can be
226seen in the self-test log after the test has completed. You can issue
227this command on a running system.
228
229.PP
230.SH AUTHOR
231Bruce Allen
232.B ballen@uwm.edu
233.fi
234University of Wisconsin - Milwaukee Physics Department
235
236.PP
237.SH CREDITS
238.fi
239This code was derived from the smartsuite package, written by
240Michael Cornwell, and from the previous ucsc smartsuite package.  It
241extends these to cover ATA-5 disks.
242.SH
243HOME PAGE FOR SMARTMONTOOLS:
244.fi
245Please see the following web site for updates, further documentation, bug
246reports and patches:
247.nf
248.B
249http://sourceforge.net/projects/smartmontools
250
251.SH
252SEE ALSO:
253.B
254smartd (8)
255.SH
256REFERENCES FOR S.M.A.R.T.
257.fi
258If you would like to understand better how S.M.A.R.T. works, and what
259it does, a good place to start is  Section 8.41 of the 'AT
260Attachment with Packet Interface-5' (ATA/ATAPI-5) specification.  This
261documents the S.M.A.R.T. functionality which the smartmontools
262utilities provide access to.  You can find Revision 1 of this document
263at:
264.nf
265.B
266http://www.t13.org/project/d1321r1c.pdf
267.fi
268Future versions of the specifications (ATA/ATAPI-6 and ATA/ATAPI-7),
269and later revisions (2, 3) of the ATA/ATAPI-5 specification are
270available from:
271.nf
272.B
273http://www.t13.org/#FTP_site
274
275.fi
276The functioning of S.M.A.R.T. is also described by the SFF-8035i
277revision 2 specification.  This is a publication of the Small Form
278Factors (SFF) Committee, and can be obtained from:
279.TP
280\
281SFF Committee
282.nf
28314426 Black Walnut Ct.
284.nf
285Saratoga, CA 95070, USA
286.nf
287SFF FaxAccess: +01 408-741-1600
288.nf
289Ph: +01 408-867-6630
290.nf
291Fax: +01 408-867-2115
292.nf
293E-Mail: 250-1752@mcimail.com.
294.PP
295Please let us know if there is an on\-line source for this document.
296
297.nf
298$Id: smartctl.8,v 1.2 2002/10/09 18:07:17 ballen4705 Exp $
Note: See TracBrowser for help on using the browser.