You need to download and compile it because no one have the latest version
Download powertop https://01.org/powertop/downloads/2013/powertop-v2.3
powertop-2.3.tar.gz < < < Click & Download Me
Before compiling you need to install dependencies
Installing Dependencies ( Just copy paste the following commands )
sudo apt-get install libtool autoconf libnl-dev ncurses-dev pciutils-dev build-essential -y
Installing Powertop
To build and install PowerTOP type the following commands,
cd Downloads/powertop* # assuming that you have downloaded in Downloads folder in you home directory
configure
make # use -j option if you want to see details below
make install
You can also use -j2 for how many cores you want to use in ./make.Replace -j2 with whatever number of CPU cores you want to use for the compilation process. for example i have used ./make -j8
Powertop is installed you can unplugged ac power and can run
sudo powertop
However, most of the settings are not saved and they are lost after a reboot. You, can, however, make them permanent, by using the commands provided in the PowerTOP html report. To generate an HTML report, run the following command: webupd8.org
sudo powertop --html=powertop.html
Implementing Powertop Suggestion On Battery And Back To Maximize Performance On Ac Power
For that you need to make a script that run powertop suggestion on battery and maximize the performance on ac power
Place it in /etc/pm/power.d/ and give execution rights
sudo gedit /etc/pm/power.d/power
Copy paste the following the following in power file
#!/bin/sh
# Shell script to reduce energy consumption when running battery. Place
# it in /etc/pm/power.d/ and give execution rights.
if on_ac_power; then
# Start AC powered settings --------------------------------------------#
# Disable laptop mode
echo 0 > /proc/sys/vm/laptop_mode
#NMI watchdog should be turned on
for foo in /proc/sys/kernel/nmi_watchdog;
do echo 1 > $foo;
done
# Set SATA channel: max performance
for foo in /sys/class/scsi_host/host*/link_power_management_policy;
do echo max_performance > $foo;
done
# CPU Governor: Performance
for foo in /sys/devices/system/cpu/cpu*/cpufreq/scaling_governor;
do echo performance > $foo;
done
# Disable USB autosuspend
for foo in /sys/bus/usb/devices/*/power/level;
do echo on > $foo;
done
# Disable PCI autosuspend
for foo in /sys/bus/pci/devices/*/power/control;
do echo on > $foo;
done
# Disabile audio_card power saving
echo 0 > /sys/module/snd_hda_intel/parameters/power_save_controller
echo 0 > /sys/module/snd_hda_intel/parameters/power_save
# End AC powered settings ----------------------------------------------#
else
# Start battery powered settings ---------------------------------------#
# Enable Laptop-Mode disk writing
echo 5 > /proc/sys/vm/laptop_mode
#NMI watchdog should be turned on
for foo in /proc/sys/kernel/nmi_watchdog;
do echo 0 > $foo;
done
# Set SATA channel to power saving
for foo in /sys/class/scsi_host/host*/link_power_management_policy;
do echo min_power > $foo;
done
# Select Ondemand CPU Governor
for foo in /sys/devices/system/cpu/cpu*/cpufreq/scaling_governor;
do echo ondemand > $foo;
done
# Activate USB autosuspend
for foo in /sys/bus/usb/devices/*/power/level;
do echo auto > $foo;
done
# Activate PCI autosuspend
for foo in /sys/bus/pci/devices/*/power/control;
do echo auto > $foo;
done
# Activate audio card power saving
# (sounds shorter than 5 seconds will not be played)
echo 5 > /sys/module/snd_hda_intel/parameters/power_save
echo 1 > /sys/module/snd_hda_intel/parameters/power_save_controller
# End battery powered settings -----------------------------------------#
fi
Now you need to assign execution permission of power script
sudo chmod +x /etc/pm/power.d/power
Now when you Unplugged, Powertop suggestion will take over and maximize the battery life & you Plugged in AC power you will have Max Performance.
Helpfull Links
http://ubuntuforums.org/showthread.php?t=1855126&page=3
http://www.webupd8.org/2012/08/install-powertop-21-in-ubuntu-1204.html
For -j Option http://dnscrypt.org/
sudo
to edit the file.powertop
might not be accurate due to internal battery re-calibrations. Source: askubuntu.com/questions/161774/…