*/
# define VIR_MIGRATE_PARAM_COMPRESSION_XBZRLE_CACHE "compression.xbzrle.cache"
+/**
+ * VIR_MIGRATE_PARAM_AUTO_CONVERGE_INITIAL:
+ *
+ * virDomainMigrate* params field: the initial percentage guest CPUs are
+ * throttled to when auto-convergence decides migration is not converging.
+ * As VIR_TYPED_PARAM_INT.
+ */
+# define VIR_MIGRATE_PARAM_AUTO_CONVERGE_INITIAL "auto_converge.initial"
+
+/**
+ * VIR_MIGRATE_PARAM_AUTO_CONVERGE_INCREMENT:
+ *
+ * virDomainMigrate* params field: the increment added to
+ * VIR_MIGRATE_PARAM_AUTO_CONVERGE_INITIAL whenever the hypervisor decides
+ * the current rate is not enough to ensure convergence of the migration.
+ * As VIR_TYPED_PARAM_INT.
+ */
+# define VIR_MIGRATE_PARAM_AUTO_CONVERGE_INCREMENT "auto_converge.increment"
+
/* Domain migration. */
virDomainPtr virDomainMigrate (virDomainPtr domain, virConnectPtr dconn,
unsigned long flags, const char *dname,
.type = VSH_OT_INT,
.help = N_("page cache size for xbzrle compression")
},
+ {.name = "auto-converge-initial",
+ .type = VSH_OT_INT,
+ .help = N_("initial CPU throttling rate for auto-convergence")
+ },
+ {.name = "auto-converge-increment",
+ .type = VSH_OT_INT,
+ .help = N_("CPU throttling rate increment for auto-convergence")
+ },
{.name = NULL}
};
VIR_FREE(xml);
}
+ if ((rv = vshCommandOptInt(ctl, cmd, "auto-converge-initial", &intOpt)) < 0) {
+ goto out;
+ } else if (rv > 0) {
+ if (virTypedParamsAddInt(¶ms, &nparams, &maxparams,
+ VIR_MIGRATE_PARAM_AUTO_CONVERGE_INITIAL,
+ intOpt) < 0)
+ goto save_error;
+ }
+
+ if ((rv = vshCommandOptInt(ctl, cmd, "auto-converge-increment", &intOpt)) < 0) {
+ goto out;
+ } else if (rv > 0) {
+ if (virTypedParamsAddInt(¶ms, &nparams, &maxparams,
+ VIR_MIGRATE_PARAM_AUTO_CONVERGE_INCREMENT,
+ intOpt) < 0)
+ goto save_error;
+ }
+
if (vshCommandOptBool(cmd, "live"))
flags |= VIR_MIGRATE_LIVE;
if (vshCommandOptBool(cmd, "p2p"))
=item B<migrate> [I<--live>] [I<--offline>] [I<--direct>] [I<--p2p> [I<--tunnelled>]]
[I<--persistent>] [I<--undefinesource>] [I<--suspend>] [I<--copy-storage-all>]
[I<--copy-storage-inc>] [I<--change-protection>] [I<--unsafe>] [I<--verbose>]
-[I<--abort-on-error>] [I<--auto-converge>] [I<--postcopy>]
-[I<--postcopy-after-precopy>] I<domain> I<desturi> [I<migrateuri>]
-[I<graphicsuri>] [I<listen-address>] [I<dname>]
+[I<--abort-on-error>] [I<--postcopy>] [I<--postcopy-after-precopy>]
+I<domain> I<desturi> [I<migrateuri>] [I<graphicsuri>] [I<listen-address>] [I<dname>]
[I<--timeout> B<seconds> [I<--timeout-suspend> | I<--timeout-postcopy>]]
[I<--xml> B<file>] [I<--migrate-disks> B<disk-list>] [I<--disks-port> B<port>]
[I<--compressed>] [I<--comp-methods> B<method-list>]
[I<--comp-mt-level>] [I<--comp-mt-threads>] [I<--comp-mt-dthreads>]
-[I<--comp-xbzrle-cache>]
+[I<--comp-xbzrle-cache>] [I<--auto-converge>] [I<auto-converge-initial>]
+[I<auto-converge-increment>]
Migrate domain to another host. Add I<--live> for live migration; <--p2p>
for peer-2-peer migration; I<--direct> for direct migration; or I<--tunnelled>
hypervisor lacks change protection support. I<--verbose> displays the progress
of migration. I<--abort-on-error> cancels
the migration if a soft error (for example I/O error) happens during the
-migration. I<--auto-converge> forces convergence during live migration.
-I<--postcopy> enables post-copy logic in migration, but does not
+migration. I<--postcopy> enables post-copy logic in migration, but does not
actually start post-copy, i.e., migration is started in pre-copy mode.
Once migration is running, the user may switch to post-copy using the
B<migrate-postcopy> command sent from another virsh instance or use
I<--postcopy-after-precopy> to let libvirt automatically switch to
post-copy after the first pass of pre-copy is finished.
+I<--auto-converge> forces convergence during live migration. The initial
+guest CPU throttling rate can be set with I<auto-converge-initial>. If the
+initial throttling rate is not enough to ensure convergence, the rate is
+periodically increased by I<auto-converge-increment>.
+
B<Note>: Individual hypervisors usually do not support all possible types of
migration. For example, QEMU does not support direct migration.