Since I am running the 2.6.6 kernel on my laptop now, I decided to take a look at
laptop mode
since it’s included in the kernel now. The laptop-mode.txt
readme that comes with the kernel has the approprate scripts in
it, so I copied out the /sbin/laptop-mode script and ran it. I
saw no mention of JFS support in the readme or the script
however, so decided to go look on the net. The
laptop mode
page does say that JFS is supported, but thats it. Digging
around on google got me a discussion about JFS and laptop mode
on the JFS list. Looks like JFS didn’t need any modifications to
work with laptop mode, it just works. So, then I did a
‘/sbin/laptop-mode start’ and a ‘hdparm -S 4 /dev/hda’ to set
the spindown time on my drive low and start laptop mode. Nothing
happened. To figure out what was keeping my drive spun up, I
used: “echo 1 > /proc/sys/vm/block_dump”. That spews out every
process that hits the disk and if it’s a read/write or a cache
hit. Using that I fixed a few things: Set syslog to not sync
after each log (a – before the filename), closed some firefox
windows that were autorefreshing and writing to cache, setup
syslog not to log my fetchnews jobs on each run. Tried laptop
mode again, but it still wouldn’t spin down. The drive was
inactive as far as I could tell. Perhaps it’s an issue with my
drive somehow, so I looked around a bit more and pulled down
smart_spindown
which is a handy script that checks for activity and then spins down
your drive if there isn’t any. It has backoff so that if things
seem busy it will wait longer and longer to spin it down. Using
that script things spun down and appeared to work ok. Running it
overnight I was able to see up to about 10min of spin down time
at various points, sometimes as little as 30 seconds. I think
this might be worth the savings if you were really hurting for
power, but otherwise seems kinda pointless.