How can I turn off hard disk power management in 12.04?

an other option (I used myself) can be to edit the hdparm configuration file:

/etc/hdparm.conf

In there you find a commented line like this:

#apm = 255

Just delete the # to uncomment so that the hd power management will be disabled by default.

In my case I did it because my laptop disk was turned off and on several times in short time intervals. By the way I discovered that it is the BIOS that is doing that and not hdparm policies and the likes... It happens when I am on battery though.


If nothing else, you can do a dirty hack by using cron (the Linux task scheduler) to issue that command periodically. It's not exactly ideal though.

https://help.ubuntu.com/community/CronHowto