SUMMARY2: ps all kill all

From: pelicancomputers <rfransix_at_yahoo.com>
Date: Mon Mar 04 2002 - 16:36:01 EST
thanks ian and everyone, here's other methods too:

kill `ps -ef | grep process | awk '{print $2}'` 
or
kill -9 `ps -aef | grep processes | grep -v grep | awk
'{print $2|}'` 
or
'ps ef | grep  <whatever> | awk '{print $1} | xargs
kill -9' 
or
ps -ef | grep [p]rossess | xargs kill -9 
or

for i in `ps -ef |grep <process> |grep -v grep|awk
'{print $2}'`
do
kill $i
done 


--- Ian Clements <ian@artisan.com> wrote:
> 
>  The problem with #2 is that you may inadvertently 
> kill the process you are running to look for the 
> others :)
> 
> 	Ian
> 
> 
> -----Original Message-----
> From: pelicancomputers [mailto:rfransix@yahoo.com]
> Sent: Monday, March 04, 2002 12:19 PM
> To: pelicancomputers; sunmanagers@sunmanagers.org
> Subject: SUMMARY: ps all kill all
> 
> 
> A.
> Excellent.
> 
> 1. pkill
> 2. kill `ps -ef | grep process | awk '{print $2}'`
> 
> thanks again.
> 
> Original Post:
> if i have a thousand processes running that i can,
> ps -ef | grep
> for...
> how can i kill them all?
> 
> ps -ef | grep process | kill $1
> or
> ?
> 
> thanks.
> Yahoo! Sports - sign up for Fantasy Baseball
> http://sports.yahoo.com
> _______________________________________________
> sunmanagers mailing list
> sunmanagers@sunmanagers.org
>
http://www.sunmanagers.org/mailman/listinfo/sunmanagers
Yahoo! Sports - sign up for Fantasy Baseball
http://sports.yahoo.com
_______________________________________________
sunmanagers mailing list
sunmanagers@sunmanagers.org
http://www.sunmanagers.org/mailman/listinfo/sunmanagers
Received on Mon Mar 4 15:37:09 2002

This archive was generated by hypermail 2.1.8 : Thu Mar 03 2016 - 06:42:35 EST