public inbox for gentoo-user@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-user] xhost +local:root ???
@ 2006-09-16 12:12 Meino Christian Cramer
  2006-09-16 14:16 ` Neil Isaac
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Meino Christian Cramer @ 2006-09-16 12:12 UTC (permalink / raw
  To: gentoo-user

Hi,

 before I 

		emerge -e system/world

 my whole system I could allow root to open the X display by typing

        xhost +local:root ??? 

 . This seems to not to work any longer.

 When starting ethereal/wireshark I get:

        Gtk-WARNING **: cannot open display:

 . 

 I searched the gentoo wiki for matches to combinations of 

        X11 root xhost

 and such but didnt find anything else than the xhost command as shown
 above.

 Is there any way to allow root to use the X display when a user has
 opened the session and su'ed to root ?

 Thank you very much for any help in advance !

 Kind regards,
 mcc

-- 
gentoo-user@gentoo.org mailing list



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [gentoo-user] xhost +local:root ???
  2006-09-16 12:12 [gentoo-user] xhost +local:root ??? Meino Christian Cramer
@ 2006-09-16 14:16 ` Neil Isaac
  2006-09-16 16:23   ` Meino Christian Cramer
  2006-09-16 18:29 ` Neil Bothwick
  2006-09-16 19:01 ` Alex Schuster
  2 siblings, 1 reply; 6+ messages in thread
From: Neil Isaac @ 2006-09-16 14:16 UTC (permalink / raw
  To: gentoo-user

On 9/16/06, Meino Christian Cramer <Meino.Cramer@gmx.de> wrote:
> Hi,
>
>  before I
>
>                 emerge -e system/world
>
>  my whole system I could allow root to open the X display by typing
>
>         xhost +local:root ???
>
>  . This seems to not to work any longer.
>
>  When starting ethereal/wireshark I get:
>
>         Gtk-WARNING **: cannot open display:
>
>  .
>
>  I searched the gentoo wiki for matches to combinations of
>
>         X11 root xhost
>
>  and such but didnt find anything else than the xhost command as shown
>  above.
>
>  Is there any way to allow root to use the X display when a user has
>  opened the session and su'ed to root ?
>
>  Thank you very much for any help in advance !

I am able to (for example) open xterm as root by doing:
sudo xterm -display :0.0

This tells xterm what xserver to run on (0.0 in my case) and also
works outside of Xorg.
Hope that helps.

-- 
Neil Isaac
isaac.neil@gmail.com
-- 
gentoo-user@gentoo.org mailing list



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [gentoo-user] xhost +local:root ???
  2006-09-16 14:16 ` Neil Isaac
@ 2006-09-16 16:23   ` Meino Christian Cramer
  0 siblings, 0 replies; 6+ messages in thread
From: Meino Christian Cramer @ 2006-09-16 16:23 UTC (permalink / raw
  To: gentoo-user, isaac.neil

From: "Neil Isaac" <isaac.neil@gmail.com>
Subject: Re: [gentoo-user] xhost +local:root ???
Date: Sat, 16 Sep 2006 14:16:43 +0000

> On 9/16/06, Meino Christian Cramer <Meino.Cramer@gmx.de> wrote:
> > Hi,
> >
> >  before I
> >
> >                 emerge -e system/world
> >
> >  my whole system I could allow root to open the X display by typing
> >
> >         xhost +local:root ???
> >
> >  . This seems to not to work any longer.
> >
> >  When starting ethereal/wireshark I get:
> >
> >         Gtk-WARNING **: cannot open display:
> >
> >  .
> >
> >  I searched the gentoo wiki for matches to combinations of
> >
> >         X11 root xhost
> >
> >  and such but didnt find anything else than the xhost command as shown
> >  above.
> >
> >  Is there any way to allow root to use the X display when a user has
> >  opened the session and su'ed to root ?
> >
> >  Thank you very much for any help in advance !
> 
> I am able to (for example) open xterm as root by doing:
> sudo xterm -display :0.0
> 
> This tells xterm what xserver to run on (0.0 in my case) and also
> works outside of Xorg.
> Hope that helps.
> 
> -- 
> Neil Isaac
> isaac.neil@gmail.com
> -- 
> gentoo-user@gentoo.org mailing list
> 

No, unfortunately not. 
Starting wireshark As normal user it works pretty well. 
But then the ethernet-card is not set to promiscous mode...

As root it does not work. And it does not root when startet with 

   sudo wireshark

. Damn....!

Any other ideas ? (I checked it with the option as mentioned above and
with the xhost settings.)

Keep hacking!
mcc

-- 
gentoo-user@gentoo.org mailing list



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [gentoo-user] xhost +local:root ???
  2006-09-16 12:12 [gentoo-user] xhost +local:root ??? Meino Christian Cramer
  2006-09-16 14:16 ` Neil Isaac
@ 2006-09-16 18:29 ` Neil Bothwick
  2006-09-16 18:55   ` Hans-Werner Hilse
  2006-09-16 19:01 ` Alex Schuster
  2 siblings, 1 reply; 6+ messages in thread
From: Neil Bothwick @ 2006-09-16 18:29 UTC (permalink / raw
  To: gentoo-user

[-- Attachment #1: Type: text/plain, Size: 478 bytes --]

On Sat, 16 Sep 2006 14:12:10 +0200 (CEST), Meino Christian Cramer wrote:

>  before I 
> 
> 		emerge -e system/world
> 
>  my whole system I could allow root to open the X display by typing
> 
>         xhost +local:root ??? 
> 
>  . This seems to not to work any longer.

emerge sux

Use sux instead of su.


-- 
Neil Bothwick

Programming Language: (n.) a shorthand way of describing a series of bugs
                      to a computer or a programmer.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [gentoo-user] xhost +local:root ???
  2006-09-16 18:29 ` Neil Bothwick
@ 2006-09-16 18:55   ` Hans-Werner Hilse
  0 siblings, 0 replies; 6+ messages in thread
From: Hans-Werner Hilse @ 2006-09-16 18:55 UTC (permalink / raw
  To: gentoo-user

Hi,

On Sat, 16 Sep 2006 19:29:14 +0100
Neil Bothwick <neil@digimed.co.uk> wrote:

> emerge sux
> 
> Use sux instead of su.

or, if using sudo, do the following:

append to /root/.bashrc:
----snip
[[ -n "$SUDO_USER" ]] && [[ -n "$DISPLAY" ]] && export XAUTHORITY=/home/$SUDO_USER/.Xauthority
----snip

to keep the DISPLAY environment variable set, /etc/sudoers should have
some line like this which tells it to not clean environment (in this
case for users in the wheel group, for which I allow passwordless
sudo'ing, too:
----snip
Defaults:%wheel !env_reset
----snip

-hwh
-- 
gentoo-user@gentoo.org mailing list



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [gentoo-user] xhost +local:root ???
  2006-09-16 12:12 [gentoo-user] xhost +local:root ??? Meino Christian Cramer
  2006-09-16 14:16 ` Neil Isaac
  2006-09-16 18:29 ` Neil Bothwick
@ 2006-09-16 19:01 ` Alex Schuster
  2 siblings, 0 replies; 6+ messages in thread
From: Alex Schuster @ 2006-09-16 19:01 UTC (permalink / raw
  To: gentoo-user

Meino writes:

>  my whole system I could allow root to open the X display by typing

>         xhost +local:root ???

>  . This seems to not to work any longer.

[...]

>  Is there any way to allow root to use the X display when a user has
>  opened the session and su'ed to root ?

On my system I can simply su and all is fine. But if a am logged in  
from remote via SSH I get the same problem when I su. "ssh -X  
root@localhost" should work, but I guess you just need to emerge sux  
and use it instead of su.

However, this works only if your user has X access and then becomes  
root - when opening a root shell in a text console, it does not work.  
In this case, your first solution seems to work fine for me.

        Alex
-- 
gentoo-user@gentoo.org mailing list



^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2006-09-16 19:07 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-09-16 12:12 [gentoo-user] xhost +local:root ??? Meino Christian Cramer
2006-09-16 14:16 ` Neil Isaac
2006-09-16 16:23   ` Meino Christian Cramer
2006-09-16 18:29 ` Neil Bothwick
2006-09-16 18:55   ` Hans-Werner Hilse
2006-09-16 19:01 ` Alex Schuster

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox