Connected to the server through ssh from the terminal. There was no operation for a period of time. When I tried to operate again, I found that it was stuck. I could only exit and reconnect.
What's going on? Did the connection disconnect itself?
我想大声告诉你2017-05-16 13:23:20
It seems that you are using a linux system
This is a security issue of linux. If no data is used within 60s, it will be automatically disconnected.
So you found the card owner~~~
Solution
#本地
#打开
sudo vim /etc/ssh/ssh_config
# 添加
ServerAliveInterval 50
ServerAliveCountMax 3
#远程
# 打开
sudo vim /etc/ssh/sshd_config
# 添加
ClientAliveInterval 50
ClientAliveCountMax 3