Bug 12572 - Root apps can't run from CLI in KDE
Summary: Root apps can't run from CLI in KDE
Status: RESOLVED DUPLICATE of bug 13834
Alias: None
Product: Mageia
Classification: Unclassified
Component: RPM Packages (show other bugs)
Version: Cauldron
Hardware: x86_64 Linux
Priority: Normal normal
Target Milestone: ---
Assignee: Mageia Bug Squad
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-02-04 13:35 CET by Frank Griffin
Modified: 2015-05-21 10:49 CEST (History)
2 users (show)

See Also:
Source RPM: polkit
CVE:
Status comment:


Attachments

Description Frank Griffin 2014-02-04 13:35:45 CET
Refer to the tail end of bug#11184 for the history.

In current cauldron, any attempt to run an app that requires root from a terminal in KDE gives an error rather than a popup for the root password:

***************************************************
[ftg@ftgme2 ~]$ diskdrake
Error executing command as another user: Not authorized

This incident has been reported.
***************************************************

Some exchange from bug#11184:

***************************************************
(Colin)
I was under the impression that the KDE polkit stuff was "built in" somehow, but we do also have a separate package: polkit-kde-agent-1. Does installing it and rebooting make things magically work?

(Frank)
[root@ftgme2 ~]# urpmi polkit-kde-agent-1
Package polkit-kde-agent-1-0.99.0-6.mga4.x86_64 is already installed
[root@ftgme2 ~]#

(Colin)
Can you check that it's actually running correctly? If it's running, try killing it and running it again manually?

(Frank)
Dunno if I did this correctly.  Curious that polkit-agent-helper-1 was running originally, but not after the restart:

[root@ftgme2 ~]# ps ax | grep polkit
 2697 ?        Ssl    0:01 /usr/lib/polkit-1/polkitd --no-debug
17486 ?        S      0:00 /usr/lib/polkit-1/polkit-agent-helper-1 root cookie0
19853 ?        Sl     0:23 /usr/lib64/kde4/libexec/polkit-kde-authentication-agent-1
20001 pts/1    S+     0:00 grep --color polkit
[root@ftgme2 ~]# kill 19853
[root@ftgme2 ~]# /usr/lib64/kde4/libexec/polkit-kde-authentication-agent-1 &
[2] 20363
[root@ftgme2 ~]# New PolkitAgentListener  0x225b000 
Adding new listener  PolkitQt1::Agent::Listener(0x23c61b0) for  0x225b000 

[2]+  Done                    /usr/lib64/kde4/libexec/polkit-kde-authentication-agent-1
[root@ftgme2 ~]# ps ax | grep polkit
 2697 ?        Ssl    0:01 /usr/lib/polkit-1/polkitd --no-debug
20369 pts/1    Sl     0:00 /usr/lib64/kde4/libexec/polkit-kde-authentication-agent-1
20413 pts/1    S+     0:00 grep --color polkit

[ftg@ftgme2 ~]$ diskdrake
Error executing command as another user: Not authorized

This incident has been reported.
[ftg@ftgme2 ~]$

(Colin)
This seems like a strange issue. Can you open a new bug report because this really is something separate to this bug. Ideally you would copy in the same info as you've done here, close this bug again and CC me on the new bug!

If you could also comment on whether you do anything odd to login or if it's just a normal login through a DE (e.g. any tty+startx, autologin etc. etc.)

Oh, also just noticed you were doing things as root. Don't do anything as root, only your user.
****************************************************

Nothing odd to login, just userid/password to KDM with KDE already set as last-used DE.

As for root:

****************************************************
[ftg@ftgme2 ~]$ /usr/lib64/kde4/libexec/polkit-kde-authentication-agent-1 &
[1] 5133
[ftg@ftgme2 ~]$ New PolkitAgentListener  0x672600 
Adding new listener  PolkitQt1::Agent::Listener(0x7a4fb0) for  0x672600 

[1]+  Done                    /usr/lib64/kde4/libexec/polkit-kde-authentication-agent-1
[ftg@ftgme2 ~]$ ps ax | grep polkit
 2697 ?        Ssl    0:03 /usr/lib/polkit-1/polkitd --no-debug
 5137 pts/1    Sl     0:00 /usr/lib64/kde4/libexec/polkit-kde-authentication-agent-1
 5177 pts/1    S+     0:00 grep --color polkit
[ftg@ftgme2 ~]$ diskdrake
Error executing command as another user: Not authorized

This incident has been reported.
[ftg@ftgme2 ~]$ 

****************************************************

So, no difference.
It seems to be running as root

Reproducible: 

Steps to Reproduce:
Frank Griffin 2014-02-04 13:36:10 CET

CC: (none) => mageia

Comment 1 Florian Hubold 2014-02-04 22:46:16 CET
Works fine here under Mageia 4, apart from the fact that "diskdrake" is not in $PATH.

[doktor5000@Mageia3 ~]$ ls -al /*bin/diskdrake
lrwxrwxrwx 1 root root 15 Feb  2 23:44 /sbin/diskdrake -> ../bin/drakdisk*

[doktor5000@Mageia3 ~]$ echo $PATH
/usr/local/bin:/usr/bin:/usr/games:/usr/lib64/qt4/bin:/usr/lib64/qt5/bin:/home/doktor5000/bin:/usr/lib64/qt5/bin:/home/doktor5000/bin

Running drakdisk as normal user works just fine, running polkit agent as expected.


So I'd say close as RESOLVED INVALID?

CC: (none) => doktor5000

Comment 2 Frank Griffin 2014-02-04 23:00:49 CET
Sorry, upon further testing I find that this only happens from the command line of an ssh session from another machine.  From a terminal on the host machine, it works as expected.

But this worked fine in the recent past.
Comment 3 Samuel Verschelde 2015-05-21 10:49:34 CEST
I think it's a duplicate of bug 13834. Reopen if needed.

*** This bug has been marked as a duplicate of bug 13834 ***

Status: NEW => RESOLVED
Resolution: (none) => DUPLICATE


Note You need to log in before you can comment on or make changes to this bug.