[Devel] [PATCH] mounts: support NFS bind-mounts in the same shared group
Stanislav Kinsburskiy
skinsbursky at virtuozzo.com
Wed Jul 19 10:43:26 MSK 2017
Initial patch was supporting only slave mounts as bind-mounts.
https://jira.sw.ru/browse/PSBM-68663
Signed-off-by: Stanislav Kinsburskiy <skinsbursky at virtuozzo.com>
---
criu/mount.c | 13 ++++++++-----
1 file changed, 8 insertions(+), 5 deletions(-)
diff --git a/criu/mount.c b/criu/mount.c
index 3abdb6e..7ed5d6e 100644
--- a/criu/mount.c
+++ b/criu/mount.c
@@ -768,11 +768,14 @@ static bool unsupported_nfs_bindmounts(const struct mount_info *m)
const struct mount_info *bm;
list_for_each_entry(bm, &m->mnt_bind, mnt_bind) {
- if (bm->shared_id != m->master_id) {
- pr_err("Bind-mount %s has another shared "
- "group, than %s: %d != %d\n",
- bm->mountpoint, m->mountpoint,
- bm->shared_id, m->master_id);
+ if ((bm->shared_id != m->master_id) &&
+ (bm->shared_id != m->shared_id)) {
+ pr_err("NFS bind-mount %s (id %d) has another shared "
+ "group, than %s (id %d): %d != %d (!= %d)\n",
+ bm->mountpoint, bm->mnt_id,
+ m->mountpoint, m->mnt_id,
+ bm->shared_id, m->master_id,
+ m->shared_id);
return true;
}
if (unsupported_nfs_mount(bm))
More information about the Devel
mailing list