From kernel/suspend.c: * BIG FAT WARNING ********************************************************* * * If you have unsupported (*) devices using DMA... * ...say goodbye to your data. * * If you touch anything on disk between suspend and resume... * ...kiss your data goodbye. * * If your disk driver does not support suspend... (IDE does) * ...you'd better find out how to get along * without your data. * * If you change kernel command line between suspend and resume... * ...prepare for nasty fsck or worse. * * (*) pm interface support is needed to make it safe. You need to append resume=/dev/your_swap_partition to kernel command line. Then you suspend by echo 4 > /proc/acpi/sleep. Article about goals and implementation of Software Suspend for Linux ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Author: G‚ábor Kuti Last revised: 2003-10-20 by Pavel Machek Idea and goals to achieve Nowadays it is common in several laptops that they have a suspend button. It saves the state of the machine to a filesystem or to a partition and switches to standby mode. Later resuming the machine the saved state is loaded back to ram and the machine can continue its work. It has two real benefits. First we save ourselves the time machine goes down and later boots up, energy costs real high when running from batteries. The other gain is that we don't have to interrupt our programs so processes that are calculating something for a long time shouldn't need to be written interruptible. Using the code You have two ways to use this code. The first one is is with a patched SysVinit (my patch is against 2.76 and available at my home page). You might call 'swsusp' or 'shutdown -z