auto logout can be very usefull feature in some cases. First of all it will provide you more secure way of remote work. Another important thing is that if you have a multiuser environment with lots of lots of users, auto log out will help you to free some system resources.

Assumtion is simple. We want to log off user after some time of no activity.

I'm creating a simple bash script placed in /etc/profile.d/

Depending of your shell, paste this:


readonly TMOUT
export TMOUT


set autologout=5

Set the script executable and your done.

To get the same resoult but on the ssh server side, modify /etc/ssh/sshd_config

ClientAliveInterval 300
ClientAliveCountMax 0

Quick and easy, but can save your life ;)