Tip of the Trade: Smartmontools
Linux, Unix, BSD, and Cywgin-on-Windows users can use the excellent smartmontools package, which includes the smartctl and smartd commands, for monitoring and controlling PATA, SATA, and SCSI hard disks. smartmontools works on drives that have the Self-Monitoring, Analysis and Reporting Technology (S.M.A.R.T.) system built into them. With smartmontools, you can test drive health and set it up to monitor drives so early warnings of possible drive failures are issued. Got S.M.A.R.T. drives? Consider adding smartmontools to test and monitor drive health as well as issue early warnings of possible failures.
S.M.A.R.T. is usually not enabled by default. There are two ways to turn it on: via the BIOS options in many PCs or with the smartctl command. But first, see if it's supported:
# smartctl -i -d ata /dev/sda smartctl version 5.37 [i686-pc-linux-gnu] Copyright (C) 2002-6 Bruce Allen Home page is http://smartmontools.sourceforge.net/ === START OF INFORMATION SECTION === Model Family: Western Digital Caviar SE (Serial ATA) family Device Model: WDC WD800JD-00MSA1 Serial Number: WD-WMAM9S474555 Firmware Version: 10.01E01 User Capacity: 80,026,361,856 bytes Device is: In smartctl database [for details use: -P show] ATA Version is: 7 ATA Standard is: Exact ATA specification draft version not indicated Local Time is: Thu Feb 7 13:09:37 2008 PST SMART support is: Available - device has SMART capability. SMART support is: Disabled
# smartctl -s on -d ata /dev/sda
# smartctl -H -d ata /dev/sda smartctl version 5.37 [i686-pc-linux-gnu] Copyright (C) 2002-6 Bruce Allen Home page is http://smartmontools.sourceforge.net/ === START OF READ SMART DATA SECTION === SMART overall-health self-assessment test result: PASSED
# smartctl -l error -d ata /dev/sda
You can also run more extensive as well as set it up for continual monitoring. man smartctl and Monitoring Hard Disks with SMART tell all.