I'm using Xubuntu 14.04 64 bit. I know that question been asked a billion times, but all of them consist of editing following file:

/etc/polkit-1/localauthority/50-local.d/com.ubuntu.enable-hibernate.pkla

That file does not exist on my system. I tried com.xubuntu.enable-hibernate.pkla but doesn't exist either, locate command doesn't find it.

share|improve this question
2  
Where did you read this file must be exist? I've created it, put the commands into and hibernate works fine on Xubuntu. To do that, use your favorite text editor to create /etc/polkit-1/localauthority/50-local.d/com.ubuntu.enable-hi‌​bernate.pkla. Add the following to the file and save:... help.ubuntu.com – TuKsn May 7 '14 at 20:47
    
@Simptnon but that file contains a billion other lines than the hibernate, anyway I found it, but weirdly, locate didn't if it wasn't for mitch i would never find it – Lynob May 7 '14 at 22:42
up vote 27 down vote accepted

Just press Ctrl+Alt+T on your keyboard to open Terminal. When it opens, run the command(s) below:

sudo nano /var/lib/polkit-1/localauthority/10-vendor.d/com.ubuntu.desktop.pkla

Look for

[Disable hibernate by default in upower]
[Disable hibernate by default in logind]

Change the value of "ResultActive=no" to "ResultActive=yes" in both, and then restart your system.

Edit

Just tried this on Xubuntu 16.04, and Ubuntu 16.04. and it also works.

enter image description here

For Ubuntu 16.04 I had to reboot for it to work.

enter image description here

enter image description here

share|improve this answer
2  
two questions why locate com.ubuntu.desktop.pkla does not find it? and why is hibernate disabled by default? – Lynob May 7 '14 at 22:40
1  
As far as the first one, use sudo locate com.ubuntu.desktop.pkla, and it will find it. As for the second one I really don't know for sure, but it might be a bug. – Mitch May 8 '14 at 5:22
1  
why using sudo? I used to search for files in /etc and var without using sudo – Lynob May 8 '14 at 6:04
1  
If you look at the folder the file is in, its owned by root. I tried it, and it works with sudo. – Mitch May 8 '14 at 6:07
1  
If you look at the polkit-1 folder, you will see an X on the folder, which means that you are neither the owner nor in the group that has permissions to read/write/execute to that particular folder/file. Where as /etc does not. – Mitch May 8 '14 at 6:22

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.