Remote Desktop through multiple ssh tunnels (A - B - C)
You will only need one tunnel, since there is only one machine in the middle.
-
Connect from A to B using SSH, with a local tunnel from
:<portX>
to<machineC>:3389
.Depending on your SSH client:
OpenSSH –
ssh -fN -L<portX>:<machineC>:3389 <machineB>
-
PuTTY – source port
<portX>
, destination<machineC>:3389
, type local.PuTTY also accepts the same
-L
option when run from command line.
-
Connect from A to
localhost:<portX>
using Remote Desktop.-
Windows Remote Desktop – enter
localhost:<portX>
in the Computer box.Or run
mstsc /v localhost:<portX>
.
-
Here <portX>
is any port between 1024-65535, and not yet in use by machine A.