Power saving for laptops
sudo apt-get install powertop indicator-power upower laptop-mode-tools
then run the following
gksu lmt-config-gui ;for laptop mode tools sudo powertop --calibrate ;note will run for some time
turn off bluetooth, check power settings for suspends
1). Enter the following in terminal: sudo gedit /etc/rc.local
2). Enter: rfkill block bluetooth
Suspend and hibernate
Suspend saves everthing to RAM, hibernate to disk. Suspend wakes up faster, Hibernate saves your batteries more. Hybrid modes try to combine the best of both worlds.
Ubuntu guide how to hibernate my computer and test it
Archlinux page on suspend and hibernate
good Archlinux thread on troubleshooting
Hibernate
ways to hibernate
pm-hibernate
is a collection of scripts that solve a lot of strange hibernation problems and bugs (see the man page). They should not be needed any more
systemctl hibernate
is the way you should be hibernating [1]
needs trying
systemd-sleep
apparently a disaster.
Uswsusp
A collection of suspend tools:
s2ram, s2disk, s2both
[5] NB not tried this yet.
swapping
You can create a swap file or use a swap partition. It makes a difference if the file / partition is encrypted or not. It makes a difference if your swap is encrypted or not. a good general article on creating files or partitions NB. apparently for some people the solution is to create a swap file (haven't tried this yet)
swapon -s
will tell you if your swap is running or not.
swap files
edits to enable hibernation
Edit this file: /var/lib/polkit-1/localauthority/50-local.d/com.ubuntu.enable-hibernate.pkla
eg.: sudo gedit /var/lib/polkit-1/localauthority/50-local.d/com.ubuntu.enable-hibernate.pkla
Add this content:
[Re-enable hibernate by default in upower] Identity=unix-user:* Action=org.freedesktop.upower.hibernate ResultActive=yes [Re-enable hibernate by default in logind] Identity=unix-user:* Action=org.freedesktop.login1.hibernate ResultActive=yes
This will add hibernate option in menu. But if you want to hibernate, when LID will close, then execute this (this will enable hibernation when LID is closed):
sudo sed -i 's/#HandleLidSwitch=suspend/HandleLidSwitch=hibernate/g' /etc/systemd/logind.conf
And restart system or execute: sudo systemctl restart systemd-logind.service (https://unix.stackexchange.com/questions/125832/no-hibernate-option-in-power-manager-on-mint-16-mate)
Other files
/sys/power/resume
/sys/power/resume_offset
/sys/power/reserverd_size