more battery, please

After I found out that the enhanced Gnome power manager applet has some trouble dealing with two batteries (it currently assumes you have only one and therefore it’s ability to guess the correct lifetime based on recent discharging times shows you definitely wrong spans when swapping the battery). But to be honest, this bug isn’t that grave to drop more words about this – I am quite sure it will be fixed soon.

More interesting instead is the possibility to save power. At least with gutsy you have the possibility to install Intel’s „powertop“ utility – a command line tool for measuring power consumption and detecting possible power leaks. I heard a lot of bad words about powertop, I for myself am quite satisfied about it and it’s documentation and hints on the website.

After dealing with it for some time, I wrote the following quite stupid but effective script, that extends my battery life time for some percent:

#!/bin/dash
# stop not essentially needed daemons
/etc/init.d/cupsys stop
/etc/init.d/tor stop
/etc/init.d/privoxy stop
/etc/init.d/bluetooth stop
/etc/init.d/racoon stop
/etc/init.d/postfix stop
/etc/init.d/cron stop
/etc/init.d/sysklogd stop
/etc/init.d/klogd stop
# decrease wlan power consumption (if wlan is not needed: switch it off!)
iwpriv eth1 set_power 5
# increase writeback time
echo 1500 > /proc/sys/vm/dirty_writeback_centisecs
# enable ac97 sound power save mode
echo 1 > /sys/module/snd_ac97_codec/parameters/power_save
# enable usb power save (actually not needed as it gets killed afterwards)
echo 1 > /sys/module/usbcore/parameters/autosuspend
# switch off usb
modprobe -r ehci_hcd
modprobe -r uhci_hcd
# switch off bluetooth
modprobe -r rfcomm
modprobe -r l2cap
modprobe -r bluetooth
# put harddisk to power save mode (spin down)
hdparm -B 1 -S 12 /dev/sda
# activate quiet hard disk mode - probably not needed when using the power save mode
hdparm -M 128 /dev/sda
# remount active partitions with noatime
mount -o remount,noatime /
mount -o remount,noatime /mnt/cryptdevice
# active laptop mode
echo 5 > /proc/sys/vm/laptop_mode

So you might guess I am not the hardware guru and you are right about it. But maybe this snippet is a good starting point for you to save some power. And yes, you can also save power on your desktop pc. It will not extend a battery lifetime but maybe the one of your purse.

Feel free to drop some of your hints or rants in the comment field.

Ubuntu on OLPC XO anonye?

While waiting for the delivery of my One Laptop per Child OLPC XO, ordered through the great Give one Get One program (you can order until 31. of December and yes, you can do it from outside U.S. e.g. Europe too, as the FAQ shows you), I’s nearly unhappy to see a lot of guys walking around with an OLPC XO at the annualy ccc hacker convention 24C3 while being nearly jealous :) Despite of dozens of OLPCs around here, at this time, nobody could answer my question whether there already had been serious efforts to bring Ubuntu to the little green thingy with the official bunny ears.

As far as Google knows, there exists an Ubuntu launchpad blueprint entitled „Ubuntu for the One Lap Top Per Child Project„, that brings up some hope but to be honest, there are dozens of interesting blueprints. So is anybody of you right now dealing with an installation of Ubuntu on the XO or knows someone around who does so?

(And yes, I know, that the Eeepc is a nice tool, too. But it just has no bunny ears, you know.)