0

I have Ubuntu 18.04 (Kerel: 5.0.0-27-generic) on my Dell XPS 15 (9570). I discovered that closing the lid puts the laptop into sleep correctly only works the first time I it. Closing the lid a second time (on on boot) does not put the laptop so sleep anymore. Rebooting resets the behavior.

sudo journalctl | grep "PM: suspend" | tail -2
Sep 06 23:35:56 XPS kernel: PM: suspend entry (deep)
Sep 06 23:36:25 XPS kernel: PM: suspend exit
cat /etc/systemd/logind.conf
[Login]
#NAutoVTs=6
#ReserveVT=6
#KillUserProcesses=no
#KillOnlyUsers=
#KillExcludeUsers=root
#InhibitDelayMaxSec=5
#HandlePowerKey=poweroff
HandleSuspendKey=suspend
#HandleHibernateKey=hibernate
HandleLidSwitch=suspend
#HandleLidSwitchDocked=ignore
#PowerKeyIgnoreInhibited=no
#SuspendKeyIgnoreInhibited=no
#HibernateKeyIgnoreInhibited=no
#LidSwitchIgnoreInhibited=yes
#HoldoffTimeoutSec=30s
#IdleAction=ignore
#IdleActionSec=30min
#RuntimeDirectorySize=10%
#RemoveIPC=yes
#InhibitorsMax=8192
#SessionsMax=8192
#UserTasksMax=33%

I used the xps-tweaks.sh script for the laptop.

How to ensure that closing the lid always put the device into sleep mode?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.