Unverified Commit 2ff023b7 by Christian Brauner Committed by Stéphane Graber

start: remove umount2()

I really fail to see the point of this and git {blame, log -S} don't really enlighten me on the reason for this as well. But I might be dense. The way I see it the only thing this line achieves is causing trouble when the container is started as root because the umount2() call will umount e.g. /usr/lib/x86_64-linux-gnu/lxc in case it is a mountpoint on the host. Note, this is because lxc_spawn() is still called in the hosts namespaces. Closes https://github.com/lxc/lxd/#3255. Signed-off-by: 's avatarChristian Brauner <christian.brauner@ubuntu.com>
parent 70f89aa1
......@@ -1259,9 +1259,6 @@ static int lxc_spawn(struct lxc_handler *handler)
if (lxc_sync_barrier_child(handler, LXC_SYNC_POST_CGROUP))
return -1;
if (detect_shared_rootfs())
umount2(handler->conf->rootfs.mount, MNT_DETACH);
if (handler->ops->post_start(handler, handler->data))
goto out_abort;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment