2
0
mirror of https://github.com/checkpoint-restore/criu synced 2025-08-30 05:48:05 +00:00

mount: don't dump content for external mounts

External mounts are provided by an user and CRIU doesn't
need to restore their content.

https://github.com/xemul/criu/issues/299

Reported-by: Stéphane Graber
Signed-off-by: Andrei Vagin <avagin@virtuozzo.com>
This commit is contained in:
Andrei Vagin 2017-03-23 08:12:12 +03:00 committed by Pavel Emelyanov
parent ceaa66034c
commit d29b00d820

View File

@ -1263,13 +1263,14 @@ static int dump_one_mountpoint(struct mount_info *pm, struct cr_img *img)
if (me.fstype == FSTYPE__AUTO)
me.fsname = pm->fsname;
if (!pm->external) {
if (!pm->dumped && dump_one_fs(pm))
return -1;
if (!pm->dumped && dump_one_fs(pm))
return -1;
if (!fsroot_mounted(pm) &&
pm->fstype->check_bindmount && pm->fstype->check_bindmount(pm))
return -1;
if (!fsroot_mounted(pm) &&
pm->fstype->check_bindmount && pm->fstype->check_bindmount(pm))
return -1;
}
if (pm->mnt_id == CRTIME_MNT_ID) {
pr_info("Skip dumping cr-time mountpoint: %s\n", pm->mountpoint);