This page looks best with JavaScript enabled

Changing lid close action on GNU/Linux (systemd)

 ·  ☕ 1 min read

All changes will be performed in /etc/systemd/logind.conf configuration file.

  1. Open configuration file in preferred editor:
    sudo nano /etc/systemd/logind.conf
  2. Uncomment and change HandleLidSwitch* actions according your needs:
    • HandleLidSwitch=poweroff - shutdown when lid is closed.
    • HandleLidSwitch=hibernate - hibernate when lid is closed.
    • HandleLidSwitch=ignore - do nothing.
    • HandleLidSwitch=suspend - suspend when lid is closed.
What's on this Page