[SOLVED] KDESU not working

This forum is dedicated to advanced help and support :

Ask here your questions about advanced usage of Mageia. For example you may post here all your questions about network and automated installs, complex server configurations, kernel tuning, creating your own Mageia mirrors, and all tasks likely to be touchy even for skilled users.

[SOLVED] KDESU not working

Postby dkeith » Oct 10th, '13, 19:27

I have somehow managed to break kdesu so that it doesn't work.

kdesu exists in /usr/lib64/kde4/libexec/kdesu

I followed the instructions in https://forums.mageia.org/en/viewtopic.php?f=7&t=4760&p=33271&hilit=kdesu#p33271, but that didn't solve it for me.

output from running kdesu in a gnome-terminal root session:

Code: Select all
# kdesu
Fontconfig warning: "/etc/fonts/conf.d/65-google-droid-sans.conf", line 61: Having multiple values in <test> isn't supported and may not work as expected
Fontconfig warning: "/etc/fonts/conf.d/65-google-droid-sans.conf", line 96: Having multiple values in <test> isn't supported and may not work as expected
kdesu(29247)/kdeui (kdelibs): Session bus not found
To circumvent this problem try the following command (with Linux and bash)
export $(dbus-launch)
KCrash: Application 'kdesu' crashing...
KCrash: Attempting to start /usr/lib64/kde4/libexec/drkonqi from kdeinit
sock_file=/root/.kde4/socket-DAVIDOPTIPLEX9010/kdeinit4__0

[1]+  Stopped                 kdesu


If I become root in terminal by typing 'su -', kdesu works. But that's not where I need it to work. In my X session, typing Alt-F2 and typing 'kdesu ' + an application name, like gnome-terminal or kate, does nothing.

Obviously I did something to break kdesu, how do I get it back?

Oh, and if I click on the mcc/drakconf icon, I still get prompted to enter the root password and mcc starts fine.

Thanks.
Last edited by dkeith on Oct 14th, '13, 23:52, edited 1 time in total.
dkeith
 
Posts: 52
Joined: Oct 1st, '13, 18:22

Re: KDESU not working

Postby doktor5000 » Oct 10th, '13, 21:40

Why do you want to run kdesu from a root session? The point of kdesu is to avoid opening a root session, it's a replacement for that.

Please show the output of
Code: Select all
rpm -V kdebase4-runtime
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18018
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: KDESU not working

Postby dkeith » Oct 10th, '13, 22:30

Code: Select all
# rpm -V kdebase4-runtime


...produces no output.
dkeith
 
Posts: 52
Joined: Oct 1st, '13, 18:22

Re: KDESU not working

Postby doktor5000 » Oct 10th, '13, 23:24

Can you please run /usr/lib64/kde4/libexec/kdesu in a terminal as normal user as you would via Alt+F2?
Like
Code: Select all
/usr/lib64/kde4/libexec/kdesu dolphin
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18018
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: KDESU not working

Postby gohlip » Oct 11th, '13, 05:59

dkeith, maybe it's something more basic...

First you need to install "sudo"
Code: Select all
# urpmi sudo


Then you need to include user in /etc/sudoers
Code: Select all
{user}    ALL=(ALL)    ALL


Finally
Code: Select all
# ln -s  /usr/lib64/kde4/libexec/kdesu /usr/bin/kdesu


Hope this helps. Cheers.
Why do we live? To prove not everything in nature has a purpose.
gohlip
 
Posts: 573
Joined: Jul 9th, '12, 10:50

Re: KDESU not working

Postby dkeith » Oct 11th, '13, 06:50

doktor5000 wrote:Can you please run /usr/lib64/kde4/libexec/kdesu in a terminal as normal user as you would via Alt+F2?
Like
Code: Select all
/usr/lib64/kde4/libexec/kdesu dolphin


ran it as a non-root user... unfortunately since I'm out of the office I had to VPN in to the office from my home Ubuntu 13.04 machine, then ssh in from gnome-terminal, then run the command:

Code: Select all
$ /usr/lib64/kde4/libexec/kdesu dolphin
Fontconfig warning: "/etc/fonts/conf.d/65-google-droid-sans.conf", line 61: Having multiple values in <test> isn't supported and may not work as expected
Fontconfig warning: "/etc/fonts/conf.d/65-google-droid-sans.conf", line 96: Having multiple values in <test> isn't supported and may not work as expected
Connecting to deprecated signal QDBusConnectionInterface::serviceOwnerChanged(QString,QString,QString)
Fontconfig warning: "/etc/fonts/conf.d/65-google-droid-sans.conf", line 61: Having multiple values in <test> isn't supported and may not work as expected
Fontconfig warning: "/etc/fonts/conf.d/65-google-droid-sans.conf", line 96: Having multiple values in <test> isn't supported and may not work as expected
kbuildsycoca4 running...


