Sunday, February 17, 2008

Config Idle Timeout for openSSH Fedora

With some ssh servers, you can config the time out in /etc/ssh/sshd_config like


However, the openssh shipped with Fedora doesn't support this option.
Two workarounds are:
  • Apply openssh watchdog patch
  • use TMOUT for shell
In /etc/profile
#set the idle timeout for ssh to 10minutes

readonly TMOUT

export TMOUT

Notice here, need to set the TMOUT to readonly, otherwise users can override it.