0

I am using Manjaro, and out of the box hibernation was not working, so I made some changes to fstab, mkinitcpio and grub and it worked but after sometime it doesn't hibernate and instead locks the screen, even though after a restart it works fine and yes I have made the swap twice the size of my RAM. Please help I couldn't find this exact question anywhere online.

3
  • What are the changes you made to the files that you mention, that made it work?
    – Kusalananda
    Commented Jul 25, 2021 at 10:14
  • In /etc/fstab added: UUID=[UUID_of_the_swap_partition] none swap defaults 0 0 In /etc/default/grub added: resume=UUID=[UUID_of_the_swap_partition] to GRUB_CMDLINE_LINUX In /etc/mkinitcpio.conf added: resume to HOOKS (after udev) sudo mkinitcpio -P && sudo update-grub Commented Jul 27, 2021 at 19:53
  • You may want to add that to the question instead, as a clarification, using the formatting tools provided to make it readable.
    – Kusalananda
    Commented Jul 27, 2021 at 19:55

1 Answer 1

1

How you can fix it...

sudo swapoff -a
sudo /sbin/mkswap /dev/sd##(swap)
sudo swapon -a

In /etc/fstab add:

UUID=[UUID_of_the_swap_partition] none swap defaults 0 0 

In /etc/default/grub add:

resume=UUID=[UUID_of_the_swap_partition] to GRUB_CMDLINE_LINUX 

In /etc/mkinitcpio.conf add:

resume to HOOKS (after udev) sudo mkinitcpio -P && sudo update-grub

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .