You are not logged in.
I noticed that in loginctl there is an option to unlock/lock sessions, and also trigger a lock on ACPI events. On my system, this is not working. I want xscreensaver to actually perform the lock. Any ideas?
Offline
What isn't working? That is, what did you try?
How isn't it working? That is, what happened? What error did you get? What's in the logs/journal?
CLI Paste | How To Ask Questions
Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L
Offline
When I run:
sudo loginctl lock-session 1 (or whatever session id is appropriate)
The command returns, and I get a shell prompt, but absolutely nothing happens. I get the same result whether the corresponding session is graphical or on a virtual terminal. If there is an actual error, I haven't found it. I haven't found any relevant logs in /var/log.
Offline
Something needs to listen to systemd-logind's dbus signals for this to work. xscreensaver doesn't do that. I'm pretty sure the big DEs have a component that does this by now and I have written xss-lock to replace xautolock with something that supports systemd (and X screen saver events) for the more lightweight environment that I use.
xscreensaver does not work with the X screen saver extension and does its own polling so you would not typically use it with xautolock/xss-lock. Maybe you could run xss-lock just to connect logind signals to xscreensaver. That means turning off the idle/inactivity events generated by the X server (if you haven't already done that for xscreensaver):
$ xss-lock -- xscreensaver-command -lock &
$ xset s off
I have not tested this and it may require some more tweaking.
Last edited by Raynman (2013-08-14 11:03:23)
Offline
Finally, an answer as to why this isn't working. This sounds intriguing, and I don't mind a little tweaking, or just ditching xscreensaver entirely. I would try it right now, but it appears that all of the download links on bitbucket required to build the aur package are broken. Is there a way this can be fixed, or do I have to work with the repository directly?
Offline
I can't find anything that needs fixing. The "Sources" link on the AUR page gets me the tarball and rebuilding the package also works. Perhaps it was a temporary issue with bitbucket?
Offline
All working fine now. BitBucket must have been down.
Yes, this appears to be what I was looking for. Thanks. I will now be able to make good use of the laptop's lid switch.
Offline