How to Kill Zombie Process


 
Thread Tools Search this Thread
Operating Systems Solaris How to Kill Zombie Process
# 8  
Old 05-08-2010
Many of you are not understanding. jlliagre is correct but not getting through somehow.

A zombie process merely clogs up a process slot in the kernel process entry table. It has no resources tied up. It is waiting to return status to a parent (called reaping), and the parent has not called wait(). Some negligent parents never call wait.

If a parent exits before calling wait then the init process reaps the orphaned child process. It may spend a short while as a zombie.

[opinion]

I personally think the guy who created the idea of calling those processes a 'zombie' was creative and totally misguided. We all know that somehow zombies are evil. Therefore you have to get rid of them They must be vermin. Kill them all!

This is a case of the name providing non-existent negative attributes to something.
Zombies are okay. They are not as evil as the name implies.

[/opinion]

What you really need to do: fix the bad programming that creates them. Or hire good programmers.

Zombies DO NOT respond to signals because they lack the process context to do so.
Kill -9 sends a signal.

Commands like preap just remove them from the internal kernel table by forcing the naughty parent process to call wait. Plus, it is OKAY to have a few zombies. It gives some programmers a chance to worry about something harmless, and bug the sysadmin.
Sysadmins love to be bugged by users.

When you have loads of zombies and they persist for days, it is time to rewrite code, or spend all day calling preap (on Solaris).
These 2 Users Gave Thanks to jim mcnamara For This Post:
# 9  
Old 05-08-2010
I am employed, with a mortgage...and an endless commute...another form of zombie. Not necessarily evil...but unable to respond to signals in many, many ways. (Just ask the wife if my ears work...)

Very good explanation, jim_mcnamara. Perhaps we've met another form of the useless use of cat? Killing the dead?
# 10  
Old 05-08-2010
Network

Quote:
Originally Posted by jim mcnamara
Many of you are not understanding. jlliagre is correct but not getting through somehow.

A zombie process merely clogs up a process slot in the kernel process entry table. It has no resources tied up. It is waiting to return status to a parent (called reaping), and the parent has not called wait(). Some negligent parents never call wait.

If a parent exits before calling wait then the init process reaps the orphaned child process. It may spend a short while as a zombie.

[opinion]

I personally think the guy who created the idea of calling those processes a 'zombie' was creative and totally misguided. We all know that somehow zombies are evil. Therefore you have to get rid of them They must be vermin. Kill them all!

This is a case of the name providing non-existent negative attributes to something.
Zombies are okay. They are not as evil as the name implies.

[/opinion]

What you really need to do: fix the bad programming that creates them. Or hire good programmers.

Zombies DO NOT respond to signals because they lack the process context to do so.
Kill -9 sends a signal.

Commands like preap just remove them from the internal kernel table by forcing the naughty parent process to call wait. Plus, it is OKAY to have a few zombies. It gives some programmers a chance to worry about something harmless, and bug the sysadmin.
Sysadmins love to be bugged by users.

When you have loads of zombies and they persist for days, it is time to rewrite code, or spend all day calling preap (on Solaris).
Good article thanks.But I dont say to jlliagre is not correct ?
# 11  
Old 05-08-2010
Not sure what means I'm not getting through. As I wrote, two zombies processes isn't a problem. They won't hurt the process table which has 32000 entries on Solaris and can be raised up to 999999. The only issue is cosmetic. I.e. zombies pollute ps and similar commands output. Reaping can fix that but the real issue is parent processes not handling their child's death, as I wrote too.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. 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

2. UNIX for Dummies Questions & Answers

what is zombie , how to kill it ,

Hello I try to googled it , but I dint get sufficient answer :( .. When I can see zombie running on server do they consume system resources or not ? I have read that is not good to kill them with signal 9 cause it might cause more troubles .. why is kill -9 so harmfull? thanks (2 Replies)
Discussion started by: kvok
2 Replies

3. 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

4. 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

5. 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

6. Linux

How to kill zombie process

I have RHES4 machine with VRTSralus - Backup Exec agent installed there and running as a service. The agent hiccups sometimes and turns into defunct state. The problem is that I cannot kill it anyway., it stays there forever until the machine is rebooted. I wonder if anyone had such an experience... (1 Reply)
Discussion started by: will_mike
1 Replies

7. 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

8. UNIX for Advanced & Expert Users

zombie daemon process!!

My daemon process is the child of init and init has the responsibility to remove it, once it turns zombie. But I want to ask why the daemon process which is child of init turns zombie in the first place. What measures I have to take to avoid this? rish (1 Reply)
Discussion started by: rish2005
1 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