kdesu hangs

some time in the last 2 weeks or so, KDESU started hanging for me when the root password is supplied. Using the command line su works fine. Used to work fine. Tips on debugging this?

When run from the command line, when it hangs the output is

kdesu_stub

where should I be picking up kdesu from?

Updated 5 PCs to openSUSE-15.0 this week.
On all I had that “kdesu hangs” problem after “zypper dist-upgrade” completed and before reboot.

But on all PC’s the problem went away after the post-upgrade reboot. Except one! (it also shows “kdesu_stub” on the shell)

I have the same issue

K then… I logged out… went to runlevel 3, emptied out /tmp and /var/tmp, rebooted, all is well. :slight_smile:

This doesn’t work for me. What you need to do is **VERY CAREFULLY **rm -rf (using a for loop) the .Xauthority files and subdirectories in root.

Make sure you don’t remove from / and ONLY DO THIS WITHIN THE .Xauthority DIRECTORY!

This is the result of a permissions problem which can occur while running an X server as root at some time (perhaps during a zypper dup).

After another system upgrade to Leap 15.0 because KDE didn’t start after some recommended "fixes’ to get NVIDIA codecs, this “fix”, removing the .Xauthority directory in / stopped working as well.
(This is also after removing all the files in /tmp and /var/temp and rebooting.)

from the command line
kdesu -c ls

first produces the message:
No protocol specified

then, upon entering the root password in the dialog:
[FONT=courier new]kdesu_stub
[FONT=arial]
[/FONT][/FONT]appears and kdesu hangs.

What to do?

kdesu is used to start GUI programs not command line commands. So not at all sure what you are trying to do??? I would not expect kdesu to work with ls since ls runs from the command line.

After another system upgrade to Leap 15.0 because KDE didn’t start after some recommended "fixes’ to get NVIDIA codecs, this “fix”, removing the .Xauthority directory in / stopped working as well.
(This is also after removing all the files in /tmp and /var/temp and rebooting. su works fine.)

Running Yast from the menu which starts kdesu hangs. Trying kdesu [FONT=arial]from the command line reveals the problem,[/FONT]

from the command line
kdesu -c ls

first produces the message:
No protocol specified

then, upon entering the root password in the dialog:
[FONT=courier new]kdesu_stub
[FONT=arial]
[/FONT][/FONT]appears and kdesu hangs.

What to do?

Please show output of


zypper lr -d

And, gogalthorp is right, kdesu is for starting GUI apps. If I ( on Tw ) invoke


kdesu -c ls

I get the kdesu window, enter the root password and then … nothing.

Just checked in my Leap 15 VM, and


kdesu yast2 

works as expected.

The output of kdesu yast2 (same result as before, the kdesu dialog hangs after kdesu_stub [FONT=arial]is written to the console. Yast2 doesn’t start:
[/FONT]


$ kdesu yast2
$ No protocol specified  
kdesu_stub 

The output of zypper lr -d :


kwalletd5: Checking for pam module
kwalletd5: Got pam-login param
kwalletd5: Waiting for hash on 5-
kwalletd5: waitingForEnvironment on: 3
Repository priorities are without effect. All enabled repositories share the same priority.

#  | Alias                           | Name                                    | Enabled | GPG Check | Refresh | Priority | Type   | URI          
                                                            | Service
---+---------------------------------+-----------------------------------------+---------+-----------+---------+----------+--------+--------------
------------------------------------------------------------+--------
 1 | download.opensuse.org-non-oss   | Main Repository (NON-OSS)               | Yes     | (r ) Yes  | Yes     |   99     | rpm-md | http://downlo
ad.opensuse.org/distribution/leap/15.0/repo/non-oss/        |         
 2 | download.opensuse.org-non-oss_1 | Update Repository (Non-Oss)             | Yes     | (r ) Yes  | Yes     |   99     | rpm-md | http://downlo
ad.opensuse.org/update/leap/15.0/non-oss/                   |         
 3 | download.opensuse.org-oss       | Main Repository (OSS)                   | Yes     | (r ) Yes  | Yes     |   99     | rpm-md | http://downlo
ad.opensuse.org/distribution/leap/15.0/repo/oss/            |         
 4 | download.opensuse.org-oss_1     | Main Update Repository                  | Yes     | (r ) Yes  | Yes     |   99     | rpm-md | http://downlo
ad.opensuse.org/update/leap/15.0/oss                        |         
 5 | dvd                             | dvd                                     | Yes     | (r ) Yes  | Yes     |   99     | rpm-md | http://opensu
se-guide.org/repo/openSUSE_Leap_15.0/                       |         
 6 | openSUSE-Leap-15.0-1            | openSUSE-Leap-15.0-1                    | Yes     | (r ) Yes  | Yes     |   99     | rpm-md | http://downlo
ad.opensuse.org/distribution/leap/15.0/repo/oss/            |         
 7 | packman                         | packman                                 | Yes     | (r ) Yes  | Yes     |   99     | rpm-md | http://packma
n.inode.at/suse/openSUSE_Leap_15.0/                         |         
 8 | repo-debug                      | openSUSE-Leap-15.0-Debug                | No      | ----      | ----    |   99     | rpm-md | http://downlo
ad.opensuse.org/debug/distribution/leap/15.0/repo/oss/      |         
 9 | repo-debug-non-oss              | openSUSE-Leap-15.0-Debug-Non-Oss        | No      | ----      | ----    |   99     | rpm-md | http://downlo
ad.opensuse.org/debug/distribution/leap/15.0/repo/non-oss/  |         
10 | repo-debug-update               | openSUSE-Leap-15.0-Update-Debug         | No      | ----      | ----    |   99     | rpm-md | http://downlo
ad.opensuse.org/debug/update/leap/15.0/oss/                 |         
11 | repo-debug-update-non-oss       | openSUSE-Leap-15.0-Update-Debug-Non-Oss | No      | ----      | ----    |   99     | rpm-md | http://downlo
ad.opensuse.org/debug/update/leap/15.0/non-oss/             |         
12 | repo-source                     | openSUSE-Leap-15.0-Source               | No      | ----      | ----    |   99     | rpm-md | http://downlo
ad.opensuse.org/source/distribution/leap/15.0/repo/oss/     |         
13 | repo-source-non-oss             | openSUSE-Leap-15.0-Source-Non-Oss       | No      | ----      | ----    |   99     | rpm-md | http://downlo
ad.opensuse.org/source/distribution/leap/15.0/repo/non-oss/ |   

Also, the output of uname -a:


Linux linux-zmcv.suse 4.12.14-lp150.12.7-default #1 SMP Tue Jul 17 12:08:37 UTC 2018 (4804d19) x86_64 x86_64 x86_64 GNU/Linux

I’m having a similar problem, but if my problem is different from the one being addressed here - then let me know and I could start a new thread.

If I want to run Yast2 I get the kdesu window to enter my password. I enter it, press ‘Enter’ or click ‘OK’ and nothing happens. Eventually I try to close the window and get a warning that kdesu is not responding.

So I tried starting it with a command line. (If I’m doing things wrong here, blame my inexperience!)

I did ‘su’ to get root powers.
Then ‘yast2’
While YaST started, konsole said this:

tim@tvb-opensuse0:~> su
Password:  
**tvb-opensuse0:/home/tim #** yast2
QStandardPaths: wrong ownership on runtime directory /run/user/1000, 1000 instead of 0
libGL error: unable to load driver: nouveau_dri.so
libGL error: driver pointer missing
libGL error: failed to load driver: nouveau


Could someone show me how to fix this?

Your things are different from what the thread is about.

I did not read all of it, but

  • when you want to start YaST from KDE, you just click the icon in the menu, no kdesu involved;
  • when you want to change to root in a shell, you use
su -

and not

su

(or when in KDE, use from the menu the Terminal in Superuser mode or what it is called, it does also do the su -).

Thank you for the reply and for the correction about my use of su!
If I click YaST from the menu it has always prompted me for my password, with a window titles “Run as root - KDE su”.
Anyway, sorry for ending up in the wrong thread.

kdesu is still not working correctly for me, but hanging up after entering in the su password when I invoke this command hitting the icon in the task bar at the bottom of the page. I can bring up superuser mode, then enter “yast2” and it comes up graphically as desired. But I cannot enter “kdesu yast2” either from cli.

Any ideas on what needs to be fixed? /run/user/1000 seems to have something to do with all this, but I am not sure what role it is playing.

  • Randall

I’ve been grappling with a borked kdesu since upgrading 42.3 => Leap 15.0. I really doubt it’s connected to the /run/user/1000 message; that’s appearing after running a number of unrelated commands. And I’ve check the folder content/permissions compared to a clean install, no difference.

The kdesu lockup issue has been around, typically after an upgrade, for years. It appears to somehow get caused by old cruff - clean installs appear fine. It may be a weirdness in the actual kdesu code (as has been reported on mailing lists); this program is old and AFAIK hasn’t been touched since ~2012. KDE bugzilla is surprisingly of little help here, other than to repeat the workaround that has been posted on blogs/elsewhere, which is to force kdesu to actually use kdesudo (available in a community repo). Using kdesudo does work from the command line, Alt-F2 works with it as do menu items running as root. A major annoyance though is that the window graphics called are not from plasma, e.g., YaST (using qt graphics IIRC) has very small fonts and dolphin does not display folder icons, plus other nuisances. When I saw this happen long ago, either changing the KDE desktop settings for root or using qtconfig to change qt’s default graphics, fixed this. Now those steps change fonts in some windows, but mostly do nothing in others - it may be that just an xwindow is being used. I think that may be related to a path issue with XDG_RUNTIME_DIR, but I eventually grew too impatient fooling with that after messing with a bunch of other upgrade glitches (which typically doesn’t happen).

In my case, I’m probably paying the price for having done so many sequential upgrades plus being a long-time KDE user. Even doing manual cleanup after upgrade, occasionally a clean install is still necessary to give the system an enema. I’m biting the bullet, doing the clean install, and then migration. Ugh. :stuck_out_tongue:

After an upgrade from 42.3 to 15 i had exactly the same error with kdesu hangs and “no protocol specified”.
The solution, at last for me, was to create a new user. After booting with this user everything was back to normal again.
Comparing the new users /home with the old one there were some differences.
In my case i simply deleteted the folders kde, kde3 and dbus in /home of the old user, rebooted and logged in my old user.
Everything is working again flawlessly with my old user now.
I hope this helps.

To the question in your thread title:

You better should have posted such a question in Forums Feedback > Forums Commenst/Suggestions. But we saw it.

The answr is, that we do not know. We see no reason for it to be closed. Must have been some incident. It is reopened now.

This thread will be merged into it to have all together.

No problem… and thanks.

I tried

karl@erlangen:~> kdesu -c "ls > ls.out"
karl@erlangen:~> ll ls.out
-rw-r--r-- 1 root root 1371 17. Sep 21:27 ls.out
karl@erlangen:~> 

You can run any command with kdesu, but the output will not be connected to the Konsole you are working in.