mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-03-31 22:50:30 +03:00
qemu_saveimage: add "sparse" to supported save image formats
Extend the list of formats to include "sparse", which uses QEMU's mapped-ram stream format [1] to write guest memory blocks at fixed offsets in the save image file. [1] https://gitlab.com/qemu-project/qemu/-/blob/master/docs/devel/migration/mapped-ram.rst?ref_type=heads Signed-off-by: Jim Fehlig <jfehlig@suse.com> Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
This commit is contained in:
parent
c939bf537e
commit
fa68f78f13
@ -613,11 +613,18 @@
|
||||
# disk space when saving large memory guests. Various compression formats are
|
||||
# available for specifying a save image compressed by the named algorithm.
|
||||
# Supported compression formats are "zstd", "lzop", "gzip", "bzip2", and "xz".
|
||||
# The "sparse" format uses QEMU's mapped-ram stream format to write guest memory
|
||||
# blocks at fixed offsets in the save image file.
|
||||
|
||||
# save_image_format can be used to select the desired save format. "raw" is
|
||||
# the traditional format used by libvirt and is also the default. The
|
||||
# compression formats can be used to save disk space, although this typically
|
||||
# results in longer save and restore times.
|
||||
# results in longer save and restore times. The "sparse" format results in a
|
||||
# save image file that is roughly the logical size of the guest's memory,
|
||||
# although on-disk size is a function of guest memory usage. The "sparse"
|
||||
# format is useful when a predictable maximum save image file size is
|
||||
# needed. The other formats can result in a save image file much larger
|
||||
# than guest memory if the guest runs a memory intensive workload.
|
||||
#
|
||||
# save_image_format is used with 'virsh save' or 'virsh managedsave'. It is
|
||||
# an error if the specified save_image_format is not valid, or cannot be
|
||||
|
@ -45,6 +45,7 @@ VIR_ENUM_IMPL(qemuSaveFormat,
|
||||
"xz",
|
||||
"lzop",
|
||||
"zstd",
|
||||
"sparse",
|
||||
);
|
||||
|
||||
static inline void
|
||||
|
@ -42,6 +42,7 @@ typedef enum {
|
||||
QEMU_SAVE_FORMAT_XZ = 3,
|
||||
QEMU_SAVE_FORMAT_LZOP = 4,
|
||||
QEMU_SAVE_FORMAT_ZSTD = 5,
|
||||
QEMU_SAVE_FORMAT_SPARSE = 6,
|
||||
/* Note: add new members only at the end.
|
||||
These values are used in the on-disk format.
|
||||
Do not change or re-use numbers. */
|
||||
|
Loading…
x
Reference in New Issue
Block a user