Hel with X11 and remote display...

Matthew Seaman m.seaman at infracaninophile.co.uk
Mon May 24 12:27:44 BST 2004

Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Mon, May 24, 2004 at 12:02:15PM +0100, Pete French wrote:
> I asked this on the 'net and got zero replies for some reason. I am
> tryingm to do something very simple - remote display an app. For
> example 'xterm -display dogbert:0.0'
> I do 'xhost +' on the X server. but it still cant connect.
> Interestingly I also observer that 'xterm -display localhost:0.0'
> doesnt even work!
> err, help! have they done something odd to X since the last time I
> tried this (a number of years ago - I normally use ssh tunneling
> these days).

The X server doesn't open ports on the network by default nowadays.
Check with netstat and see if anything is listening on port 6000 or so
to confirm this.  Local traffic -- ie. with DISPLAY=3D:0.0 goes via the
unix domain socket in /tmp.

To start up X with the networking stuff turned on:

     # startx -listen_tcp

or if you're an xdm(8) user, edit /usr/X11R6/lib/X11/xdm/Xservers and
remove the '-nolisten tcp' flags from the server command line, and hit
Ctrl-Alt-Backspace to restart the server.

Use xauth(1) rather than xhost to authorize a remote application to
display on your desktop -- use 'xauth generate' or 'xauth extract' to
produce the necessary magic cookie, copy it across to the remote
machine by whatever means seems best, and then use 'xauth add' or
'xauth merge' to add it to ~/.Xauthority on the remote end.

Of the two choices -- turning on X's networking capabilities, or using
ssh(1) to tunnel X-protocol traffic -- using ssh is much the most
preferable.  Running X in clear across the network is about as bad as
using rsh or telnet unencrypted: don't do it anywhere you might have
people snooping traffic.



Dr Matthew J Seaman MA, D.Phil.                       26 The Paddocks
                                                      Savill Way
PGP: http://www.infracaninophile.co.uk/pgpkey         Marlow
Tel: +44 1628 476614                                  Bucks., SL7 1TH UK

Content-Type: application/pgp-signature
Content-Disposition: inline

Version: GnuPG v1.2.4 (FreeBSD)



More information about the Ukfreebsd mailing list