How to Enable Hibernate Option in Linux Mint 20.x

Want to enable the hibernate function in Linux Mint? Here’s the step by step guide for beginners!

Hibernate is a feature to save your work from computer memory into hard drive, and then power-off the machine completely. On next boot, it will revert system status and go directly to where you left it.

Suspend does the same job but saving all the work into RAM memory. So the system is not completely turned off and needs battery or power supply to serve it.

Verify if hibernate works:

Hibernate function does not work in may case in Linux Mint 20 by default. You can test it out by opening “terminal” from start menu, and run command:

systemctl hibernate

NOTE: Save your work before running the command in case hibernate does not work! When your system is shutdown completely, start it again and see if it reverts to where you left it.

Enable Hibernate in Linux Mint 20

If the function does not work for you, do the steps below one by one to enable it.

1.) Check the swap area UUID:

As I mentioned, the hibernate function saves all the work into hard drive. The location is usually the Swap area. To check it out, open “terminal” from start menu and run command:

sudo swapon --show

It usually outputs the partition /dev/sdaX you created while installing the system.

Next run the blkid command should tell you the UUID for this partition.

blkid

Copy the ID and it will be used in next step.

2.) Enable hibernate via kernel parameter:

You can add a kernel parameter to boot menu easily via editing the configuration file. However, a graphical tool will be friendly for beginners.

a.) Search for and install ‘Grub Customizer‘ from Software Manager app. Or open terminal and run command to install the tool:

sudo apt install grub-customizer

b.) Next launch the tool from start menu, and navigate to ‘General Settings’ tab. Finally add following in kernel parameters box after ‘quiet splash’

resume=UUID=the_id_you_got_in_previous_step

Click the top-left “Save” button and restart your computer. And test the hibernate function again via ‘systemctl hibernate‘ command.

Add Hibernate Option in Shutdown menu

The default ‘Quit’ menu options lack hibernate. It is however easy to add back if the function works!

Firstly open terminal from start menu. When it opens, run command to create & edit the configuration file:

sudo xed /etc/polkit-1/localauthority/50-local.d/com.linuxmint.enable-hibernate.pkla

When the file opens, paste following lines and save it!

[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;org.freedesktop.login1.handle-hibernate-key;org.freedesktop.login1;org.freedesktop.login1.hibernate-multiple-sessions;org.freedesktop.login1.hibernate-ignore-inhibit
ResultActive=yes

OK, now open the Shutdown menu and see the magic!

In case for those do not have a swap partition, you can create a swap file instead and use UUID of root partition along with physical offset.

Exit mobile version