[H-GEN] remote display of programs
michael at anthon.net
Sun May 26 07:38:02 EDT 2002
[ Humbug *General* list - semi-serious discussions about Humbug and ]
[ Unix-related topics. Posts from non-subscribed addresses will vanish. ]
There is a couple of ways to do this using ssh.....
1. Chain some port forwarding ssh sessions between the machines like this
(Port 6002 picked randomly... sortof)
host1> ssh user at host2 -R 6002:127.0.0.1:6002
host2> ssh user at host3 -R 6002:127.0.0.1:6002
host3> ssh user at host4 -R 6002:127.0.0.1:6002
host4> export DISPLAY=127.0.0.1:2
2. Cascade ssh session from one machine to the next in such a way that
you can create a new session from you rlocal host to the next one in the
sequence, then use the final one to do X forwarding like so
host1> ssh user at host2 -L 1200:host3:22
host1> ssh user at 127.0.0.1 -p 1200 -L 1201:host4:22
host1> ssh user at 127.0.0.1 -p 1201 -X
The first one is pretty straight forward (I think) and requires only a
single shell on host 1, the second one is a little more complicated and
requires 3 shells on host1 (actually, I think it can be done with just 1 but
I'm not quite sure about that).
The first command in the second method establishes a tunnel from host1 port
1200 to host3 port 22, which then allows you to establish a second similar
tunnel from host1 to host4 whcih then allows you to create an ssh session
directly (in an indirect kinda way) with host 4 and enable X forwarding.
I have done very similar things myself but normally only via one proxy.
There are, of course, other options... VNC is one as someone suggested
however this would require a very similar setup to provide a tunnel between
host4 and host1. Another possibilty would be one of the VPN packages
 For want of better terms
* This is list (humbug) general handled by majordomo at lists.humbug.org.au .
* Postings to this list are only accepted from subscribed addresses of
* lists 'general' or 'general-post'. See http://www.humbug.org.au/
More information about the General