|
|
Question : Problem: Tunnel VNC through SSH - error "cannot listen to port: 5901 "
|
|
I am trying to VNC to a remote Suse Linux box, and tunnel the VNC session through SSH.
SSH works fine on it's own.
Here is what I have tried: ssh -L 5901:remoteserver:5901 me@remoteserver Password: channel_setup_fwd_listener: cannot listen to port: 5901 Could not request local forwarding. Last login: Wed Apr 2 23:16:24 2008 from my-ip-address me@remoteserver:~>
I checked the open ports on the remote server with nmap and 5901 is there: 5901/tcp open vnc-1
There is no software firewall running on the server or my pc. How can I get this VNC setup working?
|
Answer : Problem: Tunnel VNC through SSH - error "cannot listen to port: 5901 "
|
|
Woohoo! All fixed!!! The trick was this: I had to use localhost instead of remoteserver as follows ssh -L 5903:localhost:5901 me@remoteserver
As it turns out, for the tunnel, the hostname between the :'s is relative to the server. The client only resolves the "SSHserver".
For the points, it looks like a joint effort: ravenpl - In hindsight, you were on the right track, but lacked a full explanation and I wasn't sure where to go until Barthax made it explicit with an example. I chipped in with the final hurdle.
|
|
|
|