From: Chris Davies on 24 Jun 2010 10:05 Todd<todd(a)invalid.com> wrote: > If I wanted to display my entire desktop, in a single > window, in the style of VNC, is there a way for ssh > to do this? On 06/21/2010 03:24 PM, Chris Davies wrote: > Ssh can't do this, but what it can do is to tunnel (X forward) a VNC/X > server to your display. [..] > Let me know and I'll post an example Todd <todd(a)invalid.com> wrote: > I we appreciate it. OK. There are several parts to this. For the purposes of this conversation, consider V to be the device on which you want to view the remote screen, and R to be the device from which the screen is derived. (I'm deliberately avoiding the terms "client" and "server" here.) @ R 1 Enable vino (gnome) or the equivalent remote screen service (kde). If you don't know how to do this, replace "5900" with "5910" throughout the remainder of this worked example. If you definitely aren't running gnome or kde you can use this next command instead, which will open a listener with no password, but accessible only to the local system on port 5900 (use -help to see other options): x0vncserver -rfbport=5900 -localhost -securitytypes=none @ V 2 Connect to R and open a tunnel (over the encrypted session) to the listening VNC server on R. Port 5910 on V maps to port 5900 on R: ssh -fN -L localhost:5910:R:5900 R 3 Now connect, using vncviewer or your preferred alternative, to the 10th *local* VNC port (i.e. port 5910), which is actually being forwarded to the remote port 5900: vncviewer -viewonly :10 For bonus points. If you're normally logged on to V, you can merge steps 1 and 2 into a single (long) command, but I wouldn't recommend this until you have worked out what's really going on: ssh -f -L localhost:5910:R:5900 R x0vncserver -rfbport=5900 -localhost -securitytypes=none Chris
From: Todd on 24 Jun 2010 13:36
> For bonus points. If you're normally logged on to V, you can merge steps 1 > and 2 into a single (long) command, but I wouldn't recommend this until > you have worked out what's really going on: > > ssh -f -L localhost:5910:R:5900 R x0vncserver -rfbport=5900 > -localhost -securitytypes=none > > Chris Thank you! -T |