更改服务器端
sudo vim /etc/ssh/sshd_config
#config
TCPKeepAlive yes
ClientAliveInterval 30
ClientAliveCountMax 6
#restart
/sbin/service sshd restart
sudo vim /etc/ssh/sshd_config
#config
TCPKeepAlive yes
ClientAliveInterval 30
ClientAliveCountMax 6
#restart
/sbin/service sshd restart