Golfreeze.packetlove.com: Life style of Golfreeze Canon400D Family kammtan.com Jazz Freebsd Unix Linux System Admin guitar Music

All about unix linux freebsd and FAQ for Packetlove.com Web hosting , Mail hosting , VoIP + IP PBX server => all application on unix knowledges by golfreeze => Topic started by: golfreeze on เมษายน 12, 2017, 11:40:10 AM

Title: จะแก้ไขปัญหา ssh หลุดบ่อยยังไง โดยปรับเวลา ServerAliveInterval
Post by: golfreeze on เมษายน 12, 2017, 11:40:10 AM
Open the /etc/ssh/ssh_config file.

sudo nano /etc/ssh/ssh_config
and add the following line to the end of the file:

ServerAliveInterval 60
What this option does is to send a null packet to the server at every 60 seconds (of inactivity) to keep the SSH connection alive. You can experiment with the value, setting it to either higher or lower, depending on your system configuration. A value of 60 is a good starting point to start the experimentation.

เสร็จทำการ reload ssh 1 รอบครับ
systemctl reload ssh