Power saving tips for Ubuntu on laptops
My HP nc8430 also runs particularly hot by default - but I've spent a bit of time hunting down tips for reducing the power usage and heat produced from the laptop to get a longer battery life. I'm sure there are a lot more ways that power can be saved and I suspect that future versions of Ubuntu will catch up and produce the same level of battery life or even longer than windows.
Here is what I am using so far:
Set powerplay mode on ATI fglrx driver
aticonfig --set-powerstate=1 #set to low power mode
If anyone has equivalent code for other video cards please let me know and I'll add it here.
Disable 'hal' from polling your cdrom
From powertop: 'hal' is the component that auto-opens a window if you plug in a CD but disables SATA power saving from kicking in.
Disable bluetooth if you are not using it
sudo rmmod hci_usb
Remove the usb 1.1 kernel driver if not using it
Apparently the usb 1.1 driver does frequent polling and prevents the processor from staying in low power states for any length of time.
Increase the VM dirty writeback time
From powertop: This wakes the disk up less frequenty for background VM activity.
Turn off second processor
This is a very extreme measure and I haven't measured how much extra battery life it gives - but it is a bit cool to be able to turn it on and off if you have a dual core or dual CPU machine.
How cool is that?
Let me know if you come across any more tips. Cheers, Mark
Updated 17/Mar/07: Fixed commands based on feedback from Neil. Thanks Neil.




Sorry it didn't help much - did you have a look to see what device you cdrom is connected as? Try:
cat /etc/fstab
and look for a line that mentions cdrom, eg:
/dev/scd0 /media/cdrom0 udf,iso9660 user,noauto 0 0
/dev/scd0 might be something different on your machine.
Re the hci_usb - it probably means it's not loaded anyway - so nothing to save there. You can try the following command to check:
lsmod | grep hci
This will list all modules that have 'hci' in them. If it comes back empty then the module is not loaded.
Cheers,
Mark
sudo echo 1500 > /proc/sys/vm/dirty_writeback_centisecs
are correct
those echo as root but still try to write to file as the user
what you intend is done by
echo 1500 | sudo tee /proc/sys/vm/dirty_writeback_centisecs
Thanks for that - I've updated the samples above - and learned something new.
With a bit of digging I also found that you can suppress the output of the commands to the screen by appending piping the standard output to /dev/null. So the command would be:
echo 0 | sudo tee /sys/devices/system/cpu/cpu1/online > /dev/null
Cheers,
Mark