Terminate KDE session from command line

Kevin Krammer kevin.krammer at gmx.at
Mon Nov 6 20:15:07 GMT 2006

On Monday 06 November 2006 18:06, kitts wrote:
> On Monday 06 November 2006 21:20 IST, Boyan Tabakov wrote:
> > What is the propper way to terminate the kde session, running on specific
> > display from command line? Is there some dcop call that should be made?
> > Or a signal should be sent to specific process?
> Yes! there is a dcop call. I think it is
> 	dcop ksmserver ksmserver logout x x x
> I cannot recollect precisely. You may experiment with the parameters or
> lookup google. :-)

The values are documented as part of the KApplication class:

the first value is ShutdownConfirm, the second is ShutdownType and the last 
one is ShutdownMode

A comination which might be good for your use case could be
0 0 0
(no confirmation, no shutdown/logout only, schedule shutdown)


0 0 2
(no confirmation, no shutdown/logout only, force now)

It could be (not sure though) that the last value is not important once you 
say "logout only" for the second option.


Kevin Krammer, KDE developer, xdg-utils developer
KDE user support, developer mentoring
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde/attachments/20061106/37407f2e/attachment.sig>
-------------- next part --------------
This message is from the kde mailing list.
Account management:  https://mail.kde.org/mailman/listinfo/kde.
Archives: http://lists.kde.org/.
More info: http://www.kde.org/faq.html.

More information about the kde mailing list