...and dolphin came up in my X environment in Ubuntu from the remote host. So that's probably not a true test.

The best that I can do apart from that is test it when I'm back in the office.

Thanks.
dkeith
 
Posts: 52
Joined: Oct 1st, '13, 18:22

Re: KDESU not working

Postby dkeith » Oct 11th, '13, 06:54

gohlip wrote:dkeith, maybe it's something more basic...

First you need to install "sudo"
Code: Select all
# urpmi sudo


Then you need to include user in /etc/sudoers
Code: Select all
{user}    ALL=(ALL)    ALL


Finally
Code: Select all
# ln -s  /usr/lib64/kde4/libexec/kdesu /usr/bin/kdesu


Hope this helps. Cheers.


Thanks for the reply, gohlip. I've already set up my non-root user in sudo, and have already symlinked the kdesu script when following the instructions here:

https://forums.mageia.org/en/viewtopic.php?f=7&t=4760&p=33271&hilit=kdesu#p33271

So I don't think that is going to solve it. But I appreciate the ideas. It was worth a try.
dkeith
 
Posts: 52
Joined: Oct 1st, '13, 18:22

Re: KDESU not working

Postby doktor5000 » Oct 11th, '13, 21:47

gohlip wrote:dkeith, maybe it's something more basic...

First you need to install "sudo"
Code: Select all
# urpmi sudo


Then you need to include user in /etc/sudoers
Code: Select all
{user}    ALL=(ALL)    ALL
[/code]


What do you mean by more basic? kdesu is an alternative to sudo, they have nothing to do with each other ...
kdesu can use sudo if you configure it to do so, but setting up sudo will not change anything about kdesu.
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18018
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: KDESU not working

Postby gohlip » Oct 12th, '13, 06:14

doktor5000 wrote:What do you mean by more basic? kdesu is an alternative to sudo, they have nothing to do with each other ...
kdesu can use sudo if you configure it to do so, but setting up sudo will not change anything about kdesu.

What do you mean they have nothing to do with each other?
Can you back up what you said?
Why do we live? To prove not everything in nature has a purpose.
gohlip
 
Posts: 573
Joined: Jul 9th, '12, 10:50

Re: KDESU not working

Postby doktor5000 » Oct 12th, '13, 19:14

kdesu is a frontend to enable execution of (GUI) applications as root, it uses su to do that. You don't need sudo for that, and by default kdesu doesn't use sudo.

sudo is an alternative for su, and has to be configured to allow users to launch root commands.
Check e.g. https://wiki.archlinux.org/index.php/sudo#kdesu
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18018
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: KDESU not working

Postby gohlip » Oct 13th, '13, 05:32

Thanks for the link, referencing your link...."Fortunately one can tell kdesu to use sudo instead of su."
Also see links below..
http://www.linfo.org/kdesu.html
http://techbase.kde.org/Projects/kdesu#sudo
Why do we live? To prove not everything in nature has a purpose.
gohlip
 
Posts: 573
Joined: Jul 9th, '12, 10:50

Re: KDESU not working

Postby doktor5000 » Oct 13th, '13, 10:37

What's your point? Both links explain exactly what I was telling you, did you actually read them thoroughly?
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18018
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: KDESU not working

Postby gohlip » Oct 13th, '13, 17:26

