I've enabled the hibernate option and have successfully used it multiple times before, but for some reason when I tried it a few minutes ago, it only locked the computer. Running sudo pm-hibernate
seemed to do literally nothing--it asked for my password, then returned to the prompt immediately after I entered it. I think this has happened before, but I don't remember what I did to fix it (if I really did anything). I need to boot Windows, but I've got stuff open and really don't want to do a full reboot. What's going on, and how could I fix this?

- 809
2 Answers
One of the most common reasons of hibernate not working even after enabling by using the method xchamitha mentioned is either a missing swap partition or a missing entry for the swap partition in your /etc/fstab
file. This can happen if you ever modified your swap partition by deleting, extending, recreating it. Even if you haven't, verify.
Check if you have the correct entry in your /etc/fstab
by opening a terminal(Ctrl+Alt+t) and then type:
sudo blkid
this will give you an output such this(this is mine, your's will have different number of partitions with different UUID's):
/dev/sda1: UUID="E8EE-D6B7" TYPE="vfat"
/dev/sda2: LABEL="Windows and Components" UUID="CAE8DFDDE8DFC63B" TYPE="ntfs"
/dev/sda4: LABEL="Peripherals and Support" UUID="01CEB0A39FEAB500" TYPE="ntfs"
/dev/sda5: UUID="dcce3bed-77bd-497a-af91-6de6a1a68617" TYPE="ext4"
/dev/sda6: UUID="85b5c13d-93ed-487b-a4b2-9004a1fd27b0" TYPE="ext4"
/dev/sda7: UUID="7301ea57-3526-4336-b541-1e8a0422e402" TYPE="ext4"
/dev/sda8: UUID="b23adddf-2164-46ab-aa3a-bd8d83158d22" TYPE="swap"
the last entry is of the swap partition. Note the UUID of the swap partition(it is b23adddf-2164-46ab-aa3a-bd8d83158d22
for mine). If you don't have such a line, you don't have a swap partition and you will need to create one using either the GUI method or the command-line method.
Next, check if there is a line in your /etc/fstab
file similar to this:
UUID=b23adddf-2164-46ab-aa3a-bd8d83158d22 none swap sw 0 0
This line tells the kernel to mount the swap partition on boot, which is important for hibernation to be available. The entries here are separated by space(s)(the number of spaces does not matter, you should have at least one space between two entries).
Once you have completed this, reboot your machine and you should have an entry to hibernate.
-
Did exactly that but still can't hibernate. I increased my swap size, added the new UUID into the /etc/fstab but still can't hibernate. – Jan 28 '14 at 14:46
-
@user240955: What do you get when you type
sudo pm-hibernate
on a terminal? – jobin Jan 28 '14 at 17:09
Try following, this blogpost on how to enable hibernate in ubuntu 13.04. http://xchamitha.blogspot.co.uk/2013/07/enabling-hybernate-in-ubuntu-1304.html.
To summarise:
Enabling Hybernate in Ubuntu 13.04
Open a terminal CTRL+ALT+T and type,
sudo gedit /var/lib/polkit-1/localauthority/50-local.d/hibernate.pkla
Paste the following and save the file.
[Re-enable Hibernate]
Identity=unix-user:*
Action=org.freedesktop.upower.hibernate
ResultActive=yes
Reboot your computer.

- 22,112
- 28
- 68
- 88
-
http://askubuntu.com/questions/94754/how-to-enable-hibernation#comment430252_94963 – Bleeding Fingers Aug 26 '13 at 17:17
sudo pm-hibernate
has always worked. "Enabling" hibernate just put a button for it in Unity's menu. All I've done recently is install whatever updates the update manager finds. – Zelda64fan Jul 07 '13 at 20:21