LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 03-17-2006, 11:11 PM   #1
dkrysak
LQ Newbie
 
Registered: Sep 2004
Distribution: centos
Posts: 25

Rep: Reputation: 15
logout another ssh user


silly question...


when you have a remote shell on a system... and you get disconnected -- well the user is still logged in (as "top" shows) - How can I kill that rouge session?

Thanks!
 
Old 03-17-2006, 11:27 PM   #2
spooon
Senior Member
 
Registered: Aug 2005
Posts: 1,755

Rep: Reputation: 50
Here's what I usually do:
* run "ps -fu $USER"
* find the processes that correspond to the previous login session
* look for one that says "sshd: blahblah" or "bash" or something like that
* find its PID
* do "kill <that number>"
* repeat if that did not kill all of them
 
Old 03-17-2006, 11:42 PM   #3
Matir
LQ Guru
 
Registered: Nov 2004
Location: San Jose, CA
Distribution: Ubuntu
Posts: 8,507

Rep: Reputation: 124Reputation: 124
Also, this is usually unnecessary -- sessions will eventually time out on their own.
 
  


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
user logout kills wlan connection Cor_Tauri Linux - Wireless Networking 1 07-22-2004 07:42 PM
user with no logout megalomania Linux - General 3 04-12-2004 05:58 AM
ssh logout dellcom1800 Linux - Networking 3 01-13-2004 08:29 PM
User logout problem computergeek84 Linux - General 12 11-12-2003 07:35 AM
Logout an X user. squashblossom Linux - Networking 1 04-01-2003 10:22 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 09:53 PM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration