mirror of
https://github.com/checkpoint-restore/criu.git
synced 2026-07-28 20:42:49 +00:00
zdtm: make root mount private in criu mntns
If root mount in criu mntns is slave, it would be slave of host mount
where criu is stored, so if someone mounts something in subdir of
{criu-dir}/test/ on host while tests are running this mount can
influence the test as it appears on top of root mount in criu mntns.
1) With mount-compat this mount can get into restored test mntns, which
means wrong restore, as this mount was not there on dump.
2) With mount-v2 this mount would just fail container restore, as root
container mount is mounted non-recursively to protect from unexpected
mounts appear after restore.
Signed-off-by: Pavel Tikhomirov <ptikhomirov@virtuozzo.com>
This commit is contained in:
parent
70a9cd6fbf
commit
d12e2364c4
1 changed files with 1 additions and 1 deletions
|
|
@ -267,7 +267,7 @@ class ns_flavor:
|
|||
|
||||
def init(self, l_bins, x_bins):
|
||||
subprocess.check_call(
|
||||
["mount", "--make-slave", "--bind", ".", self.root])
|
||||
["mount", "--make-private", "--bind", ".", self.root])
|
||||
self.root_mounted = True
|
||||
|
||||
if not os.access(self.root + "/.constructed", os.F_OK):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue