LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 08-27-2002, 08:33 PM   #1
def1014
Member
 
Registered: Apr 2002
Distribution: Red Hat 6.1,7.2,7.3 Mandrake 8.1,8.2
Posts: 48

Rep: Reputation: 15
Angry Zombies


Does anyone know where to find a script to kill zombie processes on Red Hat 7.2? Thanks...
 
Old 08-28-2002, 12:07 PM   #2
Sixpax
Member
 
Registered: Mar 2002
Distribution: Mandrake 8.1
Posts: 386

Rep: Reputation: 31
#!/bin/bash
ps -el | while read LINE; do
ST=$(echo $LINE | cut -d" " -f2)
PID=$(echo $LINE | cut -d" " -f4)
if [ "$ST" = "Z" ]; then
kill -9 $PID
fi
done
 
  


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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Beware of Zombies floppywhopper General 1 08-27-2005 07:23 AM
system() calls causing Zombies...!!! expert gothrog Linux - Networking 4 03-17-2005 12:38 PM
zombies???? rasejo Linux - General 4 08-27-2002 01:12 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 01:21 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration