]> xenbits.xensource.com Git - libvirt.git/commit
qemu: backup: Fix handling of backing store for backup target images
authorPeter Krempa <pkrempa@redhat.com>
Tue, 31 Mar 2020 13:43:46 +0000 (15:43 +0200)
committerPeter Krempa <pkrempa@redhat.com>
Tue, 14 Apr 2020 16:37:05 +0000 (18:37 +0200)
commit4aea6f42fe32175ce0cb9015913db536097130e4
tree70e99a0b39d4471a504a525ceaa81b4eca37d801
parent818652619d382278dc0a39a967820b6540896022
qemu: backup: Fix handling of backing store for backup target images

We always tried to install backing store for the image even if it didn't
make sense, e.g. for a full backup into a raw image. Additionally we
didn't record the backing file into the qcow2 metadata so the image
itself contained the diff of data but reading from it would be
incomplete as it depends on the backing image.

This patch fixes both issues by carefully installing the correct backing
file when appropriate and also recording it into the metadata when
creating the image.

https://bugzilla.redhat.com/show_bug.cgi?id=1813310

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
src/qemu/qemu_backup.c