]> xenbits.xensource.com Git - libvirt.git/commitdiff
Make --postcopy flag mandatory with --postcopy-after-precopy
authorKothapally Madhu Pavan <kmp@linux.vnet.ibm.com>
Fri, 2 Sep 2016 11:52:13 +0000 (07:52 -0400)
committerJiri Denemark <jdenemar@redhat.com>
Fri, 2 Sep 2016 12:42:53 +0000 (14:42 +0200)
--postcopy-after-precopy is just an aditional flag for
postcopy migration.

Signed-off-by: Kothapally Madhu Pavan <kmp@linux.vnet.ibm.com>
tools/virsh-domain.c
tools/virsh.pod

index c9ad0d7a52b255e9c66a1907c346d29429631472..a614512838f8057d6383f2b9e20077c0b3c1a811 100644 (file)
@@ -10318,10 +10318,10 @@ cmdMigrate(vshControl *ctl, const vshCmd *cmd)
     }
 
     if (vshCommandOptBool(cmd, "postcopy-after-precopy")) {
-        if (!live_flag) {
+        if (!vshCommandOptBool(cmd, "postcopy")) {
             virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED, "%s",
-                          _("post-copy migration is not supported with "
-                            "non-live or paused migration"));
+                          _("--postcopy-after-precopy can only be used with "
+                            "--postcopy"));
             goto cleanup;
         }
         iterEvent = virConnectDomainEventRegisterAny(
index 1e36ee16ae015bff60dfbf40dd7f3375c076f32f..e056eb0f51d162ff68882ca8b8d1a3a255b6a219 100644 (file)
@@ -1617,8 +1617,8 @@ 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<--postcopy-after-precopy> along with I<--postcopy> 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