If we abort the container start, and don't wait for the init task to be reaped after we kill it, then we can't remove the container cgroup because it is not empty.
Signed-off-by: Serge Hallyn <serge.hal...@ubuntu.com> --- src/lxc/start.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/lxc/start.c b/src/lxc/start.c index d43d580..5092b51 100644 --- a/src/lxc/start.c +++ b/src/lxc/start.c @@ -451,9 +451,12 @@ static void lxc_fini(const char *name, struct lxc_handler *handler) void lxc_abort(const char *name, struct lxc_handler *handler) { + int ret, status; + lxc_set_state(name, handler, ABORTING); if (handler->pid > 0) kill(handler->pid, SIGKILL); + while ((ret = waitpid(-1, &status, 0)) > 0) ; } #include <sys/reboot.h> -- 1.7.9.5 ------------------------------------------------------------------------------ Introducing AppDynamics Lite, a free troubleshooting tool for Java/.NET Get 100% visibility into your production application - at no cost. Code-level diagnostics for performance bottlenecks with <2% overhead Download for free and get started troubleshooting in minutes. http://p.sf.net/sfu/appdyn_d2d_ap1 _______________________________________________ Lxc-devel mailing list Lxc-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/lxc-devel