我正试图在我的KVM来宾上使用VNC,遵循以下指南:
http://blog.scottlowe.org/2013/08/21/accessing-vnc-consoles-of-kvm-guests-via-ssh/
这是我从主机上使用的ssh命令:
ssh -v -v -4 root@192.168.122.123 -L 7000:127.0.0.1:7000192.168.122.123是我客人的地址。
我可以使用上面的命令对我的来宾进行ssh,但是当我从我的主机上使用remmina并使用VNC协议将127.0.0.1:7000输入到服务器字段时,此消息将出现在我的来宾ssh连接上:
root@Kali:~# debug1: Connection to port 7000 forwarding to 127.0.0.1 port 7000 requested.
debug2: fd 8 setting TCP_NODELAY
debug2: fd 8 setting O_NONBLOCK
debug1: channel 2: new [direct-tcpip]
channel 2: open failed: connect failed: Connection refused
debug2: channel 2: zombie
debug2: channel 2: garbage collecting
debug1: channel 2: free: direct-tcpip: listening port 7000 for 127.0.0.1 port 7000, connect from 127.0.0.1 port 59293 to 127.0.0.1 port 7000, nchannels 3在我的主机上建立ssh连接后,端口7000的输出如下:
# sudo netstat -tunelp | grep LISTEN
tcp 0 0 127.0.0.1:7000 0.0.0.0:* LISTEN 1000 283620 8509/ssh在我的来宾的sshd_config中有以下几行:
GatewayPorts yes
AllowTcpForwarding yes
X11Forwarding yes有什么想法吗?
发布于 2015-11-05 13:36:42
在客户机上没有127.0.0.1:7000 (或0.0.0.0:7000)上的侦听器。使用以下方法检查来宾上的侦听器:
netstat -an|grep 7000查看像x.x.x.x:7000 0.0.0.0:* LISTEN这样的行是否存在,以及它绑定在哪个接口上。
GatewayPorts指令在此配置中没有意义,因为它只适用于远程端口转发。
https://unix.stackexchange.com/questions/241001
复制相似问题