Try man sshd_config
and man ssh_config
.
ClientAliveInterval
Sets a timeout interval in seconds after which if
no data has been received from the client, sshd(8) will send a message
through the encrypted channel to request a response from the client.
The default is 0, indicating that these messages will not be sent to
the client. This option applies to protocol version 2 only.
and
ServerAliveInterval
Sets a timeout interval in seconds after which if no data has been
received from the server, ssh(1) will send a message through the
encrypted channel to request a response from the server. The default
is 0, indicating that these messages will not be sent to the server,
or 300 if the BatchMode option is set. This option applies to
protocol version 2 only.
I would avoid using,
echo "ClientAliveInterval 60" | sudo tee -a /etc/ssh/sshd_config
personally. The seems like a clunky and risky way of updating sshd_config. I would just sudo vi
it, and see what the existing setting for ClientAliveInterval is, if present.
Finally, I believe you're misreading what those settings do. They don't drop the connection after that time, they send a keep alive message after that time to encourage both ends of the connection, and any firewalls in between, to believe the connection is still active and should be kept open.