Session timeout setting in server


 
Thread Tools Search this Thread
Operating Systems Solaris Session timeout setting in server
# 1  
Old 03-24-2012
Session timeout setting in server

Hi All

I need to set timeout of login session of a user if a user is idle for some time.

I know the TMOUT setting but it work with only BASH & KORN shell only as I need to set for Bourne shell also. I am trying to put "ClientAliveInterval 300" in sshd_config & restart or refreshing the ssh service. But after idling for more than 300 seconds,Still user is not automatically logout.

Where I am missing please help me this regards
# 2  
Old 03-24-2012
You gotta set ClientAliveCountMax=0

See what man sshd_config says:
Code:
ClientAliveCountMax

         Sets the number of client  alive  messages  (see  Clien-
         tAliveInterval,  below)  that  can  be sent without sshd
         receiving any messages back from  the  client.  If  this
         threshold  is  reached  while  client alive messages are
         being sent, sshd disconnects the client, terminating the
         session.  It is important to note that the use of client
         alive messages is very  different  from  KeepAlive  (see
         below).  The  client alive messages are sent through the
         encrypted channel and therefore are not  spoofable.  The
         TCP  keepalive option enabled by KeepAlive is spoofable.
         The client alive mechanism is valuable when a client  or
         server  depend  on  knowing when a connection has become
         inactive.

         The default value is 3. If  ClientAliveInterval  (below)
         is  set  to  15,  and ClientAliveCountMax is left at the
         default, unresponsive ssh clients are disconnected after
         approximately 45 seconds.

This User Gave Thanks to admin_xor For This Post:
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. Linux

Is it possible to set timeout on Linux screen session

Hello friends, I work on Linux servers via SSH (putty) and run "screen" to preserve my sessions so I can attach/detach them at anytime I wish without losing the connectivity/process disruption which is working perfectly fine. As my team members also have root access to those servers, it is... (7 Replies)
Discussion started by: prvnrk
7 Replies

2. AIX

Set timeout value for ssh session to HMC?

Friends, Could anyone let me know - how to set the timeout value for ssh session to HMC? My HMC version is -- V7R7.4.0. I'm sure the version doesn't have anything to do with it. Thanks, -- Souvik (2 Replies)
Discussion started by: thisissouvik
2 Replies

3. Shell Programming and Scripting

Setting a Timeout

Hi I'm writing a script which based on a condition, restarts a set of servers. The problem I'm facing is, say if one of the server is down, my script stops there and fails to proceed. How can I ensure to set a timeout value on that script, so when the server is not reachable, the script should... (2 Replies)
Discussion started by: mathbalaji
2 Replies

4. UNIX for Dummies Questions & Answers

Putty Session Timeout

Hi, I had add the following line into .profile and .bash_profile for the timeout session to avoid putty close automatically : timeout=10800 However, i still keep encounter session time out every after 60 seconds. Can anyone please help advice. Many Thanks! (2 Replies)
Discussion started by: wancy
2 Replies

5. AIX

Unix session timeout?

We recently moved servers to a new data center, and now we're experiencing user sessions timing out after non-activity. We didnt experience this before, or know of any timeout settings that may have been changed. Any things I can check out on the server? (3 Replies)
Discussion started by: NycUnxer
3 Replies

6. Shell Programming and Scripting

session timeout for shell script

I am executing test.sh script. But this script takes lot of time and in the meantime the shell timeouts without completing the script. Is there any command which will continue processing the script. Thanks (3 Replies)
Discussion started by: infyanurag
3 Replies

7. UNIX for Dummies Questions & Answers

Find out excat timing of ftp control session timeout

We are facing difficulties in ftp'ing large files.For large file transfer using FTP, the control session gets timed out where as the the data session is active and transfers the file completely. Is there a way to make the control session active as long as data session? How to find the control... (1 Reply)
Discussion started by: rocker
1 Replies

8. Solaris

Solaris 8 - Session timeout

Hi, anyone Audit requirement to set the Solaris 8 server session timeout to 180 sec , Please advice how can I do it .... Thanks (3 Replies)
Discussion started by: civic2005
3 Replies

9. UNIX for Dummies Questions & Answers

telnet session timeout

hi, we can set something such that if the user has been idle for a while, it will auto disconnect. where to do so? thanks (6 Replies)
Discussion started by: yls177
6 Replies
Login or Register to Ask a Question