From: Tejun Heo <tj@kernel.org>
To: "Michal Koutný" <mkoutny@suse.com>
Cc: cgroups@vger.kernel.org, Li Zefan <lizefan@huawei.com>,
Johannes Weiner <hannes@cmpxchg.org>,
linux-kernel@vger.kernel.org
Subject: Re: [RFC PATCH] cgroup/pids: Make pids.events notifications affine to pids.max
Date: Mon, 2 Dec 2019 11:11:00 -0800 [thread overview]
Message-ID: <20191202191100.GF16681@devbig004.ftw2.facebook.com> (raw)
In-Reply-To: <20191128172612.10259-1-mkoutny@suse.com>
Hello,
On Thu, Nov 28, 2019 at 06:26:12PM +0100, Michal Koutný wrote:
> Currently, when pids.max limit is breached in the hierarchy, the event
> is counted and reported in the cgroup where the forking task resides.
>
> The proper hierarchical behavior is to count and report the event in the
> cgroup whose limit is being exceeded. Apply this behavior in the default
> hierarchy.
>
> Reasons for RFC:
>
> 1) If anyone has adjusted their readings to this behavior, this is a BC
> break.
>
> 2) This solves no reported bug, just a spotted inconsistency.
>
> 3) One step further would be to distinguish pids.events and
> pids.events.local for proper hierarchical counting. (The current
> behavior wouldn't match neither though.)
Yeah this is incosistent with memcg but there max / high events are
essentially useless because that doesn't indicate actual limit breach.
Both events are interesting - which cgroup's limit was reached and who
suffered because of that.
So, maybe sth like the following?
1. Make max event propagate hierarchically. This is a behavior change
but also an obvious bug fix. Given that internal cgroups don't
have processes in cgroup2, maybe it's safe enough?
2. Add another (hierarchical, of course) event which counts the number
of fork rejects. I can't think of a good name. Any ideas?
Thanks.
--
tejun
next prev parent reply other threads:[~2019-12-02 19:11 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-11-28 17:26 [RFC PATCH] cgroup/pids: Make pids.events notifications affine to pids.max Michal Koutný
2019-12-02 19:11 ` Tejun Heo [this message]
2020-02-05 13:44 ` [RFC PATCH v2 0/3] " Michal Koutný
2020-02-05 13:44 ` [RFC PATCH v2 1/3] cgroup/pids: Separate semantics of pids.events related " Michal Koutný
2020-02-12 23:03 ` Tejun Heo
2020-02-05 13:44 ` [RFC PATCH v2 2/3] cgroup/pids: Make event counters hierarchical Michal Koutný
2020-02-05 13:44 ` [RFC PATCH v2 3/3] selftests: cgroup: Add basic tests for pids controller Michal Koutný
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=20191202191100.GF16681@devbig004.ftw2.facebook.com \
--to=tj@kernel.org \
--cc=cgroups@vger.kernel.org \
--cc=hannes@cmpxchg.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lizefan@huawei.com \
--cc=mkoutny@suse.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox