diff options
| author | KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> | 2009-01-29 17:25:14 -0500 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-01-29 21:04:44 -0500 |
| commit | 8d50d369d1b3ccc4d96ce01f62146173ee7064ca (patch) | |
| tree | e48c19188cb9eba15e73702e0f2e33bd7aba0d84 /Documentation/cgroups | |
| parent | 85d9fc89fb0f0703df6444f260187c088a8d59ff (diff) | |
memcg: update document to mention that swapoff should be tested
Considering the recently found problem "memcg: fix refcnt handling at
swapoff", it's better to mention swapoff behavior in the memcg_test
document.
Signed-off-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Acked-by: Balbir Singh <balbir@linux.vnet.ibm.com>
Cc: Li Zefan <lizf@cn.fujitsu.com>
Cc: Daisuke Nishimura <nishimura@mxp.nes.nec.co.jp>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'Documentation/cgroups')
| -rw-r--r-- | Documentation/cgroups/memcg_test.txt | 24 |
1 files changed, 22 insertions, 2 deletions
diff --git a/Documentation/cgroups/memcg_test.txt b/Documentation/cgroups/memcg_test.txt index 19533f93b7a2..523a9c16c400 100644 --- a/Documentation/cgroups/memcg_test.txt +++ b/Documentation/cgroups/memcg_test.txt | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | Memory Resource Controller(Memcg) Implementation Memo. | 1 | Memory Resource Controller(Memcg) Implementation Memo. |
| 2 | Last Updated: 2008/12/15 | 2 | Last Updated: 2009/1/19 |
| 3 | Base Kernel Version: based on 2.6.28-rc8-mm. | 3 | Base Kernel Version: based on 2.6.29-rc2. |
| 4 | 4 | ||
| 5 | Because VM is getting complex (one of reasons is memcg...), memcg's behavior | 5 | Because VM is getting complex (one of reasons is memcg...), memcg's behavior |
| 6 | is complex. This is a document for memcg's internal behavior. | 6 | is complex. This is a document for memcg's internal behavior. |
| @@ -340,3 +340,23 @@ Under below explanation, we assume CONFIG_MEM_RES_CTRL_SWAP=y. | |||
| 340 | # mount -t cgroup none /cgroup -t cpuset,memory,cpu,devices | 340 | # mount -t cgroup none /cgroup -t cpuset,memory,cpu,devices |
| 341 | 341 | ||
| 342 | and do task move, mkdir, rmdir etc...under this. | 342 | and do task move, mkdir, rmdir etc...under this. |
| 343 | |||
| 344 | 9.7 swapoff. | ||
| 345 | Besides management of swap is one of complicated parts of memcg, | ||
| 346 | call path of swap-in at swapoff is not same as usual swap-in path.. | ||
| 347 | It's worth to be tested explicitly. | ||
| 348 | |||
| 349 | For example, test like following is good. | ||
| 350 | (Shell-A) | ||
| 351 | # mount -t cgroup none /cgroup -t memory | ||
| 352 | # mkdir /cgroup/test | ||
| 353 | # echo 40M > /cgroup/test/memory.limit_in_bytes | ||
| 354 | # echo 0 > /cgroup/test/tasks | ||
| 355 | Run malloc(100M) program under this. You'll see 60M of swaps. | ||
| 356 | (Shell-B) | ||
| 357 | # move all tasks in /cgroup/test to /cgroup | ||
| 358 | # /sbin/swapoff -a | ||
| 359 | # rmdir /test/cgroup | ||
| 360 | # kill malloc task. | ||
| 361 | |||
| 362 | Of course, tmpfs v.s. swapoff test should be tested, too. | ||
