June 23, 2018

Power Saving for the Workstation, Part 1 - page 3

Making It Work

  • July 27, 2007
  • By A. Lizard

The default settings in the BIOS worked, as seen in Figure 1. If ACPI and DPMS aren't enabled by default, enable them. However, the system drastically slowed down when I changed the ACPI Suspend Type to S1&S3, though it didn't appear make a difference with respect to shutting down RAM and CPU or fans. Feel free to experiment, just remember never to change BIOS (or anything else avoidable) when the machine is shut down in hibernation state.

Bad Things happen with respect to corruption of files in use, and these can corrupt your filesystem. (The screen distortion in Figure 2 is from a bad camera angle, but look at the way Konqueror and the bottom panel are split) This happened when I restored the BIOS to its default ACPI settings when in hibernate.

As I said, hibernate -force worked correctly as installed. -force is required because I have nvidia GeForce 6100 video and the inclusion of nvidia in /etc/hibernate/blacklisted-modules seems not to work. Try it without -force first, especially if you aren't running nvidia.

The original hibernate configuration files were set up to point at ram.conf, which was configured to point at uswusp (which I couldn't install). Once I found that it needed to use sysfs-ram.conf (for use with kernel-based SOFTWARE_SUSPEND), I then found it was intended to enable SOFTWARE SUSPEND to point an "mem" ACPI state that didn't exist. Finally, I modified common.conf (configuration data common to both suspend-to-ram and hibernate) to bring eth0 down, then up. Note that this was done by uncommenting existing lines, so I'm not the first to have run into the network problem.

The following steps made it work. The cat command below lists the available ACPI states.

terrarium:/var/log# cat /sys/power/state
standby disk

Create the directory /home/username/suspend.

$ mkdir suspend

These files need to be in the /etc/hibernate directory.


# TryMethod suspend2.conf
TryMethod disk.conf
# TryMethod ram.conf


# save to both, RAM and disk
# (disabled by default, since it takes longer)
# TryMethod ususpend-both.conf
# TryMethod ususpend-ram.conf
TryMethod sysfs-ram.conf


"standby" is from "available ACPI states" above, and use anything but "disk", since this specifically controls suspend-to-RAM. I'd try mem first, suspend second, and standby last, but what each does may be different on your system, if you have more than one non-disk choice, try each and see what saves most power consistent with a correct return from suspend with no data corruption.

UseSysfsPowerState standby


### network
# uncomment the following two lines:
DownInterfaces eth0
UpInterfaces auto

The change in common.conf dealt with the problem of eth0 showing as a running process when it in fact is not running; changing common.conf was convenient and suggests I'm not the first one to have this problem. Change UseSysfsPowerState to whatever matches the /var/state/log output, you should see at least one of these items:

  1. mem
  2. suspend
  3. standby

After making the above changes and entering:

# hibernate-ram --force

my system suspends to RAM, leaving the fans on. On the next keyboard or mouse event, the system resumes correctly, reopening formerly open applications, up to and including a VMware Server with Windows open.

Changing ACPI through this method involving /etc/default/acpi-support: would probably provide similar results.

In Part 2, you will find out how to set your system to work with a monitor that will put your computer into suspend as soon as the OS display power saving feature tells your computer display to go to sleep.

Most Popular LinuxPlanet Stories

We have made updates to our Privacy Policy to reflect the implementation of the General Data Protection Regulation.