[libvirt] [PATCH] Check for --live flag for postcopy-after-precopy migration

Jiri Denemark jdenemar at redhat.com
Wed Aug 31 11:42:27 UTC 2016


On Mon, Aug 29, 2016 at 16:42:04 +0530, Madhu Pavan wrote:
> 
> 
> On 08/27/2016 02:21 AM, Jiri Denemark wrote:
> > On Fri, Aug 26, 2016 at 21:41:31 +0200, Michal Privoznik wrote:
> >> On 26.08.2016 11:25, Kothapally Madhu Pavan wrote:
> >>> Unlike postcopy migration there is no --live flag check for
> >>> postcopy-after-precopy.
> >>>
> >>> Signed-off-by: Kothapally Madhu Pavan <kmp at linux.vnet.ibm.com>
> >>> ---
> >>>   tools/virsh-domain.c |    6 ++++++
> >>>   1 file changed, 6 insertions(+)
> >>>
> >> ACKed and pushed.
> > This doesn't make any sense. First, post-copy migration is enabled with
> > --postcopy option to migrate command and --postcopy-after-precopy is
> > just an additional flag for post-copy migration. So if virsh was to
> > report such an error, it should check for --postcopy option. But such
> > check doesn't belong to libvirt at all, the appropriate libvirt driver
> > is supposed to check for the flags and report invalid combinations.
> I have proposed this patch as the qemu driver doesn't have 
> postcopy-after-precopy
> flag and this bug can be fixed by minimal changes in libvirt. If we have 
> to check for
> invalid combinations in appropriate libvirt drivers, we need to create a 
> flag for
> postcopy-after-precopy migration. I will be happy to send another patch 
> if this is what
> needed.

Heh, you're right indeed. I think I really shouldn't try reviewing stuff
during a conference. So the place is correct, but I still think it
should be done in a different way. As I said --postcopy-after-precopy is
just an additional flag for --postcopy and thus we should check that
--postcopy is present rather than checking for --live and the error
message should reflect that (e.g., "--postcopy-after-precopy can only be
used with --postcopy").

Jirka




More information about the libvir-list mailing list