From: Waiman Long <longman@redhat.com>
To: Tejun Heo <tj@kernel.org>
Cc: Li Zefan <lizefan@huawei.com>,
Johannes Weiner <hannes@cmpxchg.org>,
Peter Zijlstra <peterz@infradead.org>,
Ingo Molnar <mingo@redhat.com>,
cgroups@vger.kernel.org, linux-kernel@vger.kernel.org,
kernel-team@fb.com, pjt@google.com, luto@amacapital.net,
efault@gmx.de, torvalds@linux-foundation.org
Subject: Re: [RFC PATCH-cgroup 4/6] cgroup: Introduce subtree root mode
Date: Thu, 22 Jun 2017 16:27:14 -0400 [thread overview]
Message-ID: <7e59ea28-76df-9c9f-02f5-e2847216f1dc@redhat.com> (raw)
In-Reply-To: <20170621213807.GC14720@htj.duckdns.org>
On 06/21/2017 05:38 PM, Tejun Heo wrote:
> Hello, Waiman.
>
> On Wed, Jun 14, 2017 at 11:05:35AM -0400, Waiman Long wrote:
>> Subtree root mode is a new cgroup mode which applies the following
>> restrictions when turned on:
>>
>> 1) Controllers are only allowed to be passed to the children in
>> bypass mode except those with the "enable_on_root" flag on.
>> 2) Only 1 child cgroup is allowed.
>>
>> That lone child can be used as the pseudo root of a container cgroup
>> hierarchy. All the resources, if controlled, are in the parent
>> cgroup. There will be no control knobs in the child. That makes it
>> look and feel like a root.
> I'm not sure not having the control files in the child makes that much
> difference.
It is more a look and feel thing than being useful. The sole purpose is
to make the container root looks like a real root as much as possible.
>> That pseudo root is also considered to be mixable and so can become
>> root of a mixed threaded subtree. The no internal process constraint
>> also does not apply.
> Heh, you can't just declare a non-root cgroup to be a mixed root but
> if you're special casing this and making the kernel play a masquerade
> with special node, you can make cgroup provide a mixed root while
> hosting the internal processes in a dedicated leaf cgroup which isn't
> visible to the nested root, right?
That is true.
> It's all a game of masquerading tho and doesn't actually enable
> anything which isn't possible now. This would definitely be useful
> for testing.
You are right about that. As mentioned in another email, having bypass
mode in subtree_control is useful, I think. The concept of subtree root
mode, however, is more toward satisfying PeterZ's idea of container
invariant. I won't mind leaving it out if others have no objection to that.
Cheers,
Longman
next prev parent reply other threads:[~2017-06-22 20:27 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-06-14 15:05 [RFC PATCH-cgroup 0/6] cgroup: bypass and subtree root modes Waiman Long
2017-06-14 15:05 ` [RFC PATCH-cgroup 1/6] cgroup: Relax the no internal process constraint Waiman Long
2017-06-21 20:40 ` Tejun Heo
2017-06-21 21:37 ` Waiman Long
2017-06-21 21:39 ` Tejun Heo
2017-06-21 21:50 ` Waiman Long
2017-06-21 22:02 ` Tejun Heo
2017-06-14 15:05 ` [RFC PATCH-cgroup 2/6] cgroup: Enable bypass mode in cgroup v2 Waiman Long
2017-06-21 21:17 ` Tejun Heo
2017-06-22 20:07 ` Waiman Long
2017-06-14 15:05 ` [RFC PATCH-cgroup 3/6] cgroup: Allow bypss mode in subtree_control Waiman Long
2017-06-14 15:05 ` [RFC PATCH-cgroup 4/6] cgroup: Introduce subtree root mode Waiman Long
2017-06-21 21:38 ` Tejun Heo
2017-06-22 20:27 ` Waiman Long [this message]
2017-06-14 15:05 ` [RFC PATCH-cgroup 5/6] cgroup: Skip dying css in cgroup_apply_control_{enable,disable} Waiman Long
2017-06-21 21:42 ` Tejun Heo
2017-06-21 22:01 ` Waiman Long
2017-06-21 22:04 ` Tejun Heo
2017-06-21 22:19 ` Waiman Long
2017-06-14 15:05 ` [RFC PATCH-cgroup 6/6] cgroup: Make debug controller display bypass and subtree root modes info Waiman Long
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=7e59ea28-76df-9c9f-02f5-e2847216f1dc@redhat.com \
--to=longman@redhat.com \
--cc=cgroups@vger.kernel.org \
--cc=efault@gmx.de \
--cc=hannes@cmpxchg.org \
--cc=kernel-team@fb.com \
--cc=linux-kernel@vger.kernel.org \
--cc=lizefan@huawei.com \
--cc=luto@amacapital.net \
--cc=mingo@redhat.com \
--cc=peterz@infradead.org \
--cc=pjt@google.com \
--cc=tj@kernel.org \
--cc=torvalds@linux-foundation.org \
/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
Powered by JetHome