On Fri, Jan 05, 2024 at 17:31:50 +0100, Jiri Denemark wrote:
On Fri, Jan 05, 2024 at 17:11:57 +0100, Peter Krempa wrote:
> On Fri, Jan 5, 2024 at 4:55 PM Jiri Denemark <jdenemar(a)redhat.com> wrote:
>
> > During post-copy migration (once it actually switches to post-copy mode)
> > dirty memory pages are continued to be migrated iteratively, while the
> > destination can explicitly request a specific page to be migrated before
> > the iterative process gets to it (which happens when a guest wants to
> > read a page that was not migrated yet). Without this flag explicitly
> > requested pages need to wait until all other pages already queued are
> > transferred. Enabling this flag will instruct the hypervisor to create a
> > separate migration channel for explicitly requested pages so that they
> > can preempt the queue.
> >
> > Signed-off-by: Jiri Denemark <jdenemar(a)redhat.com>
> > ---
> > include/libvirt/libvirt-domain.h | 8 ++++++++
> > 1 file changed, 8 insertions(+)
> >
> > diff --git a/include/libvirt/libvirt-domain.h
> > b/include/libvirt/libvirt-domain.h
> > index 30cce85b29..ee23ae97a5 100644
> > --- a/include/libvirt/libvirt-domain.h
> > +++ b/include/libvirt/libvirt-domain.h
> > @@ -1100,6 +1100,14 @@ typedef enum {
> > * Since: 8.5.0
> > */
> > VIR_MIGRATE_ZEROCOPY = (1 << 20),
> > +
> > + /* Allow post-copy requests to preempt normal migration stream. This
> > way
> > + * page faults on the destination hosts caused by accessing a memory
> > page
> > + * that was not migrated yet should be handled faster.
> >
> > Based on this description and the commit message there doesn't seem to be
> any reason why the user should not enable that. And in that case I think
> the users will be better off when libvirt auto-enables this.
Well yes, ideally you want this enabled all the time. But Peter Xu did
not sound like it was ready for being always enabled. I guess I'll check
with him if it's still the case or not.
So Peter confirmed we may enable postcopy-preempt for all post-copy
migrations (as long as the capability is supported). Reworked patch
series is coming in a few moments.
Jirka