vnc 远程连接云服务器
For my case, I need to bypass one intermediate server so that I can connect to the remote server with vnc. For example, there are two servers (s1, s2) except my local PC and I have to login to s1 so that I can login s2 from my local PC. However, now, I need to use vnc to connect to s2 from my local PC.
就我而言,我需要绕过一台中间服务器,以便可以通过vnc连接到远程服务器。 例如,除了本地PC外,还有两台服务器(s1,s2),我必须登录到s1,这样我才能从本地PC登录到s2。 但是,现在,我需要使用vnc从本地PC连接到s2。
In s2 side:
在s2端:
$ vncserver :1
In local PC:
在本地PC中:
$ssh -L 5901:10.80.1.1:5901 -l username -f -N afsconnect2.njit.edu
$ vncviewer localhost:590x
Note:
1, afsconnect2.njit.edu is s1 server.
2, 10.80.1.1 is s2 server.
3, Remember to change to vnc session number if “:1” has been taken.
注意:
1,afsconnect2.njit.edu是s1服务器。
2,10.80.1.1是s2服务器。
3,如果已使用“:1”,请记住更改为vnc会话号。
Great tips!
很棒的提示!
I guess the ‘590x’ should be ‘5901’ as the vncserver is created with ‘:1’.
我猜想“ 590x”应该是“ 5901”,因为vncserver是用“:1”创建的。
And for the background info, the tip is using the “Local port forwarding” function of SSH tunnels (an intro at http://www.systutorials.com/39648/port-forwarding-using-ssh-tunnel/ ).
对于背景信息,技巧是使用SSH隧道的“本地端口转发”功能( http://www.systutorials.com/39648/port-forwarding-using-ssh-tunnel/上的介绍)。
Yes, It should be ‘5901’. I have fixed it. Thank you.
是的,应该是“ 5901”。 我已经解决了。 谢谢。
翻译自: https://www.systutorials.com/how-to-use-vnc-to-connect-remote-server-with-gui-desktop/
vnc 远程连接云服务器