Re: python at login on macintels
- From: Bob Harris <nospam.News.Bob@xxxxxxxxxxxxxxxxxxxxxx>
- Date: Sun, 04 Jun 2006 19:32:04 GMT
In article
<tomstiller-A14131.23111403062006@xxxxxxxxxxxxxxxxxxxxxxxx>,
Tom Stiller <tomstiller@xxxxxxxxxxx> wrote:
In article <nospam.News.Bob-E7F013.19131603062006@xxxxxxxxxxxxxxxx>,
Bob Harris <nospam.News.Bob@xxxxxxxxxxxxxxxxxxxxxx> wrote:
Zombies: Your answer is close, but off by just a tiny bit.
A Zombie is a process that has terminated and is waiting for its
_STILL_ _ALIVE_ parent to reap the completion status.
If the parent process goes away and abandons the child before or
after the child process terminates the child process is inherited
by the 'init' process (process PID 1), and the 'init' process will
reap the status of the zombie process.
So the zombie hangs around until shutdown.
Zombie hang around until its parent process either issues a system
call from the wait() family, or the parent process terminates
which allows the zombie to be inherited by 'init', and init will
issue a wait to collect the completion status.
If the parent does not issue the wait, and the parent runs until
shutdown, then yes, the zombie will stay around until shutdown.
It still goes away the same way. During shutdown the parent will
be killed, the zombie is inherited by 'init', and its completion
status reaped.
So this means that the parent process actually still exists, or it
would not be a zombie.
You can find the parent process using the ps command
ps -o ppid,command -p [pid-of-the-zombie-process]
Then repeat using the PPID
ps -o command -p [PPID-from-previous-ps]
Interesting, but I'm not sure the explanation fits the case here.
Before logout there was a process, sctwistd, running with, say, pid 123.
After logout and re-login pid 123 is a python zombie.
Based on what you say, then sctwistd was killed as part of logout,
but its parent process was not, and the parent process did not
issue a wait to reap the completion status.
ps -o ppid,command -p 123
PPID COMMAND
nnnn (python)
ps -p [nnnn]
What is this parent process? That is the offender.
This is how zombies have worked since I first started using UNIX
back in 1985. This is how zombies worked when I was a Digital
Tru64 UNIX kernel developer. And as far as I know, this is how
zombies work on MacOSX and Linux. The zombie waits for its
parent, and if it parent dies, it is automatically adapted by
'init' which gives it the needed care and attention.
Bob Harris
.
- Follow-Ups:
- Re: python at login on macintels
- From: Tom Stiller
- Re: python at login on macintels
- References:
- Re: python at login on macintels
- From: Tom Stiller
- Re: python at login on macintels
- From: John C . Randolph
- Re: python at login on macintels
- From: Tom Stiller
- Re: python at login on macintels
- From: D P Schreber
- Re: python at login on macintels
- From: D P Schreber
- Re: python at login on macintels
- From: Tom Harrington
- Re: python at login on macintels
- From: Tom Stiller
- Re: python at login on macintels
- From: Bob Harris
- Re: python at login on macintels
- From: Tom Stiller
- Re: python at login on macintels
- Prev by Date: Re: Can't get MT-Newswatcher to connect to server in Tiger
- Next by Date: Re: i really need help with my i pod
- Previous by thread: Re: python at login on macintels
- Next by thread: Re: python at login on macintels
- Index(es):
Relevant Pages
|
|