|
|
6d3351 |
From 3a9924b5ea76945b0df16cd21fd0acbb6fe152fc Mon Sep 17 00:00:00 2001
|
|
|
6d3351 |
Message-Id: <3a9924b5ea76945b0df16cd21fd0acbb6fe152fc@dist-git>
|
|
|
6d3351 |
From: Jiri Denemark <jdenemar@redhat.com>
|
|
|
6d3351 |
Date: Wed, 31 May 2017 10:08:28 +0200
|
|
|
6d3351 |
Subject: [PATCH] qemu: Set operation on completed migration job
|
|
|
6d3351 |
|
|
|
6d3351 |
Without this patch libvirt would just report the operation of a
|
|
|
6d3351 |
completed job as "unknown" instead of "incoming migration".
|
|
|
6d3351 |
|
|
|
6d3351 |
https://bugzilla.redhat.com/show_bug.cgi?id=1457052
|
|
|
6d3351 |
|
|
|
6d3351 |
Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
|
|
|
6d3351 |
(cherry picked from commit 49d30bc2e292785bf2edc121c12bc5c10264d1d4)
|
|
|
6d3351 |
Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
|
|
|
6d3351 |
---
|
|
|
6d3351 |
src/qemu/qemu_migration_cookie.c | 4 ++++
|
|
|
6d3351 |
1 file changed, 4 insertions(+)
|
|
|
6d3351 |
|
|
|
6d3351 |
diff --git a/src/qemu/qemu_migration_cookie.c b/src/qemu/qemu_migration_cookie.c
|
|
|
6d3351 |
index 12887892db..559b1f0c15 100644
|
|
|
6d3351 |
--- a/src/qemu/qemu_migration_cookie.c
|
|
|
6d3351 |
+++ b/src/qemu/qemu_migration_cookie.c
|
|
|
6d3351 |
@@ -1292,6 +1292,7 @@ qemuMigrationEatCookie(virQEMUDriverPtr driver,
|
|
|
6d3351 |
int cookieinlen,
|
|
|
6d3351 |
unsigned int flags)
|
|
|
6d3351 |
{
|
|
|
6d3351 |
+ qemuDomainObjPrivatePtr priv = dom->privateData;
|
|
|
6d3351 |
qemuMigrationCookiePtr mig = NULL;
|
|
|
6d3351 |
|
|
|
6d3351 |
/* Parse & validate incoming cookie (if any) */
|
|
|
6d3351 |
@@ -1340,6 +1341,9 @@ qemuMigrationEatCookie(virQEMUDriverPtr driver,
|
|
|
6d3351 |
}
|
|
|
6d3351 |
}
|
|
|
6d3351 |
|
|
|
6d3351 |
+ if (flags & QEMU_MIGRATION_COOKIE_STATS && mig->jobInfo)
|
|
|
6d3351 |
+ mig->jobInfo->operation = priv->job.current->operation;
|
|
|
6d3351 |
+
|
|
|
6d3351 |
return mig;
|
|
|
6d3351 |
|
|
|
6d3351 |
error:
|
|
|
6d3351 |
--
|
|
|
6d3351 |
2.13.1
|
|
|
6d3351 |
|