Bug 432262 - ksmserver sometimes inappropriately inhibits screen locking upon hibernation
Summary: ksmserver sometimes inappropriately inhibits screen locking upon hibernation
Status: RESOLVED WORKSFORME
Alias: None
Product: ksmserver
Classification: Unmaintained
Component: general (show other bugs)
Version: unspecified
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: David Edmundson
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-01-28 19:59 UTC by valdikss
Modified: 2023-01-02 13:44 UTC (History)
5 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
journalctl log (28.07 KB, text/plain)
2021-01-28 19:59 UTC, valdikss
Details

Note You need to log in before you can comment on or make changes to this bug.
Description valdikss 2021-01-28 19:59:52 UTC
Created attachment 135271 [details]
journalctl log

SUMMARY
From time to time, about 1 of 10 hibernation attempts, the screen is not getting locked before hibernation and remain unlocked after hibernation.

In the log (journalctl), I see the following line:

    systemd-logind[1329]: Delay lock is active (UID 1000/valdikss, PID 1888/ksmserver) but inhibitor timeout is reached.

It seems that ksmserver does something so long that logind gives up and skips screen locking.

`systemd-inhibit --list` shows that ksmserver is indeed responsible for screen locking inhibitor:

    Screen Locker  1000 valdikss 1888 ksmserver sleep  Ensuring that the screen gets locked before going to sleep delay

I see no crashes or any other activity which would explain the situation.


STEPS TO REPRODUCE
1. Hibernate the PC
2. Wake up the PC

OBSERVED RESULT
About 1 of 10 times the PC wakes up unlocked

EXPECTED RESULT
The PC wakes up locked all the time


SOFTWARE/OS VERSIONS
Linux/KDE Plasma: Fedora 33
(available in About System)
KDE Plasma Version: Plasma 5.20.5
KDE Frameworks Version: 5.78.0
Qt Version: 5.15.2


ADDITIONAL INFORMATION
The log is in attachment.
Comment 1 valdikss 2021-01-28 20:00:31 UTC
Please move this bug to ksmserver is this is not a kscreenlocker bug.
Comment 2 valdikss 2021-04-29 19:44:12 UTC
Got this again. The delay before suspend was about 5 seconds. Upon wakeup, the laptop was not locked.

>Apr 29 21:08:45 val systemd-logind[1284]: Delay lock is active (UID 1000/valdikss, PID 1813/ksmserver) but inhibitor timeout is reached.
Comment 3 valdikss 2023-01-02 13:44:01 UTC
Can't reproduce on newer KDE versions.