[PLUG] Opening X app when su root

Derek Loree drl at drloree.com
Sat Sep 18 10:37:02 PDT 2004


On Sat, 2004-09-18 at 07:53, Rich Shepard wrote:
>    I know there's a way to specify the X host but I can't find it in my saved
> references. Here's the situation:
> 
>    Logged in as a user and running the X Window System. In a virtual terminal
> I 'su -' to root. Now I want to run the OpenOffice.org's 'spadmin' program
> so I can add fonts to what OO.o sees. The X server responds that it cannot
> open the display.

Try the 'su' command without the "-".  This will give you root
privileges without the root environment.  Since your environment won't
change, 'spadmin' should fire right up. 
> 
>    Is my only option to log out, then back in as root and startx from that
> login? There must be a linux-guru way but I cannot find it. Pointers
> appreciated.
> 
Another option is to change to a console, login as root, then run
'startx :2'.  This will start another X-server on <ctrl><alt><F8>.

Good Luck,

Derek Loree





More information about the PLUG mailing list