SYS-NET shutdowns when LID CLOSED

Thinkpad X1 Gen 12
Qubes r4.3
Kernal - 6.17.9.1-fc41

Problem:

In power manager, when laptop lid is closed the setting is lock screen only.

When I close the laptop lid and open it back up sys-net has completely shutdown (all other qubes are running) and I have to manually start it again.

If I lock the screen manually and do NOT close laptop lid, sys-net is fine.

Power Manager Settings
When Laptop Lid is Closed = Lock Screen (Battery + Plugged In Profile)
Also tried
When Laptop Lid is Closed = Blank Screen (Battery + Plugged In Profile)

These events have always been pain in the ass no matter what DE or OS you use, even Windows suffers from this from time to time. Here’s how you can approach it:

  1. This will tell Xfce’s power manager you want the lid event to be handled by logind:
xfconf-query -c xfce4-power-manager -p /xfce4-power-manager/logind-handle-lid-switch -t bool -s true --create
  1. Edit /etc/systemd/logind.conf and add these:
HandleLidSwitch=ignore
HandleLidSwitchExternalPower=ignore
  1. Then reload the daemon:
sudo systemctl daemon-reload

If you want to debug further before making the changes above, you can try running xfce4-power-manager with –debug flag or query the journal:

xfce4-power-manager --quit
xfce4-power-manager --no-daemon --debug
journalctl | grep -iE ‘lid|suspend|s2idle|sleep’

Here is a rather recent topic on Arch forum: XFCE: Suspend laptop when closed even with display connected / Laptop Issues / Arch Linux Forums

1 Like

@brain_frog you make the internet a better place thank you angel frog

1 Like