<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/Documentation/cgroups, branch v3.1</title>
<subtitle>Linux kernel source tree</subtitle>
<id>https://git.amat.us/linux/atom/Documentation/cgroups?h=v3.1</id>
<link rel='self' href='https://git.amat.us/linux/atom/Documentation/cgroups?h=v3.1'/>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/'/>
<updated>2011-09-15T01:09:38Z</updated>
<entry>
<title>memcg: Revert "memcg: add memory.vmscan_stat"</title>
<updated>2011-09-15T01:09:38Z</updated>
<author>
<name>Johannes Weiner</name>
<email>jweiner@redhat.com</email>
</author>
<published>2011-09-14T23:21:58Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=185efc0f9a1f2d6ad6d4782c5d9e529f3290567f'/>
<id>urn:sha1:185efc0f9a1f2d6ad6d4782c5d9e529f3290567f</id>
<content type='text'>
Revert the post-3.0 commit 82f9d486e59f5 ("memcg: add
memory.vmscan_stat").

The implementation of per-memcg reclaim statistics violates how memcg
hierarchies usually behave: hierarchically.

The reclaim statistics are accounted to child memcgs and the parent
hitting the limit, but not to hierarchy levels in between.  Usually,
hierarchical statistics are perfectly recursive, with each level
representing the sum of itself and all its children.

Since this exports statistics to userspace, this may lead to confusion
and problems with changing things after the release, so revert it now,
we can try again later.

Signed-off-by: Johannes Weiner &lt;jweiner@redhat.com&gt;
Acked-by: KAMEZAWA Hiroyuki &lt;kamezawa.hiroyu@jp.fujitsu.com&gt;
Cc: Daisuke Nishimura &lt;nishimura@mxp.nes.nec.co.jp&gt;
Cc: Michal Hocko &lt;mhocko@suse.cz&gt;
Cc: Ying Han &lt;yinghan@google.com&gt;
Cc: Balbir Singh &lt;bsingharora@gmail.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>memcg: add memory.vmscan_stat</title>
<updated>2011-07-26T23:49:42Z</updated>
<author>
<name>KAMEZAWA Hiroyuki</name>
<email>kamezawa.hiroyu@jp.fujitsu.com</email>
</author>
<published>2011-07-26T23:08:26Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=82f9d486e59f588c7d100865c36510644abda356'/>
<id>urn:sha1:82f9d486e59f588c7d100865c36510644abda356</id>
<content type='text'>
The commit log of 0ae5e89c60c9 ("memcg: count the soft_limit reclaim
in...") says it adds scanning stats to memory.stat file.  But it doesn't
because we considered we needed to make a concensus for such new APIs.

This patch is a trial to add memory.scan_stat. This shows
  - the number of scanned pages(total, anon, file)
  - the number of rotated pages(total, anon, file)
  - the number of freed pages(total, anon, file)
  - the number of elaplsed time (including sleep/pause time)

  for both of direct/soft reclaim.

The biggest difference with oringinal Ying's one is that this file
can be reset by some write, as

  # echo 0 ...../memory.scan_stat

Example of output is here. This is a result after make -j 6 kernel
under 300M limit.

  [kamezawa@bluextal ~]$ cat /cgroup/memory/A/memory.scan_stat
  [kamezawa@bluextal ~]$ cat /cgroup/memory/A/memory.vmscan_stat
  scanned_pages_by_limit 9471864
  scanned_anon_pages_by_limit 6640629
  scanned_file_pages_by_limit 2831235
  rotated_pages_by_limit 4243974
  rotated_anon_pages_by_limit 3971968
  rotated_file_pages_by_limit 272006
  freed_pages_by_limit 2318492
  freed_anon_pages_by_limit 962052
  freed_file_pages_by_limit 1356440
  elapsed_ns_by_limit 351386416101
  scanned_pages_by_system 0
  scanned_anon_pages_by_system 0
  scanned_file_pages_by_system 0
  rotated_pages_by_system 0
  rotated_anon_pages_by_system 0
  rotated_file_pages_by_system 0
  freed_pages_by_system 0
  freed_anon_pages_by_system 0
  freed_file_pages_by_system 0
  elapsed_ns_by_system 0
  scanned_pages_by_limit_under_hierarchy 9471864
  scanned_anon_pages_by_limit_under_hierarchy 6640629
  scanned_file_pages_by_limit_under_hierarchy 2831235
  rotated_pages_by_limit_under_hierarchy 4243974
  rotated_anon_pages_by_limit_under_hierarchy 3971968
  rotated_file_pages_by_limit_under_hierarchy 272006
  freed_pages_by_limit_under_hierarchy 2318492
  freed_anon_pages_by_limit_under_hierarchy 962052
  freed_file_pages_by_limit_under_hierarchy 1356440
  elapsed_ns_by_limit_under_hierarchy 351386416101
  scanned_pages_by_system_under_hierarchy 0
  scanned_anon_pages_by_system_under_hierarchy 0
  scanned_file_pages_by_system_under_hierarchy 0
  rotated_pages_by_system_under_hierarchy 0
  rotated_anon_pages_by_system_under_hierarchy 0
  rotated_file_pages_by_system_under_hierarchy 0
  freed_pages_by_system_under_hierarchy 0
  freed_anon_pages_by_system_under_hierarchy 0
  freed_file_pages_by_system_under_hierarchy 0
  elapsed_ns_by_system_under_hierarchy 0

total_xxxx is for hierarchy management.

This will be useful for further memcg developments and need to be
developped before we do some complicated rework on LRU/softlimit
management.

This patch adds a new struct memcg_scanrecord into scan_control struct.
sc-&gt;nr_scanned at el is not designed for exporting information.  For
example, nr_scanned is reset frequentrly and incremented +2 at scanning
mapped pages.

To avoid complexity, I added a new param in scan_control which is for
exporting scanning score.

Signed-off-by: KAMEZAWA Hiroyuki &lt;kamezawa.hiroyu@jp.fujitsu.com&gt;
Cc: Daisuke Nishimura &lt;nishimura@mxp.nes.nec.co.jp&gt;
Cc: Michal Hocko &lt;mhocko@suse.cz&gt;
Cc: Ying Han &lt;yinghan@google.com&gt;
Cc: Andrew Bresticker &lt;abrestic@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>Documentation: fix ambigous text for root cpuset</title>
<updated>2011-07-23T17:58:08Z</updated>
<author>
<name>Wanlong Gao</name>
<email>gaowanlong@cn.fujitsu.com</email>
</author>
<published>2011-07-23T17:38:17Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=9fd615f466f6a463ebe05f04b2684cccc65c5317'/>
<id>urn:sha1:9fd615f466f6a463ebe05f04b2684cccc65c5317</id>
<content type='text'>
Only the root cpuset has cpuset.memory_pressure_enabled flag,
but not the only one.

Signed-off-by: Wanlong Gao &lt;gaowanlong@cn.fujitsu.com&gt;
Signed-off-by: Randy Dunlap &lt;rdunlap@xenotime.net&gt;
Acked-by: Paul Menage &lt;menage@google.com&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>Documentation: fix echo command in cgroups/cpuacct.txt</title>
<updated>2011-07-23T17:58:08Z</updated>
<author>
<name>Wanlong Gao</name>
<email>gaowanlong@cn.fujitsu.com</email>
</author>
<published>2011-07-23T17:37:01Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=e47f9d84eec63484ae09f8c5b78ef605efa984a0'/>
<id>urn:sha1:e47f9d84eec63484ae09f8c5b78ef605efa984a0</id>
<content type='text'>
Must echo a task id to the cgroups' tasks file, but not to a directory.

Signed-off-by: Wanlong Gao &lt;gaowanlong@cn.fujitsu.com&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: fix cgroup blkio throttle filenames</title>
<updated>2011-07-06T20:17:51Z</updated>
<author>
<name>Andrea Righi</name>
<email>andrea@betterlinux.com</email>
</author>
<published>2011-07-06T18:26:26Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=9b61fc4cf3a7232ecc39f573a1e68148ef40ea49'/>
<id>urn:sha1:9b61fc4cf3a7232ecc39f573a1e68148ef40ea49</id>
<content type='text'>
All the blkio.throttle.* file names are incorrectly reported without
".throttle" in the documentation. Fix it.

Signed-off-by: Andrea Righi &lt;andrea@betterlinux.com&gt;
Signed-off-by: Randy Dunlap &lt;randy.dunlap@oracle.com&gt;
Acked-by: Vivek Goyal &lt;vgoyal@redhat.com&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>memcg: add documentation for the memory.numastat API</title>
<updated>2011-06-16T03:03:59Z</updated>
<author>
<name>Ying Han</name>
<email>yinghan@google.com</email>
</author>
<published>2011-06-15T22:08:16Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=50c35e5ba255fd8428cef8ff076da8d23bfd4909'/>
<id>urn:sha1:50c35e5ba255fd8428cef8ff076da8d23bfd4909</id>
<content type='text'>
[akpm@linux-foundation.org: rework text, fit it into 80-cols]
Signed-off-by: Ying Han &lt;yinghan@google.com&gt;
Reviewed-by: KOSAKI Motohiro &lt;kosaki.motohiro@jp.fujitsu.com&gt;
Acked-by: Balbir Singh &lt;bsingharora@gmail.com&gt;
Acked-by: KAMEZAWA Hiroyuki &lt;kamezawa.hiroyu@jp.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>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>
</feed>
