Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

At the office I have on the servers a vnc server running. In Windows I use putty to connect to the server, I log in and then use realvnc to see the desktop. But I cannot get this to work on Linux. I have done it in the past struggling but never again. What I have done is try to bind my localhost to the port 5901 and then to the port 5901 on the server machine

ssh -L localhost:5901:server.dog.com:5901 vass@server.dog.com

I am using the vnc client "remote desktop viewer". Best,

share|improve this question

1 Answer 1

up vote 2 down vote accepted

Try ssh -f -L 5901:localhost:5901 server.dog.com -N

share|improve this answer
    
Yes, it seems to be a syntax problem. 5901 will also only work if the vncserver was started on port 1 (e.g., 'vncserver :1') –  Barthelemy Oct 13 '10 at 20:08
1  
yes. 5901 is just from the example above. the first port is the local port, the second port is the remote port btw. –  txwikinger Oct 13 '10 at 20:17

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.