SSH Client Timeout

SSH Client Timeout

SSH allows administrators to set a timeout to log users out automatically after a certain period of idle time.
user@www# vi /etc/ssh/sshd_config
Find ClientAliveInterval and set to 300 (5 minutes) as follows:
ClientAliveInterval 300
ClientAliveCountMax 0
ClientAliveInterval sets a timeout interval in seconds after which if no data has been received from the client, secshd will send a message through the encrypted channel to request a response from the client. ClientAliveCountMax sets the number of client alive messages (above) which may be sent without secshd receiving any messages back from the client. Save and close the file. Restart sshd:
user@www# /etc/init.d/sshd restart
and enjoy.


Leave a Reply

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

My new Snowflake Blog is now live. I will not be updating this blog anymore but will continue with new contents in the Snowflake world!