1838622 Members
2091 Online
110128 Solutions
New Discussion

Re: defunct process

 
SOLVED
Go to solution
navin
Super Advisor

defunct process

I have couple of defunct processes that appears in the pa risc server .which runs 11.23
I would like to is there a simple way to find out which process or script causing this .
thanks in advance
Learning ...
7 REPLIES 7
James R. Ferguson
Acclaimed Contributor
Solution

Re: defunct process

Hi:

Defunct processes are processes for which the parent has not yet reaped the dead child's status. You can find "defunct" processes by with:

# ps -ef|grep defunct

or:

# UNIX95= ps -o pid,state

...and looking for pids with a "Z" state.

A process is also called a 'zombie'. It is already dead, waiting for its parent to reap its termination status before it is removed from the kernel's process table.

Regards!

...JRF...
Kenan Erdey
Honored Contributor

Re: defunct process

Hi,

find processes ps -ef | grep defunct. And find the process by looking for the parent process' id. this may help you.

Kenan.
Computers have lots of memory but no imagination
navin
Super Advisor

Re: defunct process

Thanks Much .By removing ppid the defunct process will be terminted completely.But other than th ebad code..what could be the cause for these in general.
Thanks much
Learning ...
Jeeshan
Honored Contributor

Re: defunct process

'defunct' processes only take up an entry in the process or ps table and exist due to poor programming clean up.

These are processes whose parents have vanished without a syscall of wait() or waitpid() to collect the exit code of these children and remove them from the process table.
If you have lots of these zombies this is usually a sign of a piece of badly written code that produced them.
though they don't take up resources they are to avoid because they fill up your process table and can result in a system that cannot fork new processes, and thus is forced to be rebooted.
a warrior never quits
Torsten.
Acclaimed Contributor

Re: defunct process

For some (diagnostic related) processes this is expected behaviour - what is the name of your processes?

Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!   
Dennis Handly
Acclaimed Contributor

Re: defunct process

>ahsan: These are processes whose parents have

No, these zombie masters are still there. If they were dead, init would reap them.

>Torsten: For some (diagnostic related) processes this is expected behaviour

Well, more of a known problem than expected. :-)
Torsten.
Acclaimed Contributor

Re: defunct process

Well, I agree.

There was a problem with ia64_corehw, IIRC.

Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!