This forum has been archived. All content is frozen. Please use KDE Discuss instead.

Shutdown/restart/logout no longer working

Tags: None
(comma "," separated)
franku
Registered Member
Posts
33
Karma
0
OS
luebking wrote:Did we determine whether it could be a hidden window that inibits logout?
see https://git.reviewboard.kde.org/r/115955/

I test this but shutdownbuttons do work as expected.

I use allways the option "restore last session" in systemsettings... But after my last post here, the next boot was strange because no application starts automatically. No Kontact (but akonadi runs), no klipper, no Konsole-window nothing. The process-list shows the curious rows again:
Code: Select all
$ ps axjf                                                                                                                                               
 PPID   PID  PGID   SID TTY      TPGID STAT   UID   TIME COMMAND                                                                                                                   
[...]
  430   493   429   429 ?           -1 Sl    1000   0:00  \_ /usr/bin/akonadi_agent_launcher akonadi_vcard_resource akonadi_vcard_resource_0
    1   542   542   542 ?           -1 Ss    1000   0:00 kdeinit4: kdeinit4 Runnin e
  542   545   542   542 ?           -1 S     1000   0:00  \_ kdeinit4: klauncher [kdei e
[...]
    1  1230   542   542 ?           -1 Sl    1000   0:00 /usr/bin/knotify4
    1  1240   542   542 ?           -1 Rl    1000   0:11 kdeinit4: konsole [kdeini e
 1240  1242  1242  1242 pts/0     3455 Ss    1000   0:00  \_ /bin/bash
 1242  3455  3455  1242 pts/0     3455 R+    1000   0:00      \_ ps axjf

So i investigate the process 542:
Code: Select all
$ cat /proc/542/cmdline
kdeinit4: kdeinit4 Runnine

The malformed lines comes from here. If i run "cat /proc/542/status" the output seems to be ok. "ok" with the meaning of "no misbehaved lines".

All new processes becomes those malformed lines in the processlist. Then i tryed to kill all those processes. They could all be killed, except kwalletd, which starts automatically again with this malformed command. In the end i killed all(?) kde-related processes, plasma shuts down and the loginmanager (kdm) appears. I could login and the desktop starts as if nothing happend before: All applications and windows starts, all is ok.

This shows, that this failure only belongs to the start of kde, not to something wrong about the hardware or the kernel.

As often, some ideas comes to me, if the failure went away, so i have to wait till the next time to investigate further. One of the last idea is: Could it be, that the "kdeinit4" process runs twice? As i remember of the processlist yesterday, there are more than one kdeinit4-processes and all processes which runs below the second one, have those malformed commandlines. If i look in the processlist when all is ok, there is only one kdeinit4-process.
User avatar
vayu
Registered Member
Posts
129
Karma
0
OS
franku wrote:It would be great, if vayu could answer some questions:
1. Persists the problem between boots?
2. What is the output from
Code: Select all
dbus-send --print-reply --dest=org.kde.ksmserver /KSMServer org.kde.KSMServerInterface.logout int32:0 int32:2 int32:2

3. is the polkitdaemon running and is "polkit-kde-authetication-agent-1" loaded?


Yes, I would love to solve this. Sorry for being gone so long, I didn't realize this thread had activity.

Yes this problem persists between boots. The only way I know to shutdown is shutdown -h now.
Here's the output of some commands in this thread:

Code: Select all
$ dbus-send --print-reply --dest=org.kde.ksmserver /KSMServer org.kde.KSMServerInterface.logout int32:0 int32:2 int32:2

method return sender=:1.10 -> dest=:1.101 reply_serial=2

Code: Select all
$ kdmctl caps   

ok kdm list local activate shutdown shutdown ask nuke reserve 3 lock suicide

Code: Select all
$ qdbus org.kde.ksmserver /KSMServer                                                                                   

method bool org.kde.KSMServerInterface.canShutdown()
method QString org.kde.KSMServerInterface.currentSession()
method void org.kde.KSMServerInterface.logout(int, int, int)
method void org.kde.KSMServerInterface.restoreSubSession(QString)
method void org.kde.KSMServerInterface.resumeStartup(QString)
method void org.kde.KSMServerInterface.saveCurrentSession()
method void org.kde.KSMServerInterface.saveCurrentSessionAs(QString)
method void org.kde.KSMServerInterface.saveSubSession(QString, QStringList, QStringList)
method QStringList org.kde.KSMServerInterface.sessionList()
signal void org.kde.KSMServerInterface.subSessionCloseCanceled()
signal void org.kde.KSMServerInterface.subSessionClosed()
signal void org.kde.KSMServerInterface.subSessionOpened()
method void org.kde.KSMServerInterface.suspendStartup(QString)
method void org.kde.KSMServerInterface.wmChanged()
method QDBusVariant org.freedesktop.DBus.Properties.Get(QString interface_name, QString property_name)
method QVariantMap org.freedesktop.DBus.Properties.GetAll(QString interface_name)
method void org.freedesktop.DBus.Properties.Set(QString interface_name, QString property_name, QDBusVariant value)
method QString org.freedesktop.DBus.Introspectable.Introspect()
method QString org.freedesktop.DBus.Peer.GetMachineId()
method void org.freedesktop.DBus.Peer.Ping()

Code: Select all
$ ps aux | grep -i polkit

root 3941 0.0 0.0 270332 4836 ? Sl 07:29 0:00 /usr/lib/policykit-1/polkitd --no-debug


I don't know how to check polkit-kde-authetication-agent-1, shouldn't it have shown in my ps and grep above?
franku
Registered Member
Posts
33
Karma
0
OS
vayu wrote:I don't know how to check polkit-kde-authetication-agent-1, shouldn't it have shown in my ps and grep above?

Yes. But as bcooksley say:
bcooksley wrote:Polkit has no involvement in logout/shutdown/restart - that indication of it going down is likely the agent exiting as part of the logout process, or because it crashed.


Do you have such malformed, snippt, lines in the process-tree too? If not, my problem is maybe different from yours.

After the last update i do not have problems with the buttons or shortcut (STRG+ALT+ENTF) anymore.
Code: Select all
$ kwin --version
QDBusConnection: session D-Bus connection created before QCoreApplication. Application may misbehave.
Qt: 4.8.6
KDE: 4.13.0
KWin: 4.11.9
User avatar
mjobin
Registered Member
Posts
40
Karma
0
OS
this is a long time issue, I have been having for a long time...
it usually happens to me after a KDE software upgrade...
like the dbus signal is no longer finding where to send the info...

desktop remains usable, but I can't logout via the usual way. only hard reset, shutdown, reboot commands will work.

I tried

qdbus-qt5 org.kde.ksmserver /KSMServer logout 0 0 0
qdbus-qt5 org.kde.ksmserver /KSMServer logout 0 2 2

$ dbus-send --print-reply --dest=org.kde.ksmserver /KSMServer org.kde.KSMServerInterface.logout int32:0 int32:2 int32:2
method return time=1459264620.658354 sender=:1.2217 -> destination=:1.3054 serial=1192 reply_serial=2

it's acting very much like nothing is happening

I would prefer not to hard reboot.
the other not-so-soft but softer solution I use is "service restart kdm" in the old days
now
"systemctl restart sddm"

but I still feel my KDE session is not being closed nicely.

thanks
User avatar
mjobin
Registered Member
Posts
40
Karma
0
OS
I just upgraded to 5.6.0

thank you


Bookmarks



Who is online

Registered users: Bing [Bot], Google [Bot], Sogou [Bot]