[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: lock-up on SIGSTOP/CONT (was: 'suspend' and 'xterm')

From: Paul Jarc
Subject: Re: lock-up on SIGSTOP/CONT (was: 'suspend' and 'xterm')
Date: 23 May 2001 12:26:02 -0400
User-agent: Gnus/5.090004 (Oort Gnus v0.04) Emacs/20.7

Sven Mascheck <address@hidden> writes:
> In short: 
>    This seems to happen if a blocking wait() is called in the parent
>    process, being also programmed with BSD-like signal handling.
>    If a child changes status due to SIGSTOP, this usually means also
>    a SIGCHLD to the parent, to notify it about this change.
>    Some programs just wait(2) in the according handler for their
>    child and lock up now, as the child actually has not exited.

So do I understand correctly that any of these will avoid the problem:
- reprogram the child to send itself SIGTSTP instead of SIGSTOP
- reprogram the parent to not catch SIGCHLD
- reprogram the parent to wait in the SIGCHLD handler with either

> Meanwhile i have a pretty bunch of zombies on the AIX, as the kernel
> does not take care of these ghosts resulting from parents not wait()ing
> properly :)  On Free/OpenBSD it usually took some minutes to clean them
> up, but some others are still lurking around.  I don't know about the
> kernel mechanism.

The kernel isn't supposed to get rid of zombies, because the parent
might wait() for them later - they'll disappear at that point.  If the
parent exits first, then the kernel should assign its children as
children of process 1, which should frequently wait() for children it
doesn't know about.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]