[libvirt] [PATCH 4/5] qemu: Unset the genid start change flag for revert force
Michal Privoznik
mprivozn at redhat.com
Wed Jun 20 13:20:31 UTC 2018
On 06/20/2018 12:54 AM, John Ferlan wrote:
> If the the snapshot revert involves a forced revert option, then
> let's not cause startup to change the genid flag in order to signify
> that we're still running the same/previous guest and not some
> snapshot reversion.
>
> https://bugzilla.redhat.com/show_bug.cgi?id=1149445
>
> Signed-off-by: John Ferlan <jferlan at redhat.com>
> ---
> src/qemu/qemu_driver.c | 6 ++++--
> 1 file changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c
> index 01011906d1..f737f4d350 100644
> --- a/src/qemu/qemu_driver.c
> +++ b/src/qemu/qemu_driver.c
> @@ -16136,12 +16136,14 @@ qemuDomainRevertToSnapshot(virDomainSnapshotPtr snapshot,
> }
>
> /* If using VM GenID, there is no way currently to change
> - * the genid for the running guest, so set an error and
> - * mark as incompatible. */
> + * the genid for the running guest, so set an error,
> + * mark as incompatible, and don't allow change of genid
> + * if the revert force flag would start the guest again. */
> if (compatible && config->genidRequested) {
> virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
> _("domain genid update requires restart"));
> compatible = false;
> + start_flags &= ~VIR_QEMU_PROCESS_START_GEN_VMID;
Pre-existing, but what is the point of this virReportError() if it does
not cause domain starting?
Michal
More information about the libvir-list
mailing list