问题描述
配置ssh端口转发.
客户端连接:
ssh root@49.234.100.17 -v -C -L 127.0.0.1:8891:10.0.1.3:8080
客户端连接端口:
curl http://127.0.0.1:8891/
报错如下:
curl: (56) Recv failure: Connection reset by peer
服务端返回报错如下:
channel 2: open failed: administratively prohibited: open failed
debug1: channel 2: free: direct-tcpip: listening port 8891 for 10.0.1.3 port 8080, connect from 127.0.0.1 port 37200 to 127.0.0.1 port 8891, nchannels 3
vim /etc/ssh/sshd_config
修改如下配置:
PermitTunnel yes