LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices



Reply
 
Search this Thread
Old 10-04-2008, 12:35 PM   #1
msivadass
LQ Newbie
 
Registered: Nov 2007
Location: India
Distribution: RHEL
Posts: 26

Rep: Reputation: 15
Question Enable connection timed out option in ssh


I want know how to enable the connection timed out options in ssh.
For example I want disconnect the users, whose are logged my sever by using ssh and the connections are idle more than 10 Minutes.

How we can do this? Pls any one help me.......?
 
Old 10-04-2008, 01:28 PM   #2
robertjinx
Member
 
Registered: Oct 2007
Location: Prague, CZ
Distribution: RedHat / CentOS / Ubuntu / SUSE / Debian
Posts: 587

Rep: Reputation: 58
Try ClientAliveCountMax and ClientAliveInterval. This settings you can check out in "man sshd_config" they are explain there and how to set them. I have set ClientAliveCountMax to 60, but you can do it as its best for you.

Cheers!
 
Old 10-05-2008, 02:44 PM   #3
MensaWater
Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 6,028
Blog Entries: 5

Rep: Reputation: 791Reputation: 791Reputation: 791Reputation: 791Reputation: 791Reputation: 791Reputation: 791
Or you could do it for all logins (not just ssh) by adding it to the system profile for the specific shell.

e.g. TMOUT=600 in /etc/bashrc for bash, or in /etc/profile for sh, and ksh. There is a similar timeout available for csh in /etc/login.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
ssh: connection to host port: 22: Connection timed out lost connection cucolin@ Linux - Server 4 11-22-2011 07:15 AM
sendmail - Connection timed out [dsn=4.0.0 stat=Deferred: Connection timed out] ananthak Linux - Software 0 04-24-2007 08:28 AM
SSH Connection timed out davhak Linux - Networking 13 03-18-2007 04:41 AM
SuseFirewall2 and external SSH access connection timed out usmanaziz Linux - Distributions 1 09-03-2004 04:15 AM
ssh: Connection timed out. [from school] nixel Linux - Networking 2 05-19-2004 01:21 PM


All times are GMT -5. The time now is 10:23 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration