cr: don't restore net namespace by default
since runc don't manage net device and their configuration, checkpoint also don't dump net namespace by default, so set 'nsmask = unix.CLONE_NEWNET' by default in restore. Or if user do not pass 'empty-ns network', criu will cost extra time in restore. Signed-off-by: Ace-Tang <aceapril@126.com>
This commit is contained in:
parent
20aff4f048
commit
4803faf00e
|
@ -109,6 +109,9 @@ using the runc checkpoint command.`,
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
options := criuOptions(context)
|
options := criuOptions(context)
|
||||||
|
if err := setEmptyNsMask(context, options); err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
status, err := startContainer(context, spec, CT_ACT_RESTORE, options)
|
status, err := startContainer(context, spec, CT_ACT_RESTORE, options)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
|
|
Loading…
Reference in New Issue