You are not logged in.

#1 2018-02-24 11:34:51

TwUxTLi51Nus
Member
Registered: 2017-09-12
Posts: 15

[solved] KDE/sddm cannot switch user

Until recently I could, using KDE menu -> Power / Session -> Switch user switch between different users on my machine. Since some update from a week ago I cannot: When I click on "Switch User" -> "Start New Session", the "old" session keeps reappearing and a new session is not created.

Inspecting the system journal I encountered error messages regarding pam_tally like the ones mentioned here, so I replaced pam_tally with pam_tally2 and /var/log/faillog with /var/log/tallylog.

This made the error messages in the system journal disappear, but did not solve the problem however. Recording what happens in the system log when I try to switch users, the following log entries appear:

Feb 24 12:16:15 <hostname> plasmashell[11610]: trying to show an empty dialog
Feb 24 12:16:19 <hostname> ksmserver[11589]: lock called
Feb 24 12:16:19 <hostname> ksmserver[11589]: Lock window Id:  20971539
Feb 24 12:16:19 <hostname> ksmserver[11589]: CreateNotify: 20971539
Feb 24 12:16:19 <hostname> ksmserver[11589]: CreateNotify: 115343363
Feb 24 12:16:19 <hostname> ksmserver[11589]: CreateNotify: 115343367
Feb 24 12:16:19 <hostname> ksmserver[11589]: CreateNotify: 115343375
Feb 24 12:16:19 <hostname> ksmserver[11589]: CreateNotify: 115343380
Feb 24 12:16:19 <hostname> ksmserver[11589]: CreateNotify: 115343382
Feb 24 12:16:19 <hostname> ksmserver[11589]: CreateNotify: 115343384
Feb 24 12:16:19 <hostname> ksmserver[11589]: MapNotify: 115343382
Feb 24 12:16:19 <hostname> ksmserver[11589]: CreateNotify: 115343386
Feb 24 12:16:19 <hostname> ksmserver[11589]: MapNotify: 20971539
Feb 24 12:16:19 <hostname> ksmserver[11589]: UnmapNotify: 113246221
Feb 24 12:16:19 <hostname> ksmserver[11589]: UnmapNotify: 113246221
Feb 24 12:16:19 <hostname> ksmserver[11589]: CreateNotify: 115343394
Feb 24 12:16:19 <hostname> plasmashell[11610]: QXcbClipboard: SelectionRequest too old
Feb 24 12:16:19 <hostname> ksmserver[11589]: CreateNotify: 113246240
Feb 24 12:16:19 <hostname> kwin_x11[11606]: QXcbConnection: XCB error: 3 (BadWindow), sequence: 39168, resource id: 113246240, major code: 18 (ChangeProperty), minor code: 0
Feb 24 12:16:19 <hostname> plasmashell[11610]: QXcbClipboard: SelectionRequest too old
Feb 24 12:16:19 <hostname> plasmashell[11610]: QXcbClipboard: SelectionRequest too old
Feb 24 12:16:28 <hostname> ksmserver[11589]: UnmapNotify: 115343382
Feb 24 12:16:28 <hostname> ksmserver[11589]: UnmapNotify: 115343382
Feb 24 12:16:28 <hostname> ksmserver[11589]: CreateNotify: 115343405
Feb 24 12:16:28 <hostname> kwin_x11[11606]: QXcbConnection: XCB error: 3 (BadWindow), sequence: 41623, resource id: 115343405, major code: 18 (ChangeProperty), minor code: 0

Any ideas / pointers where to look? Thanks!

Last edited by TwUxTLi51Nus (2018-03-02 21:19:01)

Offline

#2 2018-02-26 13:09:35

TwUxTLi51Nus
Member
Registered: 2017-09-12
Posts: 15

Re: [solved] KDE/sddm cannot switch user

Just found this, which looks similar, although it is for an earlier version of KDE/Plasma.

Offline

#3 2018-03-02 15:33:19

lianse
Member
Registered: 2014-03-22
Posts: 5

Re: [solved] KDE/sddm cannot switch user

I'v got the same problem since updating to Plasma 5.12. Although it worked once in about 15 reboots since then. So I started digging around to find the cause of this.
Googling around gave me the right hint: https://forum.manjaro.org/t/kde-cant-sw … d/40737/10 That's exactly what happens on my system, sddm starts with a journald log message "No session manager found" which results in the user switching not working.
According the the source code of sddm (LoginDBusTypes.cpp), it could'n find a the org.freedesktop.login1 service on system dbus, which is strange, as QDBusViewer show's me it is there.
So it seems to be a order/timing problem

Offline

#4 2018-03-02 16:17:41

lianse
Member
Registered: 2014-03-22
Posts: 5

Re: [solved] KDE/sddm cannot switch user

I've added the following snipped,

[Unit]
After=systemd-logind.service

to the sddm service unit by

systemctl edit sddm

which brought back the functionality (n=10 reboots).

Offline

#5 2018-03-02 21:18:21

TwUxTLi51Nus
Member
Registered: 2017-09-12
Posts: 15

Re: [solved] KDE/sddm cannot switch user

Thank you so much! That did solve it for me too, although there were no messages regarding "No session manager found" in my systemd logs.

Offline

#6 2018-03-03 05:59:09

lianse
Member
Registered: 2014-03-22
Posts: 5

Re: [solved] KDE/sddm cannot switch user

Sure with your log messages?

Try this command (you can change the log date according to your needs)

journalctl --system --since 2018-02-01 -u sddm -u systemd-logind

and watch for

-- Reboot --

marks.

Faulty starts should have the wrong order like

Feb 10 09:42:22 apc01 systemd[1]: Starting Login Service...
Feb 10 09:42:22 apc01 systemd[1]: Started Simple Desktop Display Manager.
...
Feb 10 09:42:22 apc01 sddm[484]: Initializing...
Feb 10 09:42:22 apc01 sddm[484]: No session manager found
...
Feb 10 09:42:22 apc01 systemd[1]: Started Login Service.

whereas a good order looks like this

Mär 02 17:08:50 apc01 systemd[1]: Starting Login Service...
...
Mär 02 17:08:50 apc01 systemd[1]: Started Login Service.
Mär 02 17:08:50 apc01 systemd[1]: Started Simple Desktop Display Manager.
Mär 02 17:08:51 apc01 sddm[501]: Initializing...
Mär 02 17:08:51 apc01 sddm[501]: Logind interface found
...

Offline

#7 2018-03-03 06:06:12

lianse
Member
Registered: 2014-03-22
Posts: 5

Re: [solved] KDE/sddm cannot switch user

And it has been fixed uptream by commit fca8c80: Fix race between sddm and logind because it caused another bug (poweroff/reboot not working) too.

So, when the next version of sddm is released it should be save to delete /etc/systemd/system/sddm.service.d/override.conf

Last edited by lianse (2018-03-03 06:06:31)

Offline

#8 2018-03-07 20:07:01

TwUxTLi51Nus
Member
Registered: 2017-09-12
Posts: 15

Re: [solved] KDE/sddm cannot switch user

You are right, sorry. I disabled the "override" and there indeed is the "no session manager found" log entry. I also checked earlier boots and found the message. Somehow they must have escaped my sight sad

Anyway, THX so much for providing the solution!

Offline

Board footer

Powered by FluxBB