[TriLUG] X Sessions
Andrew Perrin
andrew_perrin at unc.edu
Fri Jan 25 13:30:07 EST 2002
VNC certainly seems like overkill here - he's just trying to tunnel an X
session through ssh.
I think the problem is setting display to [local system]:0.0, which
*bypasses* the ssh tunnelling and attempts to send the X display from the
remote host to the local display via tcp. Quite rightly, the local
machine rejects this since there's no permission for the remote machine to
display locally.
Generally, when you've sshed into a remote machine with the -X (tunnel X
packets) flag, DISPLAY on the remote host gets set correctly without
having to set it manually. It can be confusing, though -- the DISPLAY
variable should actually be set to:
remotehost:n.0
where remotehost is the machine *running* the app (or, technically, the
one tunnelling the packets) and n is an integer > 0. The ssh server on
the remote machine intercepts packets destined for a local X server
numbered > 0 (server 0 is the local X display) and tunnels them
appropriately.
For example, since I know you're (Jeff) at UNC, this is from an ssh
session to isis:
aperrin at hm269-26876:~/afshome/classes/soc10/spring02$ ssh -X isis
...
aperrin at login2 ~ >echo $DISPLAY
login2.isis.unc.edu:13.0
note that DISPLAY is set to isis:13.0; the ssh server on isis takes care
of taking packets that local sessions send to isis:13.0 and tunneling them
to my machine.
Hope this helps.
----------------------------------------------------------------------
Andrew J Perrin - andrew_perrin at unc.edu - http://www.unc.edu/~aperrin
Assistant Professor of Sociology, U of North Carolina, Chapel Hill
269 Hamilton Hall, CB#3210, Chapel Hill, NC 27599-3210 USA
On Fri, 25 Jan 2002, Vestal, Roy L. wrote:
> vnc. It works great.
> www.uk.research.att.com/vnc
>
>
> -----Original Message-----
> From: Jeff Bollinger [mailto:jeff at email.unc.edu]
> Sent: Friday, January 25, 2002 11:05 AM
> To: TriLUG
> Subject: [TriLUG] X Sessions
>
>
> What do I need to change to allow myself to get an X window (xterm) from
> a remote Linux box to my local Linux box (already running X)? I have
> X11 forwarding set on the remote box in the sshd_config file, but I get
> the following error after I run export DISPLAY="[local system]:0" and
> try to run an X app:
>
>
> Xlib: connection to "[local system]:0.0" refused by server
> Xlib: Client is not authorized to connect to Server
> xterm Xt error: Can't open display: [local system]:0--
>
> Thanks,
>
> Jeff
>
> Jeff Bollinger
> University of North Carolina
> IT Security Analyst
> 105 Abernethy Hall
> mailto: jeff_bollinger at unc dot edu
>
> _______________________________________________
> TriLUG mailing list
> http://www.trilug.org/mailman/listinfo/trilug
> _______________________________________________
> TriLUG mailing list
> http://www.trilug.org/mailman/listinfo/trilug
>
More information about the TriLUG
mailing list