From: Lennart Poettering <mzxreary@0pointer.de>
To: Scott James Remnant <scott@netsplit.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH] exit: PR_SET_ANCHOR for marking processes as reapers for child processes
Date: Thu, 23 Dec 2010 16:44:59 +0100 [thread overview]
Message-ID: <20101223154458.GB17788@tango.0pointer.de> (raw)
In-Reply-To: <AANLkTi=GGGP4vK1hOBn-+oCAM1gFXg_XUfLeTFM2CqA_@mail.gmail.com>
On Tue, 21.12.10 12:05, Scott James Remnant (scott@netsplit.com) wrote:
> > PID namespaces primarily provide an independent PID numbering scheme for
> > a subset of processes, i.e. so that identical may PIDs refer to different
> > processes depending on the namespace they are running in. As a side
> > effect this also provides init-like behaviour for processes that aren't
> > the original PID 1 of the operating system. For systemd we are only
> > interested in this side effect, but are not interested at all in the
> > renumbering of processes, and in fact would even really dislike if it
> > happened. That's why PR_SET_ANCHOR is useful: it gives us init-like
> > behaviour without renaming all processes.
> >
> Right, but I don't get why you need this behavior to supervise either
> system or user processes. You already get all the functionality you
> need to track processes via either cgroups or the proc connector (or a
> combination of both).
Well, we want a clean way to get access to the full siginfo_t of the
SIGCHLD for the main process of a service. the proc connector is awful
and cgroups does not pass siginfo_t's back to userspace, hence the
cleanest way to get this done properly and beautifully is to make the
session systemd a mini-init via PR_SET_ANCHOR, because then the per-user
systemd's and the per-system systemd can use the exact same code to
handle process managment.
> So is this really just about making ps look pretty, as Kay says?
That's a side effect, but for me it's mostly about getting a simple way
to get the SIGCHLDs, focussed on the children of the session manager and
with minimal wakeups.
Lennart
--
Lennart Poettering - Red Hat, Inc.
next prev parent reply other threads:[~2010-12-23 15:45 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-02-02 12:04 [PATCH] exit: PR_SET_ANCHOR for marking processes as reapers for child processes Lennart Poettering
2010-02-03 8:24 ` KOSAKI Motohiro
2010-02-03 9:53 ` Lennart Poettering
2010-02-03 15:31 ` Américo Wang
2010-02-03 17:49 ` Lennart Poettering
2010-02-05 9:54 ` Américo Wang
2010-02-11 10:21 ` Kay Sievers
2010-02-04 15:42 ` Kay Sievers
2010-02-04 20:59 ` Kay Sievers
2010-03-04 14:08 ` Oleg Nesterov
2010-03-04 22:14 ` Roland McGrath
2010-03-05 18:51 ` Kay Sievers
2010-03-05 19:18 ` Roland McGrath
2010-03-06 0:24 ` Lennart Poettering
2010-03-09 0:45 ` Ray Lee
2010-03-09 13:19 ` Oleg Nesterov
2010-03-06 0:20 ` Lennart Poettering
2010-03-08 23:11 ` Roland McGrath
2010-03-05 4:47 ` KOSAKI Motohiro
2010-03-05 18:55 ` Kay Sievers
2010-03-06 0:16 ` Lennart Poettering
2010-03-11 4:14 ` Eric W. Biederman
2010-03-11 7:56 ` KOSAKI Motohiro
2010-12-20 14:26 ` Scott James Remnant
2010-12-20 14:51 ` Kay Sievers
2010-12-21 9:56 ` Lennart Poettering
2010-12-21 12:05 ` Scott James Remnant
2010-12-23 15:44 ` Lennart Poettering [this message]
2010-12-23 16:00 ` Scott James Remnant
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20101223154458.GB17788@tango.0pointer.de \
--to=mzxreary@0pointer.de \
--cc=linux-kernel@vger.kernel.org \
--cc=scott@netsplit.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.