Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I recently upgraded from 11.04 to 11.10, but I get "Not enough free swap" error when trying to put my laptop to hibernation.

I have 2GB of physical memory and 3GB of swap. Besides, the hibernate worked fine in 11.04.

And the memoinfo is here:

SwapCached:            0 kB
SwapTotal:       4028604 kB
SwapFree:        4028604 kB

So what might be the problem?

share|improve this question
    
which program tells you that error? please paste the meminfo output as I showed in my answer. –  cweiske Oct 30 '11 at 16:45
    
Are you still looking for help or did you find an answer to your question? If you found an answer please consider adding it here. Thanks :) –  coversnail Apr 5 '12 at 15:12
add comment

4 Answers 4

I think you should increase your SWAP size. Try with double what you have now. To change your swap size you need to boot from a live-cd. and change the swap partition, I suggest you do it with gparted.

  • sudo apt-get install gparted

Now just find your SWAP partition and change it to the size you want, I suggest 5GB or more.

Sources:

share|improve this answer
add comment

See this topic is old sorry but not clear for new people who ask the question . The answer is already given . Use Ubuntu Documentation to clarify the answer .

ubuntu.com/community/SwapFaq

share|improve this answer
    
Whilst this may theoretically answer the question, it would be preferable to include the essential parts of the answer here, and provide the link for reference. Imagine the linked site goes down for maintenance or forever - your answer would become worthless. –  hexafraction Aug 2 '12 at 12:28
add comment

make your swap drive 2x as big as your physical memory. that seems to be the rule of thumb

share|improve this answer
    
So what should I do to handle my situation ? –  Spirit Zhang Dec 20 '11 at 13:41
    
Double the size of your swap size. –  Alvar Sep 16 '12 at 17:08
add comment

Check your swap status:

$ cat /proc/meminfo |grep Swap
SwapCached:       216692 kB
SwapTotal:       5855624 kB
SwapFree:        5162340 kB

You will see how much swap is free for you to hibernate. Probably you've got too many applications running that take too much RAM.

share|improve this answer
    
Thanks for the reply. I checked swap before hibernate and I'm sure there's more than enough for the whole RAM to live in the swap, but the problem remains. –  Spirit Zhang Oct 30 '11 at 8:31
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.