You are not logged in.

#1 2020-08-17 04:48:41

ender4
Member
Registered: 2011-01-11
Posts: 16

Resuming from suspend takes multiple tries

Sometimes after suspending my computer it takes multiple attempts to resume. That is, I'll press the power button to wake it up, and it will start to resume, then immediately go back to sleep. If I keep trying, it will eventually come back up, but it usually doesn't work on the first try.

The only thing I can think of that would cause this is maybe as soon as it resumes logind thinks it has been idle since before the suspend, so triggers the IdleAction. However, I don't know how to verify if that is in fact the problem, or how to remedy it, if it is.

Possibly relevant information:

/etc/systemd/logind.conf.d/01-power.conf:

[Login]
IdleAction=suspend
IdleActionSec=10min

wayland compositor: sway 1.5

swayidle command:

swayidle timeout 120 swaymsg output * dpms off resume swaymsg output * dpms on idlehint 30

Offline

#2 2020-09-17 19:48:25

ezacaria
Member
Registered: 2007-12-10
Posts: 113

Re: Resuming from suspend takes multiple tries

This is just a guess, but perhaps a jump (or more than one) in the clock while resuming could trigger this. The absolute time in the journal or dmesg entries could show the discontinuities.

A simple way to test your hypothesis would be to disable the "sleep when idle" and rely on putting the laptop to sleep explicitly instead. I would observe the system behaviour for a while and see if it happens again.

Offline

Board footer

Powered by FluxBB