LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
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 07-01-2005, 09:16 AM   #1
Menestrel
Member
 
Registered: Oct 2003
Location: Bucharest
Distribution: Debian Sarge, Slackware Current, Ubuntu
Posts: 183

Rep: Reputation: 30
How can I kill all processes from a certain user ?


How can I kill all processes from a certain user ? also, I'd like to know how can I kill only a process from a certain user, and leave alone the same process that's running from another user.

Last edited by Menestrel; 07-04-2005 at 12:18 AM.
 
Old 07-01-2005, 09:34 AM   #2
Gkarfield
Member
 
Registered: Jul 2004
Location: Greece
Distribution: FreeBSD 6.2/widows[not 8 legs nor black]
Posts: 123

Rep: Reputation: 15
ps -ax | grep <username>

i supose. that is for BSD, it will work hopefully for llinux.
it gives the procceses nums. so right after u can kill'em
 
Old 07-01-2005, 09:39 AM   #3
Fritz_Monroe
Member
 
Registered: Nov 2004
Location: Maryland, USA
Distribution: Mint 13
Posts: 272

Rep: Reputation: 30
Here's the section in the Slackbook

My understanding of kill is that if you do a kill using the PID, it will kill that one process. If you do a kill with the name of the process, it will kill all instances of that process. Of course you have to be in as su for the second one. I think you can kill your own processes but nobody else's as a regular user.

F_M
 
Old 07-04-2005, 12:27 AM   #4
Menestrel
Member
 
Registered: Oct 2003
Location: Bucharest
Distribution: Debian Sarge, Slackware Current, Ubuntu
Posts: 183

Original Poster
Rep: Reputation: 30
I tought there was a easier way. For example, there are three users logged in my machine. And as root I want to "unlog" a certain user. Can this be accomplished by only one command ? must I kill each process of that user, because it seems time-consuming...
 
Old 07-04-2005, 01:10 AM   #5
Gkarfield
Member
 
Registered: Jul 2004
Location: Greece
Distribution: FreeBSD 6.2/widows[not 8 legs nor black]
Posts: 123

Rep: Reputation: 15
guh,

that was cough()

in freebsd always, u do ps -axj |grep <username>

was my fault to write only -ax.


then from the lots off processes

<user> 498 491 498 473 1 I+ v0 0:00.01 xinit
<user> 503 502 502 473 1 I v0 0:00.02 /bin/sh /usr/local/bin/startkde

if u kill this then u blow his window desktop
after this, his is in console
is there any processes stil active? something like login? kill it

have a nice day
 
Old 07-05-2005, 06:26 AM   #6
Menestrel
Member
 
Registered: Oct 2003
Location: Bucharest
Distribution: Debian Sarge, Slackware Current, Ubuntu
Posts: 183

Original Poster
Rep: Reputation: 30
true true
 
Old 07-05-2005, 09:53 AM   #7
Gkarfield
Member
 
Registered: Jul 2004
Location: Greece
Distribution: FreeBSD 6.2/widows[not 8 legs nor black]
Posts: 123

Rep: Reputation: 15
hi

I checked my computer......... and did not hapen that, I am the only user......... but if u find a process named 'X:0' onwned by root.............. :P. kill it and...

the last about 'login' iks only if he is in console. I have no linux at the moment, so I can not test it


cyaaaaaaaaaaa
 
  


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
Safe to kill all user: 'nobody' processes? lagu2653 Linux - Security 4 11-06-2005 06:28 PM
Gaim ate memory, couldn't kill processes. Oxagast Linux - Software 1 09-06-2005 03:55 PM
how to use kill to kill a batch of processes with same name? dr_zayus69 Linux - Software 2 09-03-2005 06:35 PM
HP-UX failing to kill some processes itumeleng Other *NIX 1 01-21-2005 08:14 PM
I want Linux source code for FAT file system in user readable form not in binary form ramya272 Linux - Newbie 5 02-05-2004 07:54 PM


All times are GMT -5. The time now is 08:22 PM.

Main Menu
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