wtorek, 6 listopada 2007

Ubuntu hard disk drive longevity

Last time I received info from my friend about problem with ubuntu acpi module on laptops. It seems, that while working on battery/powersave mode, hard disks of some manufacturers tried to park even two times per minute. It causes sometimes over two thousand parks a day. Problem is that manufacturers tells that disks works properly up to 400.000 parks. So if you have 200.000 you can start get worry, if over 500.000 you should be scared already. Better switch off your laptop now! ;)

How to check?
You should have installed smartmontools package. If you don't have try:

# apt-get install smartmontools

as root-user.

now you can type command:

# smartctl -a $DEVICE | grep Load_Cycle_Count

where $DEVICE is your disk device (ie.: /dev/sda)

Last number is our interesting. Now you know what to do.

If you want to introduce less strict power policy, here is workaround:

- create file named 99-something.sh (ie.: 99-diskpolicy.sh)
- insert there:

#!/bin/sh
hdparm -B 254 $DEVICE

(remember about $DEVICE)

- change mode of this file to 755 and owner to root (if not done already)
- copy file to directories: /etc/acpi/resume.d/ and /etc/acpi/start.d/

After next reboot proper policy will be applied.

More info is here

Brak komentarzy: