Recently, one of my friends had been facing an issue regarding the hibernation in Ubuntu 11.04. He googled all over the internet, found a lot of solutions but none of them worked out for him. Finally, we worked out a solution which I am going to share with you in this article.This article is dedicated to those people who are facing the same issue and never found a solution and for it. Also, I have taken a few lines from wikipedia to just let you know what basically hibernation is and what all are the benefits of hibernation.
Hibernation is a feature of many computer operating systems where the contents of RAM are written to non-volatile storage such as a hard disk, as a file or on a separate partition, before powering off the computer. When the computer is restarted it reloads the content of memory and is restored to the state it was in when hibernation was invoked.
Hibernation is used as an alternative to powering down the computer, because hibernating and later restarting is usually faster than closing down, later starting up, and starting all the programs that were running. Going into hibernation requires no user interaction; shutting down when programs are open either requires programs to be closed properly, or user interaction to force them to close, with possible loss of data or additional work on the part of the user to save all unsaved data in running programs.
This is how it all worked out, I have mentioned it step by step here. You don’t need to be a hard core coder for this, just open the terminal and follow these steps:
Open Terminal and go to root or just login through root
Type- vi /etc/default/grub
You will find the following line:-
Type resume=/dev/my_vg/swap in the double quotes(“ ”), it should be like this:-
GRUB_CMDLINE_LINUX=”resume=/dev/my_vg/swap” and save it.
Now update grub by typing:-
Type – vi /etc/initramfs-tools/conf.d/resume
Edit the following command in that editor:-
resume=/dev/my_vg/swap and save it.
Now update by typing:-
Try hibernating your system and check to find it working.