Difference between revisions of "External mount devices"
(Created page with "Describe the --external dev[xxx]:yyy option Category:Empty articles") |
(→Restore: improve wording) |
||
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
− | + | By default, CRIU can not checkpoint a mount namespace with some real block devices mounted inside. This is done because the block device is an external resource, it can not be available during restore, or its identification (minor:major or name) can be different. | |
− | [[Category: | + | To checkpointe/restore this setup, using the <code>--external dev</code> option (or an equivalent [[RPC]] field <code>opts.external</code>). |
+ | |||
+ | == Dump == | ||
+ | |||
+ | On dump, if an external mount device is found, CRIU rejects the dump with an error message that external mount devices are not allowed. | ||
+ | |||
+ | To resolve this, one need to explicitly tell CRIU to allow it. The syntax is: | ||
+ | |||
+ | criu dump ... --external dev[''minor''/''major'']:''name'' | ||
+ | |||
+ | This means to allow checkpoint of mount(s) for device identified by ''minor'' and ''major'' numbers pair. CRIU saves the device to [[images]] under a specified ''name'', which is to be used upon restore. | ||
+ | |||
+ | == Restore == | ||
+ | |||
+ | To restore an image with block devices mounted inside a mount namespace, one needs to also use <code>--external dev</code>. The syntax is: | ||
+ | |||
+ | criu restore ... --external dev[''name'']:''/dev/path'' | ||
+ | |||
+ | This means that a block device, which was dumped to an image under ''name'', is to be restored using the real device identified by ''/dev/path''. | ||
+ | |||
+ | [[Category:HOWTO]] | ||
+ | [[Category:API]] | ||
+ | [[Category:Files]] | ||
+ | [[Category:External]] |
Latest revision as of 01:41, 2 November 2016
By default, CRIU can not checkpoint a mount namespace with some real block devices mounted inside. This is done because the block device is an external resource, it can not be available during restore, or its identification (minor:major or name) can be different.
To checkpointe/restore this setup, using the --external dev
option (or an equivalent RPC field opts.external
).
Dump[edit]
On dump, if an external mount device is found, CRIU rejects the dump with an error message that external mount devices are not allowed.
To resolve this, one need to explicitly tell CRIU to allow it. The syntax is:
criu dump ... --external dev[minor/major]:name
This means to allow checkpoint of mount(s) for device identified by minor and major numbers pair. CRIU saves the device to images under a specified name, which is to be used upon restore.
Restore[edit]
To restore an image with block devices mounted inside a mount namespace, one needs to also use --external dev
. The syntax is:
criu restore ... --external dev[name]:/dev/path
This means that a block device, which was dumped to an image under name, is to be restored using the real device identified by /dev/path.