- conf, docs: Add support for direct and extended tlbflush features (RHEL-7122) - qemu: Add support for direct and extended tlbflush features (RHEL-7122) - conf: refactor hyperv features formatting (RHEL-7122) - conf: Adjust hyperv tlbflush formatting (RHEL-7122) - qemu_migration: Do not consider post-copy active in postcopy-recover (RHEL-73085) Resolves: RHEL-7122, RHEL-73085
58 lines
2.5 KiB
Diff
58 lines
2.5 KiB
Diff
From 50925d10476e7a61d25de6e501a4954bb427c327 Mon Sep 17 00:00:00 2001
|
|
Message-ID: <50925d10476e7a61d25de6e501a4954bb427c327.1737030652.git.jdenemar@redhat.com>
|
|
From: Jiri Denemark <jdenemar@redhat.com>
|
|
Date: Fri, 10 Jan 2025 18:25:20 +0100
|
|
Subject: [PATCH] qemu_migration: Do not consider post-copy active in
|
|
postcopy-recover
|
|
|
|
The postcopy-recover migration state in QEMU means a connection for the
|
|
migration stream was established. Depending on the schedulers on both
|
|
hosts a relative timing of the corresponding MIGRATION event on the
|
|
source host and the destination host may differ. Specifically it's
|
|
possible that the source sees postcopy-recover while the destination is
|
|
still in postcopy-paused.
|
|
|
|
Currently the Perform phase on the source host ends when we get
|
|
postcopy-recover event and the Finish phase on the destination host is
|
|
called. If this is fast enough we can still see postcopy-paused state
|
|
when the Finish phase starts waiting for migration to complete. This is
|
|
interpreted as a failure and reported back to the caller. Even though
|
|
the recovery may actually start just a few moments later.
|
|
|
|
To avoid this race we now don't consider post-copy migration active in
|
|
postcopy-recover state and keep waiting for postcopy-active event (in
|
|
the success path). Thus the Finish phase is entered only after the
|
|
migration switches to postcopy-active. In this state QEMU guarantees the
|
|
destination already switched at least to postcopy-recover and we won't
|
|
be confused be seeing an old postcopy-failed state.
|
|
|
|
https://issues.redhat.com/browse/RHEL-73085
|
|
|
|
Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
|
|
Reviewed-by: Michal Privoznik <mprivozn@redhat.com
|
|
(cherry picked from commit a71985f6f3fec52e2a6f4e3991ed9bf6280bdb4b)
|
|
Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
|
|
---
|
|
src/qemu/qemu_migration.c | 2 +-
|
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
|
|
diff --git a/src/qemu/qemu_migration.c b/src/qemu/qemu_migration.c
|
|
index 26a92d8ee2..b2b172a26c 100644
|
|
--- a/src/qemu/qemu_migration.c
|
|
+++ b/src/qemu/qemu_migration.c
|
|
@@ -1872,11 +1872,11 @@ qemuMigrationUpdateJobType(virDomainJobData *jobData)
|
|
|
|
switch ((qemuMonitorMigrationStatus) priv->stats.mig.status) {
|
|
case QEMU_MONITOR_MIGRATION_STATUS_POSTCOPY:
|
|
- case QEMU_MONITOR_MIGRATION_STATUS_POSTCOPY_RECOVER:
|
|
jobData->status = VIR_DOMAIN_JOB_STATUS_POSTCOPY;
|
|
break;
|
|
|
|
case QEMU_MONITOR_MIGRATION_STATUS_POSTCOPY_RECOVER_SETUP:
|
|
+ case QEMU_MONITOR_MIGRATION_STATUS_POSTCOPY_RECOVER:
|
|
jobData->status = VIR_DOMAIN_JOB_STATUS_POSTCOPY_RECOVER;
|
|
break;
|
|
|
|
--
|
|
2.47.1
|