HDD Cycle Count…

Whichever OS you are running, be it MS Windows or Linux, your Hard Drive could be working itself to death by performing anywhere between 4 – 150 cycles every 15 minutes. Here is some information of how to test your machine for this hard drive life-shortening issue in Ubuntu Linux (Gutsy and Hardy), as well as MS Windows (Towards end of post):

(DISCLAIMER: Please note that you apply any of the following at your own risk! The poster is not in any way to be held responsible for the outcome!)

– TEST your machine:

INSTALL SMART MONITOR TOOLS – Disk management software…

you can either open Synaptic Package Manager (System > Administration > Synaptic Package Manager) and search for or install the program (smartmontools) from there, or you can open a Terminal and copy/paste the following line:

sudo aptitude install smartmontools

ONCE INSTALLED RUN THIS COMMAND IN A TERMINAL – COPY THE WHOLE LINE AND PASTE IN A TERMINAL AND RUN IT AND IT WILL OUTPUT BOTH A LOADCYCLE COUNT AND TEMPERATURE FOR YOUR DISK
** NOTE
If your laptop disk is addressed as /dev/hda then change the above command to reflect that (to see if yours is hda or sda perform the command “sudo fdisk -l” and then look at output)

date; sudo smartctl -a /dev/sda | egrep '(Load_Cycle_Count|Temperature)'

MY OUTPUT AS AN EXAMPLE
193 Load_Cycle_Count 0x0012 083 083 000 Old_age Always - 171239
194 Temperature_Celsius 0x0002 137 137 000 Old_age Always - 40 (Lifetime Min/Max 11/54)

Notice the first line shows my load cycle count ( Look at last number )
And the second shows my temperature for my hard disk (40 degrees Cel.). Just write these both down on a piece of paper so we can refer back to them in a minute.

NOW — WAIT 15 MINUTES AND RUN THE COMMAND AGAIN

If in 15 minutes the load cycle count number listed in this commands output changes by more than 2-4 then it is probably too much for comfort. Move to applying the following fix…

The FIX:

(PLEASE NOTE: Setting the hdparm -B to the value of 255 will completely disable the hard drive head-parking feature which is desired if you use your laptop a lot on-the-go in potentially rough conditions. Hard Drive head-parking is a feature that allows the hard disk to park the head of the drive in a safe position when bumps or jolts are detected.)

1) make a file named “99-hdd-spin-fix.sh”. The important thing is starting with “99”.

2) make sure the file contains the following 2 lines (fix it if you have PATA HDD):
#!/bin/sh
hdparm -B 255 /dev/sda

3) copy this file to 3 locations:
/etc/acpi/suspend.d/
/etc/acpi/resume.d/
/etc/acpi/start.d/

After reboot you can again test your machine using the above testing method and you will notice a major difference!

If you have any questions you can write me at famsoftrc@gmail.com

For MS Windows Users:

Sourceforge (open source) has a Windows port of the utility that reports SMART (Self-Monitoring, Analysis and Reporting Technology System) data. LOAD_CYCLE_COUNT is Attribute 193.

The smartmontools don’t have a “pretty” GUI, but it is still point and click with results displayed in a CMD window. You want to look at the RAW count, which is the last column.

Download the Windows setup binary from the download page here:
http://sourceforge.net/project/sh….

2 Responses to “HDD Cycle Count…”

  1. Phil Says:

    I would NOT use the value of 255 if you HD does not support it, I would use 254 instead as that is safer… First of all find out what your HD supports with this command:
    sudo hdparm -I /dev/sda and then set it to the highest number…

    Usage examples:
    hdparm -I /dev/sda — identify disk (see above)
    hdparm -M 128 /dev/sda — set acoustic management to “quiet”
    hdparm -M 254 /dev/sda — set acoustic management to “fast”
    hdparm -S 120 /dev/sdb — set 2nd disks standby timeout to 10min
    hdparm -y /dev/sdb — set 2nd disk to standby mode
    hdparm -t /dev/sda — perform disk read timings
    hdparm –security-freeze /dev/sda — Freeze security settings
    (There are still BIOS versions which leave the drive vulnerable)

    Good link for explanation:
    http://ubuntuforums.org/showthread.php?t=591503&page=56


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: