HOWTO: Enable Hibernation in Kubuntu 20.04

One of the little annoyances of the Buntus is they don’t have hibernation enabled by default; you have to set it up yourself. This entails a few extra steps, fortunately these are fairly straightforward.

  1. Find the UUID of the swap partition with this command:
  2. edit the grub settings files /etc/default/grub and find the following line:
    on the end of that line add the following text
    where <UUID> is from the result of the command in step 1
  3. run update-grub to update the grub configuration with the new setting
  4. In a root shell type nano /etc/polkit-1/localauthority/50-local.d/com.ubuntu.enable-hibernate.pkla and enter all the text below

[Re-enable hibernate by default in upower]

[Re-enable hibernate by default in logind]


After you reboot, hibernation should work correctly.

There is an interesting possibility implicit that a specific partition can be set aside just for the hibernation. So far I haven’t tried this, but it would look attractive in cases where the swap space is all used up by applications, as the system will not hibernate in these instances.