Yes, correct. kdesu has nothing to do with sudo unless you set it to do so.
And Debian/Ubuntu has defaulted to do so with kdesudo.
Mageia's kdesu, if set up, is with su.
(Mageia's sudo, if set up, is with sudo.)
Cheers, doktor5000. No issue here. I am clear. Thanks.
Why do we live? To prove not everything in nature has a purpose.
gohlip
 
Posts: 573
Joined: Jul 9th, '12, 10:50

Re: KDESU not working

Postby gohlip » Oct 13th, '13, 18:27

Yes, correct. kdesu has nothing to do with sudo unless you set it to do so.
Mageia's kdesu, if set up, is with su.

[edit] - mistake in editing: sorry for the noise.
Why do we live? To prove not everything in nature has a purpose.
gohlip
 
Posts: 573
Joined: Jul 9th, '12, 10:50

Re: KDESU not working

Postby dkeith » Oct 14th, '13, 19:07

doktor5000 wrote:Can you please run /usr/lib64/kde4/libexec/kdesu in a terminal as normal user as you would via Alt+F2?
Like
Code: Select all
/usr/lib64/kde4/libexec/kdesu dolphin


Ok ran the above command from a gnome-terminal session, ultimately the KDE Crash Handler popped up, here's the developer info:

Code: Select all
Application: KDE su (kdesu), signal: Aborted
Using host libthread_db library "/lib64/libthread_db.so.1".
[KCrash Handler]
#5  0x00007ffcc1d24a65 in raise () from /lib64/libc.so.6
#6  0x00007ffcc1d260c8 in abort () from /lib64/libc.so.6
#7  0x00007ffcc2637224 in qt_message_output(QtMsgType, char const*) () from /lib64/libQtCore.so.4
#8  0x00007ffcc3f8d876 in QDebug::~QDebug() () from /lib64/libkdeui.so.5
#9  0x00007ffcc406a037 in KApplicationPrivate::init(bool) () from /lib64/libkdeui.so.5
#10 0x00007ffcc406b008 in KApplication::KApplication(bool) () from /lib64/libkdeui.so.5
#11 0x00000000004066db in main ()


...and here's the command line info:

Code: Select all
$ /usr/lib64/kde4/libexec/kdesu dolphin
Fontconfig warning: "/etc/fonts/conf.d/65-google-droid-sans.conf", line 61: Having multiple values in <test> isn't supported and may not work as expected
Fontconfig warning: "/etc/fonts/conf.d/65-google-droid-sans.conf", line 96: Having multiple values in <test> isn't supported and may not work as expected
kdesu(21860)/kdeui (kdelibs): Session bus not found
To circumvent this problem try the following command (with Linux and bash)
export $(dbus-launch)
KCrash: Application 'kdesu' crashing...
KCrash: Attempting to start /usr/lib64/kde4/libexec/drkonqi from kdeinit
sock_file=/home/dkeith/.kde4/socket-DAVIDOPTIPLEX9010/kdeinit4__0

[1]+  Stopped                 /usr/lib64/kde4/libexec/kdesu dolphin


Once I ran - as a normal user -
Code: Select all
export $(dbus-launch)
, then ran the above command, it ran fine.
dkeith
 
Posts: 52
Joined: Oct 1st, '13, 18:22

Re: KDESU not working

Postby doktor5000 » Oct 14th, '13, 20:05

Seems your dbus installation/setup as normal user is broken. Should be started with X login via /etc/X11/xinit.d/30dbus
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18018
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: KDESU not working

Postby dkeith » Oct 14th, '13, 21:15

doktor5000 wrote:Seems your dbus installation/setup as normal user is broken. Should be started with X login via /etc/X11/xinit.d/30dbus


Every time I've come in to my KDE desktop I would get the notification on the KDE panel/system tray/notification app that dbus failed to start. Can I just do a urpmi --replacepkgs dbus-whatever?
dkeith
 
Posts: 52
Joined: Oct 1st, '13, 18:22

Re: KDESU not working

Postby doktor5000 » Oct 14th, '13, 21:29

You can try, but will probably not help. We've had some users reporting the same issue in german forum since Mageia 2, but root cause is still unknown, and it's not reproducable elsewhere: https://forums.mageia.org/de/viewtopic.php?f=18&t=1301

You may want to remove draksnapshot, which sometimes seems to be involved in the problem.
Also take a look at those bugs: https://bugs.mageia.org/show_bug.cgi?id=5622 and https://bugs.mageia.org/show_bug.cgi?id=9326

EDIT: Which medium did you use to install Mageia, and is that a fresh installation, or an upgrade/import of old settings?
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18018
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: KDESU not working

Postby dkeith » Oct 14th, '13, 21:36

I uninstalled draksnapshot as part of the troubleshooting of another issue, am now using luckybackup.

I installed MGA2 as I recall, and upgraded it to MGA3.

Thanks.
dkeith
 
Posts: 52
Joined: Oct 1st, '13, 18:22

Re: KDESU not working

Postby doktor5000 » Oct 14th, '13, 23:35

You could try with a freshly created user, if the issue persists.
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18018
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: [SOLVED] KDESU not working

Postby dkeith » Oct 14th, '13, 23:53

Ok, I think I've got it solved now, thanks for the advice. In cleaning up my luckybackup files on a test backup I must have deleted some system files. I reinstalled > 400 pkgs, and now kdesudo seems to be working.

Thanks again.
dkeith
 
Posts: 52
Joined: Oct 1st, '13, 18:22


Return to Advanced support

Who is online

Users browsing this forum: No registered users and 1 guest