You are not logged in.
After some updates and a reboot, when I have an external monitor connected (not necessarily active), "suspend" doesn't work anymore when closing the laptop lid. I didn't change any configuration.
What I've checked and found so far doesn't help me yet, but it may help people with some knowledge on this topic.
There seem to be two ways, one is to have "logind" handle your suspend, the other ...dunno.
$ xfconf-query -c xfce4-power-manager -lv
[...]
/xfce4-power-manager/lid-action-on-ac 1
/xfce4-power-manager/lid-action-on-battery 1
/xfce4-power-manager/logind-handle-lid-switch false
[...]$ xfce4-power-manager -q && xfce4-power-manager --no-daemon --debug
...
TRACE[xfpm-manager.c:333] xfpm_manager_lid_changed_cb(): LID closed: ((XfpmLidTriggerAction) LID_TRIGGER_SUSPEND)
TRACE[xfpm-manager.c:339] xfpm_manager_lid_changed_cb(): Ignoring lid closed event: external monitor connected
TRACE[xfpm-manager.c:333] xfpm_manager_lid_changed_cb(): LID opened: ((XfpmLidTriggerAction) LID_TRIGGER_SUSPEND)
...$ cat /etc/UPower/UPower.conf
[...]
IgnoreLid=false
[...]$ cat /etc/systemd/logind.conf | grep Lid
#HandleLidSwitch=suspend
#HandleLidSwitchExternalPower=suspend
#HandleLidSwitchDocked=ignore
#LidSwitchIgnoreInhibited=yes$ systemd-inhibit --list
WHO UID USER PID COMM WHAT WHY MODE
NetworkManager 0 root 1806 NetworkManager sleep NetworkManager needs to turn off networks delay
UPower 0 root 2535 upowerd sleep Pause device polling delay
code 1000 sn 105967 code sleep Application cleanup before suspend delay
xfce4-screensaver 1000 sn 2737 xfce4-screensav sleep Locking screen before sleep delaySo it seems the suspend is not handled by "logind", and "systemd" does not list anything to inhibit suspend if there's an external monitor attached.
Last edited by starch2021 (2025-03-21 09:24:11)
Offline
Same as https://bbs.archlinux.org/viewtopic.php?id=303157 I think.
Xfce dev: https://gravatar.com/gaelbonithon
Offline
thanks, yes, that looks very much like the same issue...."laptop lid suspend" in the search doesn't yield this thread.
So seems there's no solution as of now.
And if I suspend explicitly via menu or command that works, but then if I close the lid the laptop wakes up again.
So currently I have to unplug the dock (switching off the external monitor isn't enough) and close the lid.
Or if I want it to be connected, suspend via menu and leave display open.
Offline
I've used the solution that came up in the other thread:
as user:
xfconf-query -c xfce4-power-manager -p /xfce4-power-manager/logind-handle-lid-switch -t bool -s true --createAnd as root:
- in "/etc/systemd/logind.conf" set
HandleLidSwitchDocked=suspendthen reload:
systemctl reload systemd-logindNow my laptop suspends again when closing the lid.
Offline