Bug 514056

Summary: dbus hangs when kfmclient is run by root
Product: [openSUSE] openSUSE 12.2 Reporter: Pavol Rusnak <prusnak>
Component: KDE4 ApplicationsAssignee: E-mail List <kde-maintainers>
Status: VERIFIED INVALID QA Contact: E-mail List <qa-bugs>
Severity: Normal    
Priority: P5 - None CC: ctrippe, forgotten_d3bkfIx-vJ, forgotten_vXTZVacoSi, forgotten_xs3PtXj4XH, marc.collin, publio.escipion.el.africano, roger.luedecke, sboyce
Version: RC 2   
Target Milestone: ---   
Hardware: Other   
OS: openSUSE 12.2   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---
Attachments: strace output
List of launch errors given by the system when starting applications as a root user.

Description Pavol Rusnak 2009-06-17 16:19:10 UTC
When I run kfmclient under normal client it works:

[prusnak@leira 0 ~] kfmclient openURL http://example.com

opens the webpage in browser. When I switch to root and perform the same task it stalls:

[root@leira 0 ~] kfmclient openURL http://example.com
Comment 1 Pavol Rusnak 2009-06-17 16:20:52 UTC
Created attachment 298733 [details]
strace output
Comment 2 Forgotten User vXTZVacoSi 2009-06-17 16:36:30 UTC
Works for me on KDE4.2.4 (:KDE42 repo) with 'su -' to change to root, doesn't when using only 'su'

how did you switch to root? 'su -' or plain 'su'?

Using only 'su' won't allow any kde app to start, but it is also wrong to switch to root only with 'su' as it preservs the env variables if I am not mistaken (something you don't really want, this will make root the owner of your .kde settings...)

Sounds to me like https://bugzilla.novell.com/show_bug.cgi?id=502058
Comment 3 Lubos Lunak 2009-07-30 14:28:59 UTC
*** Bug 502058 has been marked as a duplicate of this bug. ***
Comment 4 Lubos Lunak 2009-07-30 14:32:49 UTC
According to strace it hangs in dbus.
Comment 5 Christian Trippe 2009-07-30 14:51:07 UTC
This might be related to the following upstream bugs:

https://bugs.kde.org/show_bug.cgi?id=199209

https://bugs.kde.org/show_bug.cgi?id=165268
Comment 6 Lubos Lunak 2009-07-31 20:21:26 UTC
*** Bug 487060 has been marked as a duplicate of this bug. ***
Comment 7 Timo Hoenig 2010-10-29 11:54:55 UTC
-> Upstream.
Comment 8 Christian Trippe 2010-12-13 19:48:43 UTC
*** Bug 656210 has been marked as a duplicate of this bug. ***
Comment 9 Forgotten User xs3PtXj4XH 2010-12-15 03:42:42 UTC
Hold on, how come I didn't get this behaviour until 11.4 M4 and never once before?  If it was an upstream bug, shouldn't it have shown up before now, and in every release since it was reported?
Comment 10 Forgotten User xs3PtXj4XH 2011-01-30 17:17:57 UTC
Created attachment 411146 [details]
List of launch errors given by the system when starting applications as a root user.

Bug is still present in 11.4 Milestone 6.  I have attached launch feedback.
Comment 11 Forgotten User vXTZVacoSi 2011-02-24 16:44:34 UTC
*** Bug 674745 has been marked as a duplicate of this bug. ***
Comment 12 Forgotten User xs3PtXj4XH 2011-05-03 15:01:21 UTC
I've mentioned this bug report here: https://bugs.kde.org/show_bug.cgi?id=199209
Comment 13 Forgotten User xs3PtXj4XH 2011-07-20 12:52:08 UTC
This bug has also been cited upstream here: https://bugs.kde.org/show_bug.cgi?id=277249
Comment 14 Roger Luedecke 2011-11-26 16:46:19 UTC
This is not upstream. The problem is still occuring, and the related KDE.org bugreports indicate it is our problem. This is not fixed, and it is not upstream.
Comment 15 Forgotten User xs3PtXj4XH 2012-04-08 11:01:46 UTC
I have tested this issue against 12.2 Milestone 2 and the problem is ongoing. Can anybody else confirm?
Comment 16 Forgotten User xs3PtXj4XH 2012-04-12 10:26:12 UTC
Fixed platform setting to 12.2
Comment 17 Forgotten User xs3PtXj4XH 2012-04-16 16:48:22 UTC
12.2 Milestone 3 still returns "session bus not found" to the user when issuing commands to kfmclient as root.
Comment 18 Forgotten User xs3PtXj4XH 2012-08-06 05:37:55 UTC
Still present in 12.2 RC2.
Comment 19 Marc collin 2012-11-15 20:04:06 UTC
in suse 12.2 and kde 4.9.3
in user session

i do: su

kfmclient openURL http://google.com
klauncher(24105) kdemain: No DBUS session-bus found. Check if you have started the DBUS server. 
kdeinit4: Communication error with launcher. Exiting!
kfmclient(24101)/kdecore (KSycoca) KSycocaPrivate::checkVersion: Found version 209 , expecting version 210 or higher. 
kfmclient(24101)/kdecore (KSycoca) KSycocaPrivate::checkVersion: Found version 209 , expecting version 210 or higher. 
kfmclient(24101): No ksycoca4 database available! 

kfmclient(24101)/kdecore (trader) KServiceTypeTrader::defaultOffers: KServiceTypeTrader: serviceType  "KUriFilter/Plugin"  not found 
kfmclient(24101): Session bus not found 
Abandon

so that fail

if i do su - 

kfmclient openURL http://google.com
Connecting to deprecated signal QDBusConnectionInterface::serviceOwnerChanged(QString,QString,QString)
kbuildsycoca4 running...

that work
Comment 20 Marc collin 2012-11-16 19:24:45 UTC
for starting a kde graphic program, it should be started with su - or kdesu