Re: How do I recognize a zombie process?


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers Re: How do I recognize a zombie process?
# 1  
Old 08-21-2008
Tools Re: How do I recognize a zombie process?

Hey Guys,

I am not really new to Unix/Linux however I was never taught how to spot a zombie process. I used top to check out the processes I was running and how the resources were looking and in the upper right it said 1 zombie, I have attached a jpeg of it. Thank you in advance for your help.

Michael
Re: How do I recognize a zombie process?-zombie1jpg
# 2  
Old 08-21-2008
Example:
root 6365 6353 0 0:00 <defunct>
# 3  
Old 08-21-2008
Most ps implementations show it as <defunct>.
So you could simply
Code:
$ ps -ef | grep defunct

With Linux ps you can also go after the state like such, provided there are any zombies
which well behaved programs simply don't produce
Code:
$ ps -e -o pid= -o state=|awk '$2=="Z"{print$1}'|tr \\040 ,|xargs ps -fp

# 4  
Old 08-22-2008
MySQL

Quote:
Originally Posted by buffoonix
Most ps implementations show it as <defunct>.
So you could simply
Code:
$ ps -ef | grep defunct

With Linux ps you can also go after the state like such, provided there are any zombies
which well behaved programs simply don't produce
Code:
$ ps -e -o pid= -o state=|awk '$2=="Z"{print$1}'|tr \\040 ,|xargs ps -fp

Thank you very much that helps a ton I will use these and see what I come up with.

Michael
# 5  
Old 08-23-2008
get the proccess id, then pkill it

$ ps aux | awk '$8=="Z" { print $2 }'

Good luck
 
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Red Hat

How to get rid of zombie process?

Hi, How to get rid of Zombie Process, Kill -9 PID does not seem to be permanent solution, your help will be Appreciated. Thanks (11 Replies)
Discussion started by: szs
11 Replies

2. UNIX for Advanced & Expert Users

Zombie process

What is the overhead associated with zombie process?Is it running out of process-ID?:confused: Since some information is stored in process table.. Thanks in Advance (4 Replies)
Discussion started by: jois
4 Replies

3. UNIX for Dummies Questions & Answers

Zombie process question

Hey guys, So i did some research on the site but previous posts answered most of my questions about zombie processes but I have one question that didnt seem to get addressed "how do you find the parent or parent ID of a zombie process so you can kill it?" I know p -kill doesnt always just... (6 Replies)
Discussion started by: kingpin007
6 Replies

4. Solaris

How to Kill Zombie Process

Dear Bos, I have one server,everday if I check with command TOP always present zombie,like below: last pid: 4578; load averages: 0.15, 0.11, 0.13 07:56:15 298 processes: 295 sleeping, 1... (10 Replies)
Discussion started by: fredginting
10 Replies

5. AIX

zombie process

Is there an equivilant to the preap command in AIX that would allow me to get rid of a zombie process. I am new to AIX, moving over from Solaris and in the past I have been able to preap the pid on the defunct process to clean them up. I have looked around and the best I can see is that it may... (3 Replies)
Discussion started by: sboots
3 Replies

6. Solaris

zombie process

dear friends, in an interview they asked me what is zombie process. how we can identifying these process.if can you kill all zombie process. (8 Replies)
Discussion started by: sijocg
8 Replies

7. Shell Programming and Scripting

Zombie process

Hi I need help because I don't know if it is possible to add a find inside a cat. like I have a file with the pid of the process that use to became zombie. And I have the same pid stored in the var (pid1) now, I have no clue how to check if the the find finds the pid or even if it's... (2 Replies)
Discussion started by: ruben.rodrigues
2 Replies

8. Linux

zombie process

Hi What is the command to find only the zombie processes?? How to write the code in C to fetch the no. of zombie processes?? Thanx (5 Replies)
Discussion started by: jeenat
5 Replies

9. UNIX for Advanced & Expert Users

Zombie process

I would like to create a zombie process so that I can test monitoring software functionality. Any techniques? (2 Replies)
Discussion started by: swhitney
2 Replies

10. UNIX for Dummies Questions & Answers

Zombie process

How do i kill a zombie process. Is it that only root can kill a zombie process. (8 Replies)
Discussion started by: orca
8 Replies
Login or Register to Ask a Question