root user, graphical programs

Polytropon freebsd at edvax.de
Fri May 15 08:45:16 UTC 2009


On Fri, 15 May 2009 10:38:34 +0200 (CEST), Pieter Donche <Pieter.Donche at ua.ac.be> wrote:
> No luck (yet)
> I tried both methods, (with xpdf as a graphical program)
> The first still gives 
> # xpdf
> Can't open display
> 
> The second method
> # xpdf
> No protocol specified
> Error: Can't open display:  :0.0
> 
> (after su -, $HOME was indeed /root)
> (in /root .Xauthority was changed/created, $DISPLAY is :0.0)

Maybe very unelegant, but has a chance to work:

	% su -
	Password:
	# cp /home/<your-username>/.Xauthority /root
	# setenv DISPLAY :0.0
	# xpdf

This assumes that csh is your dialog shell. If it's not, you may
need another syntax to change DISPLAY, e. g. for BASH.

It worked in the past, but who knows what still works in X... :-)


-- 
Polytropon
>From Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...


More information about the freebsd-questions mailing list