Save power with PowerTOP 2.0

May 12th, 2012

In order to optimize power consumption PowerTOP can be utilized in its recent version 2.0. Ubuntu 12.04 ships with 1.97 so if you want to benefit from the latest and greatest you’ll have to compile for yourself. However this is not a big deal.

  • download PowerTOP
  • extract file and enter dir
  • sudo apt-get install build-essential checkinstall
  • ./autogen.sh
  • ./configure
  • (install everything configure complains about, then rerun configure)

  • ./make
  • sudo checkinstall
  • Samsung P580 backlight brightness on Ubuntu 12.04

    May 12th, 2012

    After everything else works out of the box with a fresh install of Ubuntu 12.04 I realized that brightness control via FN key doesn’t. The problem seems to be somewhere located in the Nvidia driver for GT330M and can easily be solved by adding one line to the “Device” section of /etc/X11/xorg.conf.

    Hit ALT-F2

    gksu gedit /etc/X11/xorg.conf

    add

    Option "RegistryDwords" "EnableBrightnessControl=1"

    to the “Device” section so it looks somewhat like this

    Section "Device"
    Identifier "Default Device"
    Option "NoLogo" "True"
    Option "RegistryDwords" "EnableBrightnessControl=1"
    EndSection

    save file and finally reboot or restart lightdm with

    sudo service lightdm restart

    and brightness control is back in your hands!

    wicd – iwlwifi problems solved

    May 11th, 2012

    Last week I posted about my connection problems with iwlwifi and network manager. For the duration of a week I have tested wicd as an alternative connection tool on two Intel machines and must say: no disconnections or any problems whatsoever so far! iwlwifi options can be set to N speed and no modifications other than stopping the LED from blinking are necessary.

    Gnome 3.4 window buttons on left side

    May 6th, 2012

    First install dconf-tools with

    sudo apt-get install dconf-tools

    start dconf-editor

    dconf-editor

    and change org > gnome > shell > overrides > button-layout to

    close,minimize,maximize:

    Done!

    Ubuntu 12.04 and ath9k

    May 5th, 2012

    Wireless is traditionally troublesome on Linux. The other day I transferred a lot of data over my wifi. After iwlwifi is finally stable for Intel devices using wicd, ath9k for Atheros wasn’t. It nearly passed out a couple of times leaving me with unusable connection speed.

    I’m still testing if the culprit is hardware encryption or maybe power saving. For now I disabled hardware encryption with

    sudo nano /etc/modprobe.d/ath9k.conf

    adding

    options ath9k nohwcrypt=1

    and rebooting.

    No further problems until now.

    Ubuntu 12.04 and VDPAU on Nvidia

    May 5th, 2012

    Although the new Unity experience is a smooth and snappy one desktop wise, video playback is a little choppy and sluggish. Even when using GPU powered VDPAU compiz is using a lot more CPU than it should and playback all in all is not enjoyable for me. Unlike earlier releases tearing is not a problem though.

    Installing Gnome Shell works much better for video. But the new 3.4 desktop feels not as good as 3.2 did. So not a real option either.

    Fortunately there is xbmc with its great media center software. For the first time available from standard Ubuntu repositories. Using it from within either Unity or Gnome suffers from the underlying desktop environments. Choosing the xbmc session from lightdm however delivers what any media enthusiast would want. Playback is smooth, CPU is very low and I’m happy again.

    Ubuntu 12.04 iwlwifi connection troubles

    May 4th, 2012

    I have one laptop running over night sometimes. That requires a stable wifi connection which I found out Ubuntu 12.04 with iwlwifi could not offer. Often I returned to the desktop in the morning and network-manager disconnected hours ago without establishing a new connection. So no down and uploads since then. Manually trying to reconnect doesn’t work either. One either has to switch off and on wifi or unload and reload the iwlwifi module.

    I experimented with iwlwifi options 11n_disable and swcrypto as some people on the net suggested but no luck. Wifi kept disconnecting unpredictably. Then I stumbled upon one bug addressing this misbehavior to network-manager suggesting to remove it and install wicd. That was what I did last week and had not one disconnection since then!

    sudo apt-get install wicd
    sudo apt-get remove --purge network-manager network-manager-gnome

    Caution: you will lose your network indicator and wicd will not show anywhere in Unity. Doesn’t matter to me since I monitor my network along with other information with Conky.

    Ubuntu 12.04 LTS Beta on Acer 1810t

    April 15th, 2012

    Although being in beta state Ubuntu 12.04 LTS runs great on my Acer 1810t already. There are just three annoyances I had to tinker with.

    Fan always on and too loud (AC)

    With an AC cable plugged in the fan is always on which is very audible in a quiet environment. This can be controlled using kernel module acerhdf which is loaded by default but lacks finetuning. So all you have to do is create a configuration file

    sudo nano /etc/modprobe.d/acerhdf.conf

    and paste in the appropriate settings

    options acerhdf interval=5 fanon=65000 fanoff=60000 kernelmode=1

    and here comes silence! Use temperature settings at your own risk. The example above turns the fan on at 65° C and off at 60° C.

    Noisy harddisk spindowns

    Second thing is hdparm settings when running on battery. Former apm (Advanced Power Management) default for the harddrive in Oneiric was 128. It is now 127 which allows the drive to spin down resulting in frequent spin downs and wakeups which are audible and annoying. This can be avoided by setting apm back to 128 when running on battery

    sudo hdparm /etc/sda -B 128

    In order to make apm settings permanent add this to /etc/hdparm.conf

    /dev/sda {
    apm = 254
    apm_battery = 128
    }

    Constantly blinking wifi LED

    Well, for the LED to stop blinking when active but rather be just on it needs just an option to Intel’s wifi module. This however is not iwlagn as in Oneiric but iwlwifi in Precise. So create a config file

    sudo nano /etc/modprobe.d/iwlwifi.conf

    and paste

    options iwlwifi led_mode=1

    and reboot or unload module with

    sudo modprobe -r iwlwifi

    and reload with

    sudo modprobe iwlwifi

    Done!

    One-Liner to kill all WINEPREFIX instances

    March 24th, 2012

    Every now and then a casual game run with wine crashes on my girlfriend’s rig. She’s just a regular Ubuntu user and cannot be bothered with WINEPREFIX=~/.wine/game wineserver -k and probably some xrandr voodoo to correct screen resolution.

    Hence putting the following in her .bashrc as an alias or a script helps a lot:

    for i in ~/.wine/*; do WINEPREFIX=$i wineserver -k && xrandr -s 1366x768; done

    XBMC and VA API

    February 25th, 2012

    Having set up VA API like mentioned before compiling XBMC with support for hardware decoding on Intel G45 is pretty straight forward. No other steps have to be taken than to compile as mentioned in the README.ubuntu at http://gitorious.org/xbmc/xbmc/blobs/HEAD/README.ubuntu.

    I installed the dependencies and downloaded the source into subfolder xbmc with

    git clone git://github.com/xbmc/xbmc.git xbmc

    compiled with

    ./bootstrap && ./configure && make -j2

    and after compilation successfully finished

    sudo make install

    Works like a charm at least for 720p content in H.264.