]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
Introduce VIR_MIGRATE_POSTCOPY_RESUME flag
authorJiri Denemark <jdenemar@redhat.com>
Tue, 10 May 2022 13:20:25 +0000 (15:20 +0200)
committerJiri Denemark <jdenemar@redhat.com>
Tue, 7 Jun 2022 15:40:20 +0000 (17:40 +0200)
This flag can be used to restart post-copy migration once it failed
because of a broken connection.

Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
include/libvirt/libvirt-domain.h
src/libvirt-domain.c

index caf99d41bcc4cfde55e80e2a866d7e00bde045d6..e7020f19cc7f1da71ce3412331a4fb741b8fd097 100644 (file)
@@ -1084,6 +1084,11 @@ typedef enum {
       */
     VIR_MIGRATE_NON_SHARED_SYNCHRONOUS_WRITES = (1 << 18),
 
+    /* Resume migration which failed in post-copy phase.
+     *
+     * Since: 8.5.0
+     */
+    VIR_MIGRATE_POSTCOPY_RESUME = (1 << 19),
 } virDomainMigrateFlags;
 
 
index 10fc3188fe59196ee7564ef74701f092f5fca2c4..a5f18f953e0749e726d4025bb4771f1e3b292e3e 100644 (file)
@@ -9771,6 +9771,12 @@ virDomainMigrateGetMaxSpeed(virDomainPtr domain,
  * this, libvirt will refuse to cancel post-copy migration via
  * virDomainAbortJob.
  *
+ * Failed post-copy migration can be recovered once the cause for the failure
+ * (e.g., a network issue) is resolved by repeating the migration with an
+ * additional VIR_MIGRATE_POSTCOPY_RESUME flag. This will recreate the
+ * connection and resume migration from the point where it failed. This step
+ * can be repeated in case the migration breaks again.
+ *
  * The following domain life cycle events are emitted during post-copy
  * migration:
  *  VIR_DOMAIN_EVENT_SUSPENDED_POSTCOPY (on the source) -- migration entered