> Yes it's a wrapper, but it's a needed one, it'll especially filter stuff in > the environment. It would help to show the logind session before and after > restart. I seem to remember that when you restart like that, the lightdm > process will inherit the console session or something like that, and it'll > mess up the permissions. > > Try, on a fresh start: > > loginctl > service lightdm restart > loginctl > > and again report back.
Sure, here it is: ---------8<---console ------------------ ### ssh prompt after fresh boot # loginctl SESSION UID USER SEAT c1 142 lightdm seat0 2 0 root 2 sessions listed. # loginctl show-session c1 Id=c1 Name=lightdm Timestamp=Sa 2015-12-05 17:39:23 CET TimestampMonotonic=25179163 VTNr=7 Display=:0 Remote=no Service=lightdm-greeter Scope=session-c1.scope Leader=6205 Audit=0 Type=x11 Class=greeter Active=yes State=active IdleHint=no IdleSinceHint=0 IdleSinceHintMonotonic=0 # service lightdm restart [ ok ] Stopping Light Display Manager: lightdm. [ ok ] Starting Light Display Manager: lightdm. # loginctl SESSION UID USER SEAT 2 0 root ---------8<---end console -------------- I think you're on to something: after this, I logged in to lightdm (sure enough, a broken session again) and noticed, that there's no new session, but it "inherited" the session from the ssh login: ---------8<---console ------------------ $ echo $XDG_SESSION_ID 2 ---------8<---end console -------------- And, just for the sake of completeness, the data for the ssh-prompt: ---------8<---console ------------------ # loginctl show-session 2 Id=2 Name=root Timestamp=Sa 2015-12-05 17:39:50 CET TimestampMonotonic=51388061 VTNr=0 Remote=yes RemoteHost=enterprise.startrek.nachtgeist.net Service=sshd Scope=session-2.scope Leader=6806 Audit=2 Type=tty Class=user Active=yes State=active IdleHint=no IdleSinceHint=0 IdleSinceHintMonotonic=0 ---------8<---end console -------------- Up until now I thought, lightdm failed to correctly register a user-session, when really it failed to register one at all... Daniel