[Devel] Re: [RFC][PATCH] ns: Syscalls for better namespace sharing control.

2010-03-09 Thread Daniel Lezcano
Eric W. Biederman wrote: [ ... ] I guess my meaning is I was expecting. child = fork(); if (child == 0) { execve(...); } waitpid(child); This puts /bin/sh in the container as well. #include unistd.h #include stdlib.h #include stdio.h #include syscall.h #include sys/types.h

[Devel] Re: [RFC][PATCH] ns: Syscalls for better namespace sharing control.

2010-03-09 Thread Eric W. Biederman
Daniel Lezcano daniel.lezc...@free.fr writes: Eric W. Biederman wrote: [ ... ] I guess my meaning is I was expecting. child = fork(); if (child == 0) { execve(...); } waitpid(child); This puts /bin/sh in the container as well. #include unistd.h #include stdlib.h #include

[Devel] Re: [RFC][PATCH] ns: Syscalls for better namespace sharing control.

2010-03-09 Thread Daniel Lezcano
Eric W. Biederman wrote: Daniel Lezcano daniel.lezc...@free.fr writes: Eric W. Biederman wrote: [ ... ] I guess my meaning is I was expecting. child = fork(); if (child == 0) { execve(...); } waitpid(child); This puts /bin/sh in the container as well.

[Devel] [PATCH RFC linux-cr] add rpid to ckpt_pids struct

2010-03-09 Thread Serge E. Hallyn
When we restart an application, we won't try to restore the original pid in the parent pid_ns, so we don't checkpoint that pid. However, if we are going to dump mount info from userspace using /proc/pid/mountinfo, then it will be easiest for a restart wrapper to use the pids from the checkpoint

[Devel] [PATCH RFC user-cr] add -p option to ckptinfo to dump pids tree

2010-03-09 Thread Serge E. Hallyn
This will be used by a restart wrapper to analyze /proc/$$/mountinfo. Also add the new rpids field to ckpt_pids to reflect kernel. It depends on the patch I just sent for linux-cr adding rpid to struct ckpt_pids. Signed-off-by: Serge E. Hallyn se...@us.ibm.com --- ckptinfo.c

[Devel] [PATCH 1/8] cr_tests: crcounter: Don't report bogus waits

2010-03-09 Thread Matt Helsley
This outputs a bunch of garbage but according to the comments don't absolutely need this wait anyway. So redirect stderr for the bash wait to /dev/null. Signed-off-by: Matt Helsley matth...@us.ibm.com --- counterloop/cloop_serial.sh |2 +- 1 files changed, 1 insertions(+), 1 deletions(-)

[Devel] [PATCH 7/8] cr_tests: Make rewrite-cr-header.sh define the header cpp guard

2010-03-09 Thread Matt Helsley
Signed-off-by: Matt Helsley matth...@us.ibm.com --- rewrite-cr-header.sh |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/rewrite-cr-header.sh b/rewrite-cr-header.sh index 62ad5b5..21f699c 100755 --- a/rewrite-cr-header.sh +++ b/rewrite-cr-header.sh @@ -45,6 +45,7 @@ set

[Devel] [PATCH 2/8] cr_tests: factor out do_ckpt()

2010-03-09 Thread Matt Helsley
do_ckpt() sets checkpoint-ready and waits for checkpoint-done. Test scripts should set checkpoint-skip if tests should skip the wait for checkpoint-done as if checkpointing were done. This allows us to have tests with multiple checkpoints in them: checkpoint 1 ...

[Devel] [PATCH 5/8] cr_tests: simple: Fix stdio

2010-03-09 Thread Matt Helsley
The perror() after calling checkpoint() is useless -- stderr is closed. Fix it by using dup2() to redirect stderr to the specified file. Do the same for stdout just in case we want to use printf later. Signed-off-by: Matt Helsley matth...@us.ibm.com --- simple/ckpt.c |4 ++-- 1 files

[Devel] [PATCH 3/8] cr_tests: eventfd: use labels.[ch|lds] from libcrtest

2010-03-09 Thread Matt Helsley
Signed-off-by: Matt Helsley matth...@us.ibm.com --- eventfd/libeptest.h | 46 +- 1 files changed, 1 insertions(+), 45 deletions(-) diff --git a/eventfd/libeptest.h b/eventfd/libeptest.h index b6629e8..3f1522e 100644 --- a/eventfd/libeptest.h +++

