Ubuntu, Dell laptop and hard disk power management
There has been some talk those days on laptop hard disk lifespan. See, for example, what Pascal says about it.
So, after some investigation, I saw that on my laptop (Dell Latitude D420) the BIOS doesn't handle an APM value of 255. By default the startup scripts execute hdparm -B 255 /dev/sda (or other devices) and that actually sets the APM value to 128 (as given by hdparm -I /dev/sda | grep Advanced). (I'm using Ubuntu 7.10 -- the script I'm talking about is /etc/acpi/power.sh.)
On the other hand, using -B 254 seems to disable APM. So here's a way to do it, by default, on every boot:
- Add those lines to /etc/hdparm.conf:
/dev/sda {
apm = 254
} - Make /etc/init.d/hdparm run at startup:
ln -s /etc/init.d/hdparm /etc/rcS.d/S07hdparm
And now the load cycle count reported by SMART remains stable. Which means that hopefully my hard disk will live longer.
Addendum: if you don't use SMART, you should. Install the smartmontools package, enable SMART on your disks with smartctl -s on, and read the smartctl(8) manpage. Optionally, enable the smartd monitoring daemon (via /etc/default/smartmontools).