It is not a zombe. If a child process dies and the parent never calls wait() you get a zombe. If the parent dies then the child's parent becomes init, which calls wait all the time. So anything with parent init is still running, probably waiting for some I/O.
Try building it with debug on (-g) and then use gdb to attach to a running "zombe" and see what it is doing.
-----Original Message-----
From: [email protected] on behalf of Michael Abbott
Sent: Mon 5/12/2008 6:08 AM
To: [email protected]
Subject: Creating Zombies with epicsThreadExitMain
I'm finding some very strange behaviour with epicsThreadExitMain on Red
Hat Enterprise Linux 4. The default soft IOC implementation (softIoc.cpp)
exits by calling epicsThreadExitMain(), but this has a very unfortunate
effect on my system (RHEL 4) -- a Zombie process is created (apparently
owned by init, which is the first puzzle) which continues to hold its
executable file open. I've also confirmed this on RHEL 5.
I guess there are two separate issues here:
1. Exiting with epicsThreadExitMain() appears to be a very bad thing, at
least on RHEL;
2. RHEL appears to have an unpleasant bug involving process cleanup -- how
else do I have persistent zombies owned by init? Or else I'm missing
something...
To reproduce this, create an EPICS IOC with the following code:
int main()
{
iocsh("/dev/null");
epicsThreadExitMain();
}
The iocsh() call is necessary to reproduce the problem.
- Replies:
- RE: Creating Zombies with epicsThreadExitMain Michael Abbott
- References:
- Creating Zombies with epicsThreadExitMain Michael Abbott
- Navigate by Date:
- Prev:
Creating Zombies with epicsThreadExitMain Michael Abbott
- Next:
RE: Creating Zombies with epicsThreadExitMain Michael Abbott
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
<2008>
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
- Navigate by Thread:
- Prev:
Creating Zombies with epicsThreadExitMain Michael Abbott
- Next:
RE: Creating Zombies with epicsThreadExitMain Michael Abbott
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
<2008>
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
|