当前位置: 首页 > 工具软件 > Foreign LINUX > 使用案例 >

修改sshd_config解决 xshell 链接 linux 错误 connection closed by foreign host

洪博涛
2023-12-01

用xshell连接服务器总是报错 connection closed by foreign host,害的我一个程序每次都跑到一半


解决方案是:    


sudo vim /etc/ssh/sshd_config
添加两行:
ClientAliveInterval 60
ClientAliveCountMax 3
sudo /etc/init.d/ssh restart
 类似资料: