创建一个ssh配置文件: vi ~/.ssh/config
vi ~/.ssh/config
写入以下内容:
Host * ServerAliveInterval 120 TCPKeepAlive no