Bug 389765 - kdesu fails with tabs in the command
Summary: kdesu fails with tabs in the command
Status: RESOLVED FIXED
: 388632 390862 392207 393267 394182 394214 405288 (view as bug list)
Alias: None
Product: openSUSE 11.0
Classification: openSUSE
Component: KDE4 Workspace (show other bugs)
Version: Beta 3
Hardware: Other Other
: P2 - High : Normal with 10 votes (vote)
Target Milestone: ---
Assignee: E-mail List
QA Contact: E-mail List
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-05-13 12:04 UTC by Stanislav Visnovsky
Modified: 2015-02-18 21:33 UTC (History)
24 users (show)

See Also:
Found By: ---
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments
screenshot with error message (197.51 KB, image/png)
2008-05-27 16:34 UTC, Duncan Mac-Vicar
Details
strace log (1.74 MB, application/x-gzip)
2008-05-28 13:29 UTC, Duncan Mac-Vicar
Details
remember password unchecked screenshot (161.15 KB, image/png)
2008-05-28 23:40 UTC, Marco Calistri
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Stanislav Visnovsky 2008-05-13 12:04:22 UTC
After the installation of pre-Beta3, the updater asks if user wants to add the sources to keep the system up to date. However, it tries to run 'yast2 piwo' but fails silently and asks immediately the same question.
Comment 1 Stephan Kulow 2008-05-13 19:25:42 UTC
the two michaels and me debugged this in length this afternoon and there seem to be 2 problems: if you use "keep password" the daemon is started and then immediately connected. If the daemon is too slow, then this will fail.

The other problem is that yast2 can not open X connection if run without terminal.

And the third problem: the updater applet does not check the return value
Comment 2 Stephan Kulow 2008-05-13 19:28:15 UTC
how to reproduce #1: 
killall kdesud
/usr/bin/kdesu -c "/usr/bin/xterm +132" < /dev/null
check [ ] keep password
enter root passwd
echo $?


I raise this to blocker because we need registration to work
Comment 3 Michael Matz 2008-05-14 13:47:50 UTC
Actually when you use KDE3 and this applet (that is KDE4 based) there is
another problem.  The whole kdesu thingy becomes confused about which sockets
it wants to use.

$ killall kdesud
$ /usr/bin/kdesu -c "xterm"
kdeinit4: preparing to launch /usr/lib/kde4/libexec/kdesud

(... entering password ..., nothing happens)
kdesud is now running, and we have:

$ ls -l /tmp/ksocket-matz/kdesud*
srw------- 1 matz nogroup 0 2008-05-14 15:40 /tmp/ksocket-matz/kdesud_:0

So, kdesud created a socket named kdesud_:0, all fine, including the $DISPLAY.
stracing kdesu shows that it actually wants to access a different socket:
(I strace the shell where I start kdesu):

$ /usr/bin/kdesu -c "xterm"
kdeinit4: preparing to launch /usr/lib/kde4/libexec/kdesud
kdesud(9220) create_socket: kdesud is already running

(... password dialog comes up, entering password, ... nothing happens)

The strace of kdesu shows this:
9218  access("/tmp/ksocket-matz/kdesud_:", R_OK|W_OK) = -1 ENOENT
...
9218  access("/tmp/ksocket-matz/kdesud_:", R_OK|W_OK) = -1 ENOENT

It's also interesting to see that kdeinit4 also didn't notice that
kdesud already was running, so it started it again, and the second kdesud
did notice it.

I assume that's because of the same error.

So, this is another error in connection with kdesu: kdesud and kdesu accessing
different socket names.  At least in a KDE3 setup.
Comment 4 Stanislav Visnovsky 2008-05-14 14:30:22 UTC
I've tested with KDE4, where it does not work either.
Comment 5 Stephan Kulow 2008-05-15 15:48:32 UTC
*** Bug 390862 has been marked as a duplicate of this bug. ***
Comment 6 Forgotten User 4Gm3Z7gaCh 2008-05-17 15:55:23 UTC
After running yast2 piwo as root and registering, adding repos the following message is given from the suse updater.

The metadata cache needs to be built for the 'Main Repository (NON-OSS)' repository. You can run 'zypper refresh' as root to do this.
The metadata cache needs to be built for the 'Main Repository (OSS)' repository. You can run 'zypper refresh' as root to do this.
Error building the cache database: Can't provide /media.1/media : Can't create /media.1 
Error building the cache database: Can't provide /media.1/media : Can't create /media.1 
Repository 'Updates for 11.0' is invalid. Can't provide /repodata/repomd.xml.asc : Can't create /repodata Please check if the URIs defined for this repository are pointing to a valid repository. 
Problem loading data from 'Updates for 11.0' Resolvables from 'Updates for 11.0' not loaded because of error.

Using YaST online update or zypper works perfectly.
Comment 7 Lubos Lunak 2008-05-19 17:15:24 UTC
Coolo: I've fixed the problem described in comment #3 (your porting bug, BTW :) ), but the description in comment #2 does not match. Can you check whether you still have those problems (kdelibs4 with fix already submitted and in buildservice)?
Comment 8 Thomas Göttlicher 2008-05-20 07:29:04 UTC
*** Bug 392207 has been marked as a duplicate of this bug. ***
Comment 9 Andreas Jaeger 2008-05-21 07:19:47 UTC
*** Bug 392770 has been marked as a duplicate of this bug. ***
Comment 10 Stephan Kulow 2008-05-21 12:27:03 UTC
No, I have a much severe problem now:

kdesu(9932)/kdesu (kdelibs) KDESu::KDEsuClient::command: [ /usr/src/packages/BUILD/kdelibs-4.0.4/kdesu/client.cpp : 211 ] no reply from daemon 
Comment 11 Lubos Lunak 2008-05-21 13:10:45 UTC
I made a lame mistake in the fix, already fixed. The correct kdelibs4 package has "Tue May 20 17:26:40 CEST 2008 - llunak@suse.cz - fix last patch (bnc#389765)". The one works perfectly fine here.

I don't quite understand how any of the bugs here could cause "no reply from
daemon" though. If it's still broken for you, does it depend on whether $DISPLAY has screen number included (i.e. ":0" vs ":0.0")?
Comment 12 Stephan Kulow 2008-05-21 19:16:08 UTC
no idea, it worked perfectly on another try
Comment 13 Lubos Lunak 2008-05-21 19:23:51 UTC
Marking as fixed then.
Comment 14 Lubos Lunak 2008-05-21 19:24:17 UTC
*** Bug 393267 has been marked as a duplicate of this bug. ***
Comment 15 Keith Waugh 2008-05-21 19:44:45 UTC
Yes, I can now launch Yast2 normally after unchecking the box to remember the password. Why did I check that box to begin with? Thanks.
Comment 16 Thomas Göttlicher 2008-05-26 08:28:33 UTC
*** Bug 394182 has been marked as a duplicate of this bug. ***
Comment 17 Lubos Lunak 2008-05-26 15:56:23 UTC
*** Bug 394214 has been marked as a duplicate of this bug. ***
Comment 18 Marco Calistri 2008-05-27 13:07:10 UTC
Hello, I am using opensuse 10.3 with KDE4 latest updates and still getting the problem as per comment # 10 whenever I run opensuse-updater-kde as normal user.
Everything goes smooth only if I run updater-kde as root.

Regards.
Comment 19 Duncan Mac-Vicar 2008-05-27 16:33:19 UTC
Tested latest RC1 build, attached screenshot
Comment 20 Duncan Mac-Vicar 2008-05-27 16:34:06 UTC
Created attachment 218367 [details]
screenshot with error message
Comment 21 Duncan Mac-Vicar 2008-05-27 16:38:42 UTC
Note, happens not when running yast2 piwo, but when calling kdesu --noignorebutton with the zypper refresh command.

Comment 22 Lubos Lunak 2008-05-27 16:53:12 UTC
Works for me. What are the exact steps to reproduce with a fresh user?
Comment 23 Lubos Lunak 2008-05-27 16:57:04 UTC
And, while you're at it, 'ps ux' before and after and strace of the kdesu command might be useful too.
Comment 24 Stephan Kulow 2008-05-28 11:34:44 UTC
duncan just passed by and said:

 - install
 - "kdesu yast2 piwo" works fine
 - at the end of piwo, applet wants to call kdesu zypper install ...
   -> screenshot bug every time

I will try to reproduce as soon as my DVD is ready.
Comment 25 Duncan Mac-Vicar 2008-05-28 13:29:32 UTC
Created attachment 218616 [details]
strace log

Look for this line:

32268 execve("/usr/bin/kdesu", ["kdesu"..., "--noignorebutton"..., "-d"..., "-c"..., "( zypper -x --non-interactive in -l -t patch --name  \"kmps-11\" \"kmps-11\" )\t> /tmp/opensuseupdater.mtqFy0trUQ/opensuseupdater_out 2> /tmp/opensuseupdater.mtqFy0trUQ/opensuseupdater_err "...], [/* 79 vars */]) = 0
Comment 26 Lubos Lunak 2008-05-28 14:20:04 UTC
That's not all info I asked for, but, just as a I guess, if you try without the \t in the command, it will work, right?
Comment 27 Stephan Kulow 2008-05-28 14:46:19 UTC
Duncan, can you please try that? Thomas is on vacation afaik
Comment 28 Stephan Kulow 2008-05-28 15:35:53 UTC
ok, it's indeed fixing the issue. Duncan will submit a new updater with spaces
Comment 29 Stephan Kulow 2008-05-28 18:35:36 UTC
ok, tab is gone
Comment 30 Marco Calistri 2008-05-28 23:40:43 UTC
Created attachment 218755 [details]
remember password unchecked screenshot
Comment 31 Marco Calistri 2008-05-28 23:42:27 UTC
Sorry to communicate this just now, but by simply unchecking "remember password" on the opensuse-updater-kde input password window, the updater runs perfectly.
Comment 32 Henning Schnoor 2008-06-12 10:00:00 UTC
Hi,

the issue as described in bug 394182 is still present in RC1. This definately should be fixed before the release, since it cannot be fixed with an update.

Also, unchecking "keep password" does not fix the problem. Updates are still not performed, the only thing that changes isthat (unlike when having the box checked) opensuseupdater does not show that updates are available anymore.

I"m using KDE 3.5 on a freshly installed 11.0 RC1.

All the best,
   Henning
Comment 33 Stephan Kulow 2008-06-12 10:13:12 UTC
then you have a different problem
Comment 34 Henning Schnoor 2008-06-12 10:43:55 UTC
Hi,

possible, but the description of my problem is exactly the same as in 394182, which has been marked as a duplicate of this bug here.

Where do you suggest I make a report concerning my issue? I have not done reporting on openSuSe before (only on Mozilla and KDE), so I'm not aware of the proper procedure here.

Henning
Comment 35 Henning Schnoor 2008-06-12 10:46:19 UTC
Hi,

further update: when I log into KDE as root, the updater works. So it does seem to be a problem with the kdesu part.

See you,
   Henning
Comment 36 Henning Schnoor 2008-06-12 13:23:58 UTC
Hi again,

you were correct, this is a different problem. Whether or not updating succeeds or not does not depend on whether I'm logged in as root or not, but whether I install only patches (then it works) or also upgrades (then it fails). I'm going to fille a seperate bug on this.

Sorry for the confusion,
   Henning
Comment 37 Thomas Göttlicher 2008-07-24 08:25:51 UTC
*** Bug 388632 has been marked as a duplicate of this bug. ***
Comment 38 Thomas Göttlicher 2008-07-29 11:31:28 UTC
*** Bug 405288 has been marked as a duplicate of this bug. ***
Comment 39 Bernhard Koenig 2008-08-01 23:16:19 UTC
I have KDE 4.1 installed and this problem seems to persist. Just tried to install the new ktorrent upgrade suggested by openSUSE updater but it doesn't work. I click on "select packages", then "install", but nothing happens: the updater checks for new available updates instead of installing the new selected upgrades.
Comment 40 Bernhard Koenig 2008-08-02 13:31:57 UTC
OK, I was able to upgrade ktorrent, ktorrent-lang now with the package manager. It seems the reason why it didn't work from the system tray was that ktorrent, ktorrent-lang have mutual dependencies and the system tray updater couldn't see through that.
Comment 41 Rodney Baker 2008-10-02 11:37:51 UTC
I have the same issue with kdesu/KDE 4.1.1 on both 10.3 and 11.0. Th exact error message is "kdesu(29191)/kdesu (kdelibs) KDEsu::KDEsuClient::command: [/usr/src/packages/BUILD/kdelibs-4.1.1/kdesu/client.cpp:196] no reply from daemon".

This seems to occur on my systems only when running kdesu for the updater applet. I can start YaST with no problems.

The problem occurs for patches if I have the "keep password" checkbox checked and for updates regardless of the state of the "keep password" checkbox.
Comment 42 Adam Spiers 2008-12-14 23:49:41 UTC
Any progress on this?  I see it on a fresh 11.0 install.  Unchecking the "keep password" checkbox works around, but most users won't think to try that (I didn't until I googled and found this bugzilla entry).

With 7 duplicates and 10 votes, shouldn't this be documented on

  http://en.opensuse.org/Bugs:Most_Annoying_Bugs_11.0

?
Comment 43 Adam Spiers 2008-12-15 00:01:01 UTC
Hope the answer is 'yes', because I added it to that wiki page :-)
Comment 44 Lubos Lunak 2009-05-13 13:05:26 UTC
This appears to work fine for me on 11.0 test system, and in newer versions kdesu handles tabs in the command just fine. Can somebody still confirm and what are the exact steps to reproduce?
Comment 45 Adam Spiers 2009-05-13 16:18:21 UTC
I have not noticed it with 11.1 or SLED 11, although this does not necessarily mean that the problem has gone, since I switched from KDE to GNOME a few weeks ago.
Comment 46 Forgotten User bSWU20Bh6O 2009-05-14 20:16:11 UTC
This is working in 11.1. See comment #2 to decide for yourself. Closing this as FIXED.