Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How can Fedora 17 (LXDE spin, if it matters) be configured to sleep or suspend when the lid of a laptop (Lenovo S10 netbook) is closed? With a 'stock' installation (from the LXDE spin live CD), closing the lid doesn't seem to change the machine's state at all (fan still cycles, front LEDs don't change state, uptime unaffected), and when the lid is reopened the keyboard is hot... Thanks!

share|improve this question

migrated from Nov 18 '12 at 4:14

This question came from our site for system and network administrators.

Fedora is a distro with one of the most solid documentation projects. Some of it is mundane and GUI oriented, but there is a lot of valuable information if only you look in the right place. I cannot imagine that the documentation has deteriorated since the days of redhat (when I was looking at those docs). – Ярослав Рахматуллин Nov 18 '12 at 10:37

You may want to read the whole power management guide, but the section about acpid is exactly what you are looking for. On my system I have:

# cat /etc/acpi/events/lid
event=button[ /]lid
action=/etc/acpi/actions/ %e

# cat /etc/acpi/actions/

#mute alsa.
#amixer sset PCM 0

#echo $*

dec=`echo ibase=16\; ${4^^}|bc`

if [ $(($dec % 2 )) -eq 1 ]
        logger "lid down"
        logger "lid up"

If I wanted to suspend, I'd call hibernate-ram (tuxonice) instead of logging "lid down". I think the same thing can be done in Fedora with the pm-suspend command. If you find that this command does nothing, then it's likely a driver issue. You will have to research how to properly configure ACPI on that laptop.

share|improve this answer

You must log in to answer this question.