<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/Documentation/cgroups/cgroups.txt, branch v3.2.23</title>
<subtitle>Linux kernel source tree</subtitle>
<id>https://git.amat.us/linux/atom/Documentation/cgroups/cgroups.txt?h=v3.2.23</id>
<link rel='self' href='https://git.amat.us/linux/atom/Documentation/cgroups/cgroups.txt?h=v3.2.23'/>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/'/>
<updated>2011-11-04T19:01:46Z</updated>
<entry>
<title>Documentation: update cgroups notes</title>
<updated>2011-11-04T19:01:46Z</updated>
<author>
<name>Li Zefan</name>
<email>lizf@cn.fujitsu.com</email>
</author>
<published>2011-11-04T18:22:05Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=5fe69d7e258a17d825d982ac695c1db5c4bc4768'/>
<id>urn:sha1:5fe69d7e258a17d825d982ac695c1db5c4bc4768</id>
<content type='text'>
- ns cgroup has been removed.
- it's true moving a task to another cgroup can fail.

Signed-off-by: Li Zefan &lt;lizf@cn.fujitsu.com&gt;
Acked-by: Paul Menage &lt;paul@paulmenage.org&gt;
Signed-off-by: Randy Dunlap &lt;rdunlap@xenotime.net&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>Documentation: fix cgroup typos and formatting</title>
<updated>2011-06-16T04:52:50Z</updated>
<author>
<name>Jörg Sommer</name>
<email>joerg@alea.gnuu.de</email>
</author>
<published>2011-06-15T20:00:47Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=67de0162fbb78713fcb23cb2502b380faa8bde73'/>
<id>urn:sha1:67de0162fbb78713fcb23cb2502b380faa8bde73</id>
<content type='text'>
Fix format and spelling.

