Skip to content
Snippets Groups Projects
Select Git revision
  • 2872fa34a3c0494a7f63a685993eafa5cb8e5697
  • master default
2 results

pykat_LLO.py

Blame
  • Forked from finesse / pykat
    Source project has a limited visibility.
    index.html 22.22 KiB
    <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    <html>
    <head>
      <title>smartmontools Home Page</title>
                                                                            
                            
      <meta http-equiv="content-type"
     content="text/html; charset=ISO-8859-1">
                       
      <meta name="author" content="Bruce Allen">
                       
      <meta name="description"
     content="SMART S.M.A.R.T. linux disk monitoring">
    </head>
      <body>
                       
    <div align="center">    
    <h1><font color="#3333ff">smartmontools HOME PAGE &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; 
     </font>  <a href="http://sourceforge.net"><img
     src="http://sourceforge.net/sflogo.php?group_id=64297&amp;type=5"
     width="210" height="62" border="0" alt="SourceForge.net Logo"
     align="middle">
        </a> </h1>
        </div>
                               
    <div align="left">This is the home page for smartmontools. &nbsp;The smartmontools
           package contains two utility programs (<font color="#3333ff"><b>smartctl</b></font>
                   and <font color="#3333ff"><b>smartd</b></font>) to control 
    and   monitor     storage systems using the Self-Monitoring, Analysis and 
    Reporting   Technology     System  (S.M.A.R.T.) built into most modern ATA 
    and SCSI hard  disks.  It   is derived from the smartsuite package, and includes 
    support   for ATA/ATAPI-5     disks. It should run on any modern linux system.<br>
               <br>
               For your convenience, this is a single page, so you can print
    it  easily.<br>
                             
    <hr width="100%" size="2">           
    <ul>
                 <li><a href="#howtodownload">How to download and install smartmontools</a></li>
                  <li><a href="#FAQ">Frequently Asked Questions</a></li>
                 <li><a href="#testinghelp">The code needs to be tested on SCSI 
     disks/tapes</a></li>
                    <li><a href="#differfromsmartsuite">How does smartmontools
     differ    from  smartsuite?</a></li>
                         <li><a href="#references">Useful references on S.M.A.R.T.
       and   ATA/ATAPI-5,   -6, and -7</a></li>
                 <li><a href="#sampleoutput">Some sample output from smartmontools</a></li>
                    <li><a
     href="http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/smartmontools/">Smartmontools 
         CVS archive</a> and <a
     href="http://sourceforge.net/projects/smartmontools">SourceForge projects 
         group page</a></li>
          <li><a
     href="http://lists.sourceforge.net/mailman/listinfo/smartmontools-support">
        Mailing list and archives</a> for smartmontools support<br>
          </li>
                                        
    </ul>
              <b><br>
               </b>           
    <hr width="100%" size="2"><b><br>
               </b><b><a name="howtodownload"></a></b><b> How to download and 
    install     smartmontools<br>
               </b>There are three different ways to get and install smartmontools. 
       &nbsp;You   can use any one of these three procedures. &nbsp;Just after 
     "Method  3" below are some instructions for trying out smartmontools once 
     you have completed the installation.<br>
                         
    <ol>
                 <li><b>First Method - Install from the RPM file:</b><br>
                                                         
        <ul>
                   <li>Download the latest binary RPM file (<tt>*.rpm</tt>) from
               <a
     href="http://sourceforge.net/project/showfiles.php?group_id=64297">here</a>
             . &nbsp;Don't get the SRPM file (<tt>*.src.rpm</tt>).</li>
                   <li>Install it using RPM. &nbsp;You must be root to do this:<br>
                     <tt>su root</tt> &nbsp;(enter root password)<br>
                     <tt>rpm -ivh smartmontools-5.0-1.i386.rpm<br>
               </tt>For most users, this is all that is needed.<br>
             </li>
                   <li>If you receive an error message, you have probably previously
        installed the <tt>smartsuite</tt> package, or RedHat's <tt>kernel-utils</tt>
       package,    which provide older versions of the <tt>smartd</tt> and <tt>
      smartctl</tt>       utilities. &nbsp;In this case you should use the <tt>
      --nodeps</tt> or          <tt>  --force</tt>  arguments of rpm to replace
     these two utilities:<br>
                     <tt>rpm -ivh --nodeps --force smartmontools-5.0-1.i386.rpm</tt></li>
             <li>If you want to remove the package (<tt>rpm -e s</tt><tt>martmontools-5.0-1</tt>
       ) and your system does not have <tt>chkconfig</tt> installed, you may
    need  to use the <tt>--noscripts</tt> option to <tt>rpm -e</tt>.<br>
                   </li>
                                                         
        </ul>
               </li>
                 <li><b>Second Method - Install from the source tarball</b>:<br>
                                                               
        <ul>
                    <li>Download the latest source-code tarball from <a
     href="http://sourceforge.net/project/showfiles.php?group_id=64297">here</a>.
    Note: you probably want the most recent release.
     </li>
                    <li>Uncompress the tarball:<br>
                      <tt>tar zxvf smartmontools-5.0-1.tar.gz</tt></li>
                    <li>The previous step created a directory called smartmontools-5.0-1
         containing the code. &nbsp;Go to that directory, build, and install:<br>
                      <tt>cd smartmontools-5.0-1<br>
              make<br>
               make install &nbsp;</tt> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 
      &nbsp;    &nbsp; &nbsp; &nbsp; &nbsp;[only root can do this]<br>
                   </li>
                                                                            
        </ul>
                </li>
                 <li><b>Third Method - Download code directly from the CVS archive:</b><br>
                                     
        <ul>
                <li>Download the latest code snapshot from CVS. If prompted for 
     a  password,    simply press the Enter key. &nbsp;Note that the two lines 
     below  that start   "<tt>cvs</tt>" are long! <br>
                     <tt>cvs -d:pserver:anonymous@cvs.smartmontools.sourceforge.net:/cvsroot/smartmontools 
         login</tt> <tt><br>
               cvs -z3 -d:pserver:anonymous@cvs.smartmontools.sourceforge.net:/cvsroot/smartmontools 
         co sm5</tt><br>
                   </li>
                <li>The previous step created a subdirectory called <tt>sm5/</tt>
         containing    the code. Go to that directory, build, and install:<br>
                     <tt>cd sm5<br>
               make<br>
               make install &nbsp;</tt> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 
      &nbsp;    &nbsp; &nbsp; &nbsp; &nbsp;[only root can do this]<br>
                   </li>
                                          
        </ul>
                                  </li>
             
    </ol>
                 <b>After installing using Method 1, 2 or 3 above, you can read 
     the   man pages, and try out the commands:</b><br>
                   
    <blockquote>                        
      <blockquote><tt>man 8 smartctl</tt><br>
                <tt>man 8 smartd</tt><br>
                <tt>/usr/sbin/smartctl -etf /dev/hda &nbsp;</tt>[only root can
     do this]<br>
                <tt>/usr/sbin/smartctl -a /dev/hda &nbsp; &nbsp;</tt>[only root 
     can do this]</blockquote>
            </blockquote>
             Note that the default location for the manual pages is in <tt>/usr/share/man/man8</tt>
       . &nbsp;If "<tt>man</tt>" does not find the manual pages, then you may 
    need to add <tt>/usr/share/man</tt> to your <tt>MANPATH</tt> environment variable.<br>
         
    <hr width="100%" size="2"><br>
               <br>
               <a name="FAQ"></a><b>Frequently-asked questions<br>
               </b>If your question is not here, please <a
     href="mailto:smartmontools-support@lists.sourceforge.net"> email me</a>.<br>
                         
    <ul>
                 <li><b>What do I do if I have problems, or need support? &nbsp;Suppose
      I want to become a developer, or suggest some new extensions?</b><br>
        Please send an email to the <a
     href="http://lists.sourceforge.net/mailman/listinfo/smartmontools-support">
        smartmontools-support mailing list</a>.<br>
          </li>
          <li><b>What are the future plans for smartmontools?</b><br>
               My plan is that smartmontools-5.x will support ATA/ATAPI-5 disks.
      &nbsp;Eventually,     we'll do smartmontools-6.x to support ATA/ATAPI-6
    disks,  smartmontools-7.x     for the ATA/ATAPI-7 standard, and so on. &nbsp;The
     "x" will denote revision    level, as bugs get found and fixed, and as enhancements
      get added. &nbsp;    If it's possible to maintain backwards compatibility,
      that would be nice,    but I don't know if it will be possible or practical.</li>
                 <li><b>Why are you doing this?</b><br>
               My research group runs a beowulf cluster with 300 ATA-5 disks. 
    &nbsp;We     have more than 20 TB of data stored on the system. &nbsp;It's 
    nice to have    advanced warning when a disk is going to fail.</li>
                <li><b>I see some strange output from smartctl. &nbsp;What does 
     it  mean?</b><br>
              The raw S.M.A.R.T. attributes (temperature, power-on lifetime,
    and   so  on)  are stored in vendor-specific structures. &nbsp;Sometime these
    are  strange.   &nbsp;Hitachi disks (at least some of them) store power-on
    lifetime  in minutes,   rather than hours. &nbsp;IBM disks (at least some
    of them) have three temperatures stored in the raw structure, not just one.
    And so on. &nbsp;If you find strange output, or unknown attributes, please
    send an email to <a
     href="ttp://lists.sourceforge.net/mailman/listinfo/smartmontools-support">
        smartmontools-support</a> and we'll help you try and figure it out.</li>
                <li><b>What attributes does smartmontools not yet recognize?<br>
                  </b>From a Hitachi disk: (230)(250)<br>
              If you can attach names/meanings to these attributes, please send 
     me  a note to <a
     href="ttp://lists.sourceforge.net/mailman/listinfo/smartmontools-support">
        smartmontools-support</a>.</li>
            <li><b>When I run <tt>smartd</tt> , the SYSLOG (<tt>/var/log/messages</tt>
          ) contains messages like this:</b><br>
              <tt>smartd: Reading Device /dev/sdv <br>
          modprobe: modprobe: Can't locate module block-major-65<br>
              </tt>This is because when <tt>smartd</tt> starts, it looks for
    all   ATA  and SCSI devices to monitor (matching the pattern <tt>/dev/hd[a-z]</tt>
         or      <tt>/dev/sd[a-z]</tt>). &nbsp;The log messages appear because
     your  system  doesn't have most of these devices.<br>
          A future release of smartd will have a command-line option to specify 
     which  devices to include or exclude from start-up search.<br>
            </li>
                         
    </ul>
               
    <hr width="100%" size="2"><b><a name="testinghelp"></a>Help needed in testing 
         smartmontools, especially on SCSI disks/systems<br>
               </b>I have access to a number of systems with ATA S.M.A.R.T. disks,
       but   I don't have any access to systems with SCSI S.M.A.R.T. devices.
    &nbsp;I'd     be very grateful to find someone who could help me test the
    smartmontools     code on SCSI disks. &nbsp;Since it's derived from the smartsuite
    package,     it should initially work about the same way with SCSI devices
    as the smartsuite     tools did.<br>
               <br>
               I'd be especially happy if someone would like to take on the task, 
      as  a  developer, of maintaining the SCSI code. &nbsp;Do you have a beowulf
       cluster   with a few hundred SCSI disks? Please volunteer!<br>
                         
    <hr width="100%" size="2"><a name="differfromsmartsuite"></a><b>How does smartmontools
    differ from smartsuite?<br>
    </b>The smartsuite code was originally developed as a Senior Thesis by Michael Cornwell
    at the Concurrent Systems Laboratory (now part of the <a
     href="http://ssrc.soe.ucsc.edu">Storage Systems Research Center</a>), Jack
    Baskin School of Engineering, University of California, Santa Cruz. <br>
    <b><br>
               </b>Smartmontools was derived directly from smartsuite .  It differs
    from smartsuite in that it supports
    the ATA/ATAPI-5 standard.   So for example <tt>smartctl</tt> from smartsuite
    has no facility  for printing  the S.M.A.R.T. self-test logs, and doesn't
    print timestamp information  in the most  usable  way.   The  <tt>smartctl</tt>
     utility in smartmontools has added functionality (<tt>-l,</tt><tt>-L,-f,
    -F and -m</tt> options),  updated documentation, and also fixes small technical
    bugs in smartsuite. <br>
     <br>
               The other principle difference is that smartmontools is an open-source 
    development project, meaning that we keep the files in CVS, and   that  other 
    developers who wish to contribute can commit changes to the archive. &nbsp;If 
    you would like to contribute, please write to to <a
     href="ttp://lists.sourceforge.net/mailman/listinfo/smartmontools-support">
        smartmontools-support</a>.<br>
     <br>
     But the bottom line is that the code in smartmontools is derived directly 
    from smartsuite  and is very similar.  The smartsuite package can be found
    <a href="http://sourceforge.net/projects/smartsuite/">here</a>. &nbsp;<br>
                         
    <hr width="100%" size="2"><br>
                  <a name="references"></a><big><b>Useful references on S.M.A.R.T.
       and   the   ATA/ATAPI standards<br>
                  </b>If you are having trouble understanding the output of smartctl
        or  smartd,  please first read the manual pages:<tt><br>
                 &nbsp;&nbsp;&nbsp; man 8 smartctl<br>
                 &nbsp;&nbsp;&nbsp; man 8 smartd</tt><br>
                  If you'd like to know more about S.M.A.R.T., then the following 
      references     may be helpful:<br>
                 </big>             
    <ul>
                   <li>The <a href="http://www.t13.org/project/d1321r1c.pdf">
    ATAPI/ATA-5       Revision 1 specification</a></li>
                   <li><a href="http://www.t13.org/#FTP_site">Earlier and later 
     revisions      of the ATAPI/ATA specifications</a></li>
                   <li>The S.M.A.R.T. specification is SFF-8035i (rev E). &nbsp;I 
      can   not   find an on-line reference. It can be obtained from the <a
     href="http://www.sffcommittee.com/ns/">Small Form Factors  Committee</a>
              . Here is their <a
     href="ftp://ftp.seagate.com/sff/INF-8035.TXT"> "link"</a>        .</li>
                             
    </ul>
                           
    <hr width="100%" size="2"><a name="sampleoutput"></a><b>Sample output from 
         smartmontools</b><br>
                <tt>      </tt>       
    <pre><tt>root#  /usr/sbin/smartctl -am /dev/hda<br>smartctl version 5.0-6 Copyright (C) 2002 Bruce Allen<br>Home page of smartctl is http://smartmontools.sourceforge.net/<br><br>Device Model:     HITACHI_DK23BA-20<br>Serial Number:    12H7M8<br>Firmware Version: 00E0A0D2<br>ATA Version is:   5<br>ATA Standard is:  ATA/ATAPI-5 T13 1321D revision 1<br>SMART support is: Enabled<br><br>SMART overall-health self-assessment test result: PASSED<br><br><br>General SMART Values: <br>Off-line data collection status: (0x00)	Offline data collection activity was<br>					never started.<br><br>Self-test execution status:      (   0)	The previous self-test routine completed<br>					without error or no self-test has ever <br>					been run.<br><br>Total time to complete off-line <br>data collection: 		 (1530) seconds.<br><br>Offline data collection<br>capabilities: 			 (0x1b) SMART execute Offline immediate.<br>					Automatic timer ON/OFF support.<br>					Suspend Offline collection upon new<br>					command.<br>					Offline surface scan supported.<br>					Self-test supported.<br><br>SMART capabilities:            (0x0003)	Saves SMART data before entering<br>					power-saving mode.<br>					Supports SMART auto save timer.<br><br>Error logging capability:        (0x01)	Error logging supported.<br><br>Short self-test routine <br>recommended polling time: 	 (   2) minutes.<br><br>Extended self-test routine <br>recommended polling time: 	 (  26) minutes.<br><br>Vendor Specific SMART Attributes with Thresholds:<br>Revision Number: 16<br>Attribute                    Flag     Value Worst Threshold Raw Value<br>(  1)Raw Read Error Rate     0x000d   100   084   050       247<br>(  3)Spin Up Time            0x0007   100   100   050       0<br>(  4)Start Stop Count        0x0032   100   100   050       197<br>(  5)Reallocated Sector Ct   0x0033   100   100   010       12<br>(  7)Seek Error Rate         0x000f   100   100   050       330<br>(  9)Power On Hours          0x0032   100   100   060       482 h +  4 m<br>( 10)Spin Retry Count        0x0013   100   100   050       0<br>( 12)Power Cycle Count       0x0032   100   100   050       197<br>(192)Power-Off Retract Count 0x0032   100   100   050       13<br>(195)Hardware ECC Recovered  0x001a   100   065   050       191<br>(196)Reallocated Event Count 0x0032   099   099   001       12<br>(197)Current Pending Sector  0x0032   097   096   001       3<br>(198)Offline Uncorrectable   0x0010   097   096   001       15<br>(199)UDMA CRC Error Count    0x003e   200   200   000       0<br>(221)G-Sense Error Rate      0x000a   100   100   050       0<br>(223)Load Retry Count        0x0012   100   100   050       0<br>(225)Load Cycle Count        0x0032   098   098   050       822100607<br>(230)Unknown Attribute       0x0032   100   100   060       13875<br>(250)Unknown Attribute       0x000a   100   070   050       937<br><br>SMART Error Log<br>SMART Error Logging Version: 1<br>ATA Error Count: 9 (only the most recent five errors are shown below)<br><br>Acronyms used below:<br>DCR = Device Control Register<br>FR  = Features Register<br>SC  = Sector Count Register<br>SN  = Sector Number Register<br>CL  = Cylinder Low Register<br>CH  = Cylinder High Register<br>D/H = Device/Head Register<br>CR  = Content written to Command Register<br>ER  = Error register<br>STA = Status register<br><br>Timestamp is time (in seconds) since the command that caused an error was accepted,<br>measured from the time the disk was powered-on, during the session when the error occurred.<br>Note: timestamp "wraps" after 1193.046 hours = 49.710 days = 2^32 seconds.<br><br>Error Log Structure 1:<br>Error occurred at disk power-on lifetime: 458 hours<br>When the command that caused the error occurred, the device was active or idle.<br>After command completion occurred, registers were:<br>ER:40 SC:01 SN:15 CL:be CH:2e D/H:e0 ST:51<br>Sequence of commands leading to the command that caused the error were:<br>DCR   FR   SC   SN   CL   CH   D/H   CR   Timestamp<br> 00   00   01   15   be   2e    e0   c8     831.599<br> 00   00   01   14   be   2e    e0   c8     831.594<br> 00   00   01   13   be   2e    e0   c8     831.594<br> 00   00   01   12   be   2e    e0   c8     831.594<br> 00   00   01   11   be   2e    e0   c8     831.594<br><br>Error Log Structure 2:<br>Error occurred at disk power-on lifetime: 458 hours<br>When the command that caused the error occurred, the device was active or idle.<br>After command completion occurred, registers were:<br>ER:40 SC:45 SN:15 CL:be CH:2e D/H:e0 ST:51<br>Sequence of commands leading to the command that caused the error were:<br>DCR   FR   SC   SN   CL   CH   D/H   CR   Timestamp<br> 00   00   80   da   bd   2e    e0   c8     829.680<br> 00   00   80   5a   bd   2e    e0   c8     829.677<br> 00   00   80   da   bc   2e    e0   c8     829.673<br> 00   00   80   5a   bc   2e    e0   c8     829.671<br> 00   00   01   58   bc   2e    e0   c8     829.671<br><br>Error Log Structure 3:<br>Error occurred at disk power-on lifetime: 458 hours<br>When the command that caused the error occurred, the device was active or idle.<br>After command completion occurred, registers were:<br>ER:40 SC:01 SN:47 CL:bc CH:2e D/H:e0 ST:51<br>Sequence of commands leading to the command that caused the error were:<br>DCR   FR   SC   SN   CL   CH   D/H   CR   Timestamp<br> 00   00   01   47   bc   2e    e0   c8     826.962<br> 00   00   01   46   bc   2e    e0   c8     826.961<br> 00   00   01   45   bc   2e    e0   c8     826.961<br> 00   00   01   44   bc   2e    e0   c8     826.961<br> 00   00   01   43   bc   2e    e0   c8     826.961<br><br>Error Log Structure 4:<br>Error occurred at disk power-on lifetime: 458 hours<br>When the command that caused the error occurred, the device was active or idle.<br>After command completion occurred, registers were:<br>ER:40 SC:13 SN:47 CL:bc CH:2e D/H:e0 ST:51<br>Sequence of commands leading to the command that caused the error were:<br>DCR   FR   SC   SN   CL   CH   D/H   CR   Timestamp<br> 00   00   80   da   bb   2e    e0   c8     825.038<br> 00   00   80   5a   bb   2e    e0   c8     825.033<br> 00   00   80   da   ba   2e    e0   c8     825.030<br> 00   00   80   5a   ba   2e    e0   c8     824.940<br> 00   00   80   da   b9   2e    e0   c8     824.937<br><br>Error Log Structure 5:<br>Error occurred at disk power-on lifetime: 458 hours<br>When the command that caused the error occurred, the device was active or idle.<br>After command completion occurred, registers were:<br>ER:40 SC:01 SN:85 CL:19 CH:2c D/H:e0 ST:51<br>Sequence of commands leading to the command that caused the error were:<br>DCR   FR   SC   SN   CL   CH   D/H   CR   Timestamp<br> 00   00   01   85   19   2c    e0   c8     816.487<br> 00   00   01   84   19   2c    e0   c8     816.487<br> 00   00   01   83   19   2c    e0   c8     816.486<br> 00   00   01   82   19   2c    e0   c8     816.486<br> 00   00   01   81   19   2c    e0   c8     816.486<br><br>SMART Self-test log, version number 1<br><br>Num  Test_Description    Status                  Remaining  LifeTime(hours)  LBA_of_first_error<br># 1  Short captive       Completed                     00%       459         <br># 2  Short captive       Completed                     00%       459         <br># 3  Extended off-line   Completed: read failure       40%       455         0x002c1985<br># 4  Extended off-line   Aborted by host               50%       455         <br># 5  Short off-line      Completed                     00%       451         <br># 6  Short off-line      Completed                     00%       451         <br># 7  Extended off-line   Completed: read failure       40%       449         0x002c1985<br># 8  Short off-line      Completed: read failure       20%       391         0x0003e00a<br># 9  Short captive       Interrupted (host reset)      40%       390         <br>#10  Short captive       Interrupted (host reset)      40%       390         <br>#11  Short off-line      Completed: read failure       20%       390         0x0003e00a<br>#12  Extended off-line   Completed: read failure       40%       247         0x002c1979<br><br></tt></pre>
            <tt>    </tt>             
    <hr width="100%" size="2">Page maintained by <a
     href="mailto:smartmontools-support@lists.sourceforge.net">Bruce Allen</a><br>
               <big> </big></div>
                                       
    </body>
    </html>