Sample Header Ad - 728x90

Trying to use xautolock to suspend activity after a certain amount of time

4 votes
1 answer
1948 views
I'm using manjaro (5.8.18-1-MANJARO) and the i3 window manager. I'm trying to lock the screen then suspend activity after given amounts of idle time. I've found that xautolock should suit my needs using both the -locker and -killer flags. My i3 config contains the following :
--no-startup-id xautolock -time 5 -locker blurlock -notify 15 -notifier "notify-send 'Screen will lock in 15 s'" -detectsleep -killtime 60 -killer "systemctl suspend"
However, this doesn't seem to work: 1) The locker part works fine, but system doesn't suspend after 60 minutes. 2) If I suspend the system manually (I'm using a modified version of the i3exit script, the executed command is xautolock -locknow && systemctl suspend), then the system suspends *again* shortly after i resumed it. This behavior started very recently, I think after a system update, and I don't think I've changed anything else than the i3exit myself in system settings / config. I don't know what could be putting the system to sleep again since I don't have any power-manager activated to my knowledge. Thanks for your help !
Asked by Raphaël Ventura (55 rep)
Dec 3, 2020, 10:12 AM
Last activity: Feb 4, 2021, 08:47 PM