[Devel] [PATCH 6/8] cr_tests: simple: Make output more useful

2010-03-09 Thread Matt Helsley
I'd have thought seeing hello, world! was a sign the test passed. Make the output indicative of the test results. Signed-off-by: Matt Helsley matth...@us.ibm.com --- simple/ckpt.c |6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/simple/ckpt.c b/simple/ckpt.c index

[Devel] [PATCH 8/8] cr_tests: update cr.h

2010-03-09 Thread Matt Helsley
cr.h is grossly out-of-date. Any build which relies on it is horribly broken without this change. Signed-off-by: Matt Helsley matth...@us.ibm.com --- cr.h | 46 +++--- 1 files changed, 19 insertions(+), 27 deletions(-) diff --git a/cr.h b/cr.h index

[Devel] [PATCH 4/8] cr_tests: epoll: Cleanup libeptest.[oa]

2010-03-09 Thread Matt Helsley
These weren't being cleaned up. Signed-off-by: Matt Helsley matth...@us.ibm.com --- epoll/module.mk |2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/epoll/module.mk b/epoll/module.mk index 2e5d8c6..260e549 100644 --- a/epoll/module.mk +++ b/epoll/module.mk @@ -9,3 +9,5

[Devel] Re: [PATCH RFC linux-cr] add rpid to ckpt_pids struct

2010-03-09 Thread Serge E. Hallyn
Quoting Matt Helsley (matth...@us.ibm.com): On Tue, Mar 09, 2010 at 03:04:51PM -0600, Serge E. Hallyn wrote: When we restart an application, we won't try to restore the original pid in the parent pid_ns, so we don't checkpoint that pid. However, if we are going to dump mount info from

[Devel] Re: [PATCH RFC linux-cr] add rpid to ckpt_pids struct

2010-03-09 Thread Matt Helsley
On Tue, Mar 09, 2010 at 03:04:51PM -0600, Serge E. Hallyn wrote: When we restart an application, we won't try to restore the original pid in the parent pid_ns, so we don't checkpoint that pid. However, if we are going to dump mount info from userspace using /proc/pid/mountinfo, then it will

[Devel] Re: [PATCH 1/8] cr_tests: crcounter: Don't report bogus waits

2010-03-09 Thread Serge E. Hallyn
Quoting Matt Helsley (matth...@us.ibm.com): This outputs a bunch of garbage but according to the comments don't absolutely need this wait anyway. So redirect stderr for the bash wait to /dev/null. Signed-off-by: Matt Helsley matth...@us.ibm.com All applied, thanks. -serge

[Devel] Re: [PATCH -mmotm 0/5] memcg: per cgroup dirty limit (v6)

2010-03-09 Thread Balbir Singh
* Andrea Righi ari...@develer.com [2010-03-10 00:00:31]: Control the maximum amount of dirty pages a cgroup can have at any given time. Per cgroup dirty limit is like fixing the max amount of dirty (hard to reclaim) page cache used by any cgroup. So, in case of multiple cgroup writers,

[Devel] Re: [PATCH mmotm 2.5/4] memcg: disable irq at page cgroup lock (Re: [PATCH -mmotm 3/4] memcg: dirty pages accounting and limiting infrastructure)

2010-03-09 Thread Daisuke Nishimura
Please please measure the performance overhead of this change. here. I made a patch below and measured the time(average of 10 times) of kernel build on tmpfs(make -j8 on 8 CPU machine with 2.6.33 defconfig). before - root cgroup: 190.47 sec - child

[Devel] Re: [PATCH mmotm 2.5/4] memcg: disable irq at page cgroup lock (Re: [PATCH -mmotm 3/4] memcg: dirty pages accounting and limiting infrastructure)

2010-03-09 Thread Balbir Singh
* nishim...@mxp.nes.nec.co.jp nishim...@mxp.nes.nec.co.jp [2010-03-10 10:43:09]: Please please measure the performance overhead of this change. here. I made a patch below and measured the time(average of 10 times) of kernel build on tmpfs(make -j8 on 8 CPU machine