mirror of
https://github.com/checkpoint-restore/criu.git
synced 2026-07-28 20:42:49 +00:00
mounts: Make sure all namespaces has the same root source
Currently we support nested mount namespaces, only if all of them have the same path to the root. crtools doesn't mount root, so it should be bind-mounted for all namespaces. Signed-off-by: Andrey Vagin <avagin@openvz.org> Signed-off-by: Pavel Emelyanov <xemul@parallels.com>
This commit is contained in:
parent
1edfe53b71
commit
898335ba32
1 changed files with 6 additions and 0 deletions
6
mount.c
6
mount.c
|
|
@ -233,6 +233,12 @@ static struct mount_info *mnt_build_ids_tree(struct mount_info *list)
|
|||
m->mnt_id, m->parent_mnt_id, m->mountpoint,
|
||||
root ? "found" : "not found");
|
||||
if (root && m->is_ns_root) {
|
||||
if (!mounts_equal(root, m, true) ||
|
||||
strcmp(root->root, m->root)) {
|
||||
pr_err("Nested mount namespaces with different roots are not supported yet");
|
||||
return NULL;
|
||||
}
|
||||
|
||||
/*
|
||||
* A root of a sub mount namespace is
|
||||
* mounted in a temporary directory in the
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue