NASA666

不以物喜,不以己悲.
Posted on , viewed 547 times

ssh设置过期时间

1. vi ~/.ssh/config or vi /etc/ssh_config
2. 
    Host *
          ClientAliveInterval 120
          ClientAliveCountMax 720
3. explain
The first one configures the server to send null packets to clients each 120 seconds 
and the second one configures the server to close the connection if the client has been inactive for 720 intervals 
that is 720*120 = 86400 seconds = 24 hours
也就是设置过期时间为24小时.