Description of problem: cannot connect to X server :0.0 with "sudo su - root" in runlevel5 with any X application like kwrite, xterm, xeyes,..... Version-Release number of selected component (if applicable): How reproducible: Always Steps to Reproduce: 1. As a user, click up a terminal 2. su - root and create "/etc/sudoers.d/sudo_sys_owner" with Host_Alias CSNETS = 192.168.1.0/24 User_Alias FULLTIMERS = bittwister Cmnd_Alias SU = /usr/bin/su FULLTIMERS ALL = NOPASSWD: ALL Change 192.168.1.0/24 and bittwister to match your setup and set privs with 3. chmod 440 /etc/sudoers.d/sudo_sys_owner 4. exit You should be back in your user account 5. sudo su - root should provide you with the root prompt, if not, log out/in and try sudo command again. Now for the test, at the root prompt 6. touch del_me 7. kwrite del_me If you are in runlevel5 it should fail. If runlevel is 3 kwrite should pop up. 8 Switch runlevels, log in. If runlevel3, enter startx click up the terminal and do a 9. sudo su - root 10. kwrite del_me See attachment if test procedure does not work for you.
Created attachment 1900 [details] My test setup/steps/results
Just tried this on my system (I already had a sudo rule in place for me so I skipped that part - hopefully it doesn't have any bearing). Anyway: [colin@jimmy ~]$ xprop -root | grep PULSE_ID PULSE_ID(STRING) = "603@6cb2a4b2bd6df042e57da8a4000001d4/4423" [colin@jimmy ~]$ sudo su - root [root@jimmy ~]# xprop -root | grep PULSE_ID PULSE_ID(STRING) = "603@6cb2a4b2bd6df042e57da8a4000001d4/4423" So as you can see I can still happily access my users X11. I did also run xeyes and it worked fine. Anyway, I'm about to try and reset the suders file to see whether it is simple config of sudo that is to blame. I'll report back in a mo'
CC: (none) => mageia
Checked with a clean /etc/suders and a file dropped in suders.d just as you describe. It all worked fine. So I simply cannot reproduce here. What msec security level do you have? Perhaps it's getting in the way?
Created attachment 1904 [details] re-test with xeyes and requested msec settings
OK, so maybe it's not related to msec... What about $XAUTHORITY env var? [colin@jimmy ~]$ echo $XAUTHORITY /var/run/gdm/auth-for-colin-LjSec3/database [colin@jimmy ~]$ xauth list jimmy/unix:0 MIT-MAGIC-COOKIE-1 aaaaabbbbbbbcccccccdddddddeeeeef [colin@jimmy ~]$ sudo su - root [root@jimmy ~]# echo $XAUTHORITY /root/.xauth01jE5y [root@jimmy ~]# xauth list jimmy/unix:0 MIT-MAGIC-COOKIE-1 aaaaabbbbbbbcccccccdddddddeeeeef (value changed to protect the innocent, but it's the same value ultimately). What says yours?
Hmmm, looking like you are running gnome. Running default install kde here. [junk@cauldron1 ~]$ echo $XAUTHORITY [junk@cauldron1 ~]$ xauth list cauldron1.home.test:0 MIT-MAGIC-COOKIE-1 47d... cauldron1.home.test:0 MIT-MAGIC-COOKIE-1 47d2.... cauldron1.home.test/unix:0 MIT-MAGIC-COOKIE-1 47d2.... cauldron.home.test/unix:0 MIT-MAGIC-COOKIE-1 19fc... [junk@cauldron1 ~]$ sudo su - root [root@cauldron1 ~]# echo $XAUTHORITY [root@cauldron1 ~]# xauth list xauth: file /root/.Xauthority does not exist [root@cauldron1 ~]# All are terminals are xterm. launched from: 1. ~/.kde4/Autostart/startup 2. desktop shortcut 3. run command via right desktop click and tried a konsole. $XAUTHORITY is blank
Looks to me like a KDM/KDE init error then. I guess some work is needed to bring it up to speed. A quick test would be to use gdm as a DM but still log into KDE and see if the problem persists. At least then it would easier to see where to start looking in order to fix.
Source RPM: (none) => kdebase4-runtime-4.8.1-3.mga2.src.rpm
Problem workaround solution: 1. urpmi --auto gdm 2. change DISPLAYMANAGER=gdm in /etc/sysconfig/desktop 3. reboot I tested with xterm -fg white -bg darkblue -e "sudo su - root" & xterm -fg white -bg Seagreen &
Hi, This bug was filed against cauldron, but we do not have cauldron at the moment. Please report whether this bug is still valid for Mageia 2. Thanks :) Cheers, marja
Keywords: (none) => NEEDINFO
(In reply to comment #9) > > Please report whether this bug is still valid for Mageia 2. still valid.
Keywords: NEEDINFO => (none)
With a new install of Mageia 3 KDE, and with Sudo installed & working, I cannot run Dolphin or Kwrite as root (the only 2 I've tried) it producing the same error as in the opening post. 'su -c' doesn't work either. It's a bit disheartening to see a year and a version on, that the same bug exists.
Version: Cauldron => 3Hardware: All => i586CC: (none) => omelette
This is a DM issue. I suspect it's kdm and kdm sucks hugely. As mentioned above gdm behaves much better and I hope we can drop kdm soon for something better (e.g. ssdm) as the default KDE/Qt DM and get rid of these issues once and for all.
CC: (none) => junknospam
Mageia 3 changed to end-of-life (EOL) status 4 months ago. http://blog.mageia.org/en/2014/11/26/lets-say-goodbye-to-mageia-3/ Mageia 3 is no longer maintained, which means that it will not receive any further security or bug fix updates. As a result we are closing this bug. If you can reproduce this bug against a currently maintained version of Mageia please feel free to click on "Version" change it against that version of Mageia and reopen this bug. Thank you for reporting this bug and we are sorry it could not be fixed. -- The Mageia Bugsquad
Status: NEW => RESOLVEDResolution: (none) => OLD