Post date: 18-Oct-2010 02:39:37
There are reasons for which to resize our swap partition after the OS was installed. Now we are at the point where we have successfully resized our swap partition making it larger or smaller. We have also put the new UUID of the resized partition in /etc/fstab
and the system boots and functions fine with the new swap. However if we hibernate the machine and then we try to thaw (resume from hibernation) something goes wrong. Instead of thawing from the swap partition the OS begins a fresh boot. Always. This is because the kernel looks for a swap to resume from based on a hard-coded UUID value that was not updated when we placed the new UUID in /etc/fstab
. At this point we simply need to update that UUID to the new one and everything will be back to normal. In order to do that we follow these steps:
/etc/initramfs-tools/conf.d/resume
which stores the UUID for thaw:gksudo gedit /etc/initramfs-tools/conf.d/resume
/etc/fstab
). We save and close Gedit.initramfs-tools
:sudo apt-get install --reinstall initramfs-tools
sudo update-initramfs -u -k all
After a reboot our system should be able to successfully thaw from hibernate.