2009-06-04 11:51:06

by Scott James Remnant

[permalink] [raw]
Subject: Re: [PATCH/RFC] exit: PR_SET_ANCHOR for marking processes as reapers for child processes

On Thu, 2009-05-28 at 22:47 +0200, Lennart Poettering wrote:

> Right now, if a process dies all its children are reparented to init.
> This logic has good uses, i.e. for double forking when
> daemonizing. However it also allows child processes to "escape" their
> parents, which is a problem for software like session managers (such
> as gnome-session) or other process supervisors [1].
>
As we discussed on IRC, another option is for the session
manager/process supervisor to use the proc connector to receive messages
about fork() and exit() - then it doesn't need to receive SIGCHLD, so it
doesn't matter where the process reparents to.

OTOH, this patch would make the process trees much prettier <g>

Scott
--
Scott James Remnant
[email protected]


Attachments:
signature.asc (197.00 B)
This is a digitally signed message part