Signed-off-by: Jörg Sommer &lt;joerg@alea.gnuu.de&gt;
Acked-by: Paul Menage &lt;menage@google.com&gt;
Signed-off-by: Randy Dunlap &lt;randy.dunlap@oracle.com&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>Documentation: update cgroupfs mount point</title>
<updated>2011-06-16T04:52:50Z</updated>
<author>
<name>Jörg Sommer</name>
<email>joerg@alea.gnuu.de</email>
</author>
<published>2011-06-15T19:59:45Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=f6e07d38078e82a6aeaae00bb134591ef5ac1167'/>
<id>urn:sha1:f6e07d38078e82a6aeaae00bb134591ef5ac1167</id>
<content type='text'>
According to commit 676db4af0430 ("cgroupfs: create /sys/fs/cgroup to
mount cgroupfs on") the canonical mountpoint for the cgroup filesystem
is /sys/fs/cgroup.  Hence, this should be used in the documentation.

Signed-off-by: Jörg Sommer &lt;joerg@alea.gnuu.de&gt;
Acked-by: Paul Menage &lt;menage@google.com&gt;
Signed-off-by: Randy Dunlap &lt;randy.dunlap@oracle.com&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>cgroup: remove the ns_cgroup</title>
<updated>2011-05-27T00:12:34Z</updated>
<author>
<name>Daniel Lezcano</name>
<email>daniel.lezcano@free.fr</email>
</author>
<published>2011-05-26T23:25:23Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=a77aea92010acf54ad785047234418d5d68772e2'/>
<id>urn:sha1:a77aea92010acf54ad785047234418d5d68772e2</id>
<content type='text'>
The ns_cgroup is an annoying cgroup at the namespace / cgroup frontier and
leads to some problems:

  * cgroup creation is out-of-control
  * cgroup name can conflict when pids are looping
  * it is not possible to have a single process handling a lot of
    namespaces without falling in a exponential creation time
  * we may want to create a namespace without creating a cgroup

  The ns_cgroup was replaced by a compatibility flag 'clone_children',
  where a newly created cgroup will copy the parent cgroup values.
  The userspace has to manually create a cgroup and add a task to
  the 'tasks' file.

This patch removes the ns_cgroup as suggested in the following thread:

https://lists.linux-foundation.org/pipermail/containers/2009-June/018616.html

The 'cgroup_clone' function is removed because it is no longer used.

This is a userspace-visible change.  Commit 45531757b45c ("cgroup: notify
ns_cgroup deprecated") (merged into 2.6.27) caused the kernel to emit a
printk warning users that the feature is planned for removal.  Since that
time we have heard from XXX users who were affected by this.

Signed-off-by: Daniel Lezcano &lt;daniel.lezcano@free.fr&gt;
Signed-off-by: Serge E. Hallyn &lt;serge.hallyn@canonical.com&gt;
Cc: Eric W. Biederman &lt;ebiederm@xmission.com&gt;
Cc: Jamal Hadi Salim &lt;hadi@cyberus.ca&gt;
Reviewed-by: Li Zefan &lt;lizf@cn.fujitsu.com&gt;
Acked-by: Paul Menage &lt;menage@google.com&gt;
Acked-by: Matt Helsley &lt;matthltc@us.ibm.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>cgroups: make procs file writable</title>
<updated>2011-05-27T00:12:34Z</updated>
<author>
<name>Ben Blum</name>
<email>bblum@andrew.cmu.edu</email>
</author>
<published>2011-05-26T23:25:20Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=74a1166dfe1135dcc168d35fa5261aa7e087011b'/>
<id>urn:sha1:74a1166dfe1135dcc168d35fa5261aa7e087011b</id>
<content type='text'>
Make procs file writable to move all threads by tgid at once.

Add functionality that enables users to move all threads in a threadgroup
at once to a cgroup by writing the tgid to the 'cgroup.procs' file.  This
current implementation makes use of a per-threadgroup rwsem that's taken
for reading in the fork() path to prevent newly forking threads within the
threadgroup from "escaping" while the move is in progress.

Signed-off-by: Ben Blum &lt;bblum@andrew.cmu.edu&gt;
Cc: "Eric W. Biederman" &lt;ebiederm@xmission.com&gt;
Cc: Li Zefan &lt;lizf@cn.fujitsu.com&gt;
Cc: Matt Helsley &lt;matthltc@us.ibm.com&gt;
Reviewed-by: Paul Menage &lt;menage@google.com&gt;
Cc: Oleg Nesterov &lt;oleg@redhat.com&gt;
Cc: David Rientjes &lt;rientjes@google.com&gt;
Cc: Miao Xie &lt;miaox@cn.fujitsu.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>cgroups: add per-thread subsystem callbacks</title>
<updated>2011-05-27T00:12:34Z</updated>
<author>
<name>Ben Blum</name>
<email>bblum@andrew.cmu.edu</email>
</author>
<published>2011-05-26T23:25:19Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=f780bdb7c1c73009cb57adcf99ef50027d80bf3c'/>
<id>urn:sha1:f780bdb7c1c73009cb57adcf99ef50027d80bf3c</id>
<content type='text'>
Add cgroup subsystem callbacks for per-thread attachment in atomic contexts

Add can_attach_task(), pre_attach(), and attach_task() as new callbacks
for cgroups's subsystem interface.  Unlike can_attach and attach, these
are for per-thread operations, to be called potentially many times when
attaching an entire threadgroup.

Also, the old "bool threadgroup" interface is removed, as replaced by
this.  All subsystems are modified for the new interface - of note is
cpuset, which requires from/to nodemasks for attach to be globally scoped
(though per-cpuset would work too) to persist from its pre_attach to
attach_task and attach.

This is a pre-patch for cgroup-procs-writable.patch.

Signed-off-by: Ben Blum &lt;bblum@andrew.cmu.edu&gt;
Cc: "Eric W. Biederman" &lt;ebiederm@xmission.com&gt;
Cc: Li Zefan &lt;lizf@cn.fujitsu.com&gt;
Cc: Matt Helsley &lt;matthltc@us.ibm.com&gt;
Reviewed-by: Paul Menage &lt;menage@google.com&gt;
Cc: Oleg Nesterov &lt;oleg@redhat.com&gt;
Cc: David Rientjes &lt;rientjes@google.com&gt;
Cc: Miao Xie &lt;miaox@cn.fujitsu.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>Documentation: update cgroups info user groups names</title>
<updated>2011-04-05T00:51:47Z</updated>
<author>
<name>Geunsik Lim</name>
<email>geunsik.lim@samsung.com</email>
</author>
<published>2011-04-04T22:10:45Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=6ad85239da45d035b2c786f73ec3c2798352c820'/>
<id>urn:sha1:6ad85239da45d035b2c786f73ec3c2798352c820</id>
<content type='text'>
Update suitable words to explain / understand cgroups contents.

Signed-off-by: Geunsik Lim &lt;geunsik.lim@samsung.com&gt;
Cc: Paul Menage &lt;menage@google.com&gt;
Signed-off-by: Randy Dunlap &lt;randy.dunlap@oracle.com&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>Documentation: update cgroup pid and cpuset information</title>
<updated>2011-03-16T17:47:04Z</updated>
<author>
<name>Eric B Munson</name>
<email>emunson@mgebm.net</email>
</author>
<published>2011-03-15T23:12:18Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=bb6405eab2a408c46949b3353ecfa1126caa3af2'/>
<id>urn:sha1:bb6405eab2a408c46949b3353ecfa1126caa3af2</id>
<content type='text'>
The cgroup documentation does not specify how a process can be removed
from a particular group.  This patch adds a note at the end of the
simple example about how this is done.  Also, some cgroups (like
cpusets) require user input before a new group can be used.  This is
noted in the patch as well.

Signed-off-by: Eric B Munson &lt;emunson@mgebm.net&gt;
Acked-by: Paul Menage &lt;menage@google.com&gt;
Signed-off-by: Randy Dunlap &lt;randy.dunlap@oracle.com&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>cgroups: remove deprecated subsystem from examples.</title>
<updated>2011-01-13T16:03:16Z</updated>
<author>
<name>Trevor Woerner</name>
<email>twoerner@gmail.com</email>
</author>
<published>2011-01-13T01:00:29Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=1bdcd78e2445f1ef7097a3ae7ef12e8f9c4fb05f'/>
<id>urn:sha1:1bdcd78e2445f1ef7097a3ae7ef12e8f9c4fb05f</id>
<content type='text'>
The 'ns' cgroup is considered deprecated. Change the cgroup subsystem
used in the examples of the cgroup documentation from 'ns' to 'blkio'.

Signed-off-by: Trevor Woerner &lt;twoerner@gmail.com&gt;
Acked-by: Li Zefan &lt;lizf@cn.fujitsu.com&gt;
Acked-by: Paul Menage &lt;menage@google.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>cgroup: add clone_children control file</title>
<updated>2010-10-28T01:03:09Z</updated>
<author>
<name>Daniel Lezcano</name>
<email>daniel.lezcano@free.fr</email>
</author>
<published>2010-10-27T22:33:35Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=97978e6d1f2da0073416870410459694fbdbfd9b'/>
<id>urn:sha1:97978e6d1f2da0073416870410459694fbdbfd9b</id>
<content type='text'>
The ns_cgroup is a control group interacting with the namespaces.  When a
new namespace is created, a corresponding cgroup is automatically created
too.  The cgroup name is the pid of the process who did 'unshare' or the
child of 'clone'.

This cgroup is tied with the namespace because it prevents a process to
escape the control group and use the post_clone callback, so the child
cgroup inherits the values of the parent cgroup.

Unfortunately, the more we use this cgroup and the more we are facing
problems with it:

(1) when a process unshares, the cgroup name may conflict with a
    previous cgroup with the same pid, so unshare or clone return -EEXIST

(2) the cgroup creation is out of control because there may have an
    application creating several namespaces where the system will
    automatically create several cgroups in his back and let them on the
    cgroupfs (eg.  a vrf based on the network namespace).

(3) the mix of (1) and (2) force an administrator to regularly check
    and clean these cgroups.

This patchset removes the ns_cgroup by adding a new flag to the cgroup and
the cgroupfs mount option.  It enables the copy of the parent cgroup when
a child cgroup is created.  We can then safely remove the ns_cgroup as
this flag brings a compatibility.  We have now to manually create and add
the task to a cgroup, which is consistent with the cgroup framework.

This patch:

Sent as an answer to a previous thread around the ns_cgroup.

https://lists.linux-foundation.org/pipermail/containers/2009-June/018627.html

It adds a control file 'clone_children' for a cgroup.  This control file
is a boolean specifying if the child cgroup should be a clone of the
parent cgroup or not.  The default value is 'false'.

This flag makes the child cgroup to call the post_clone callback of all
the subsystem, if it is available.

At present, the cpuset is the only one which had implemented the
post_clone callback.

The option can be set at mount time by specifying the 'clone_children'
mount option.

Signed-off-by: Daniel Lezcano &lt;daniel.lezcano@free.fr&gt;
Signed-off-by: Serge E. Hallyn &lt;serge.hallyn@canonical.com&gt;
Cc: Eric W. Biederman &lt;ebiederm@xmission.com&gt;
Acked-by: Paul Menage &lt;menage@google.com&gt;
Reviewed-by: Li Zefan &lt;lizf@cn.fujitsu.com&gt;
Cc: Jamal Hadi Salim &lt;hadi@cyberus.ca&gt;
Cc: Matt Helsley &lt;matthltc@us.ibm.com&gt;
Acked-by: Balbir Singh &lt;balbir@linux.vnet.ibm.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
</feed>
