The problem: your favorite internet connection has one or more NAT between you and your server, so your SSH connection freeze after some idle time…

The solution: add the following configuration directive to SSH configuration:

# add this line to the end of /etc/ssh/ssh_config
ServerAliveInterval 60


or for the personal configuration:

# add (create file if missing) this two lines
# to ~/.ssh/config
Host *
ServerAliveInterval 60

You can use your personal configuration file ~/.ssh/config or the system wide file /etc/ssh/ssh_config


Leave a Reply

Avatar placeholder

Your email address will not be published. Required fields are marked *