Tips and Tricks about SSH client
How to keep SSH connection alive
Example:
ssh -o ServerAliveInterval=60 username@hostname
We also could update the SSH config file to keep alive for all connections.
# in file:
# - ~/.ssh/config
Host *
ServerAliveInterval 60
We could also configure ~/.bash_profile for this:
alias ssh-qa-east="ssh -o ServerAliveInterval=60 <user>@<ip>"
References: