Not enough free swap space to hibernate

Matthew Flaschen matthew.flaschen at gatech.edu
Wed Mar 25 12:29:53 UTC 2009


Vincent Arnoux wrote:
> Hello the list,
> I have 1 GB or RAM and 1 GB of swap.

Well, that's your problem.  2 GB is typically recommended for 1 GB
physical memory.  That's what I have, and it works fine.
> During hibernation, RAM is being written to swap partition. If there
> is not enough space, suspend to disk just fails. How can I force my
> swap to be emptied?

I believe you can do:

swapoff swaplocation

swaplocation can be either a partition or a file.  I haven't verified,
but this should free the entire partition for hibernating.  Of course,
if you don't have enough physical memory, swapoff can trigger the out of
memory killer, which will cause (seemingly) random processes to die.

Matt Flaschen




More information about the ubuntu-users mailing list