[libvirt] [PATCH 1/8] qemu: snapshot: Require support of 'transaction' command for external snapshots
Ján Tomko
jtomko at redhat.com
Thu Jul 12 13:49:55 UTC 2018
On Tue, Jul 03, 2018 at 02:32:59PM +0200, Peter Krempa wrote:
>While qemu supports the 'transaction' command since v1.1.0
>(52e7c241ac766406f05fa) and the 'blockdev-snapshot-sync' command since
>v0.14.0-rc0 we need to keep the capability bits present since some qemu
>downstreams (RHEL/CentOS 7 for example) chose to cripple qemu by
>arbitrarily compile out some stuff which was already present at that
s/compile/compiling/
>time.
>
>To simplify the crazy code just require both commands to be present at
>the beginning of a external snapshot so that we can remove the case when
s/a external/an external/
>'transaction' would not be supported.
>
>This also allows to drop any logic connected to the
>VIR_DOMAIN_SNAPSHOT_CREATE_ATOMIC flag since snapshots are atomic with
>the 'transaction' command.
>
>Signed-off-by: Peter Krempa <pkrempa at redhat.com>
>---
> src/qemu/qemu_driver.c | 62 +++++++++++---------------------------------------
> 1 file changed, 13 insertions(+), 49 deletions(-)
>
>@@ -15265,13 +15234,8 @@ qemuDomainSnapshotCreateActiveExternal(virQEMUDriverPtr driver,
> qemuDomainObjSetAsyncJobMask(vm, QEMU_JOB_DEFAULT_MASK);
> }
>
>- /* now the domain is now paused if:
>- * - if a memory snapshot was requested
>- * - an atomic snapshot was requested AND
>- * qemu does not support transactions
>- *
>- * Next we snapshot the disks.
>- */
>+ /* now the domain is now paused if a memory snapshot was requested */
Double now.
>+
> if ((ret = qemuDomainSnapshotCreateDiskActive(driver, vm, snap, flags,
> QEMU_ASYNC_JOB_SNAPSHOT)) < 0)
> goto cleanup;
Reviewed-by: Ján Tomko <jtomko at redhat.com>
Jano
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: Digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20180712/c908be8f/attachment-0001.sig>
More information about the libvir-list
mailing list