[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: cannot open display



On Thu, Jun 21, 2001 at 10:34:35AM -0700, G.LeeJohnson wrote:
>      Upon su -'ing from console to say use gedit it says cannot open display
> (for root)..reg user is fine....how do i fix this.
> 
So don't do that! Executing "su -" deletes als environment
variables (including DISPLAY). The are 3 Solutions to this
problem.

1. Don't use "su -", try "su". Your environment variables stay
the same. Unfortunately this can be a problem because normal
users don't have /sbin and /usr/sbin in their PATH.

2. Keep on using "su -". You just need to set DISPLAY and
XAUTHORITY explicitly.

3. Use sudo.

Cheers
Martin

-- 
... A booming voice says, "Wrong, cretin!", and you notice that you
have turned into a pile of dust.

Attachment: pgphapxnE8jCO.pgp
Description: PGP signature


Reply to: