Re: [Qemu-devel] [PATCH 3/10] Add bdrv_flush_all()

Anthony Liguori
2008-09-10T15:20:22Z

Glauber Costa wrote:
> On Wed, Sep 10, 2008 at 10:26 AM, Chris Lalancette <clalance@redhat.com> wrote:
>
>> Anthony Liguori wrote:
>>
>>> This patch adds a bdrv_flush_all() function. It's necessary to ensure that all
>>> IO operations have been flushed to disk before completely a live migration.
>>>
>>> N.B. we don't actually use this now. We really should flush the block drivers
>>> using an live savevm callback to avoid unnecessary guest down time.
>>>
>> Simple enough, and follows the pattern in the KVM migration.
>>
>> Chris Lalancette
>>
>>
> sounds ok.
>

I'm actually liking bdrv_flush_all() less and less. If there are any
outstanding IO requests, it will increase the down time associated with
live migration. I think we definitely need to add a live save handler
that waits until there are no outstanding IO requests to converge. I'm
concerned though that it's not totally unreasonable to expect a guest to
always have an IO request in flight. That leads me to think that maybe
we should be cancelling outstanding requests, and somehow saving their
state?

Regards,

Anthony Liguori