From: Fam Zheng <famz@redhat.com>
To: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Cc: Kevin Wolf <kwolf@redhat.com>, qemu-devel <qemu-devel@nongnu.org>,
qemu block <qemu-block@nongnu.org>, Max Reitz <mreitz@redhat.com>,
John Snow <jsnow@redhat.com>,
"gilbert >> Dr. David Alan Gilbert" <dgilbert@redhat.com>,
"Juan Q >> Juan Jose Quintela Carreira" <quintela@redhat.com>
Subject: Re: [Qemu-devel] Restoring bitmaps after failed/cancelled migration
Date: Thu, 17 May 2018 10:14:41 +0800 [thread overview]
Message-ID: <20180517021441.GG6731@lemon.usersys.redhat.com> (raw)
In-Reply-To: <25af7923-1eb0-8189-1c14-0f8f33007e6e@virtuozzo.com>
On Wed, 05/16 18:52, Vladimir Sementsov-Ogievskiy wrote:
> 16.05.2018 18:32, Kevin Wolf wrote:
> > Am 16.05.2018 um 17:10 hat Vladimir Sementsov-Ogievskiy geschrieben:
> > > 16.05.2018 15:47, Kevin Wolf wrote:
> > > > Am 14.05.2018 um 12:09 hat Vladimir Sementsov-Ogievskiy geschrieben:
> > > > > 14.05.2018 09:41, Fam Zheng wrote:
> > > > > > On Wed, 04/18 17:00, Vladimir Sementsov-Ogievskiy wrote:
> > > > > > > Is it possible, that target will change the disk, and then we return control
> > > > > > > to the source? In this case bitmaps will be invalid. So, should not we drop
> > > > > > > all the bitmaps on inactivate?
> > > > > > Yes, dropping all live bitmaps upon inactivate sounds reasonable. If the dst
> > > > > > fails to start, and we want to resume VM at src, we could (optionally?) reload
> > > > > > the persistent bitmaps, I guess.
> > > > > Reload from where? We didn't store them.
> > > > Maybe this just means that it turns out that not storing them was a bad
> > > > idea?
> > > >
> > > > What was the motivation for not storing the bitmap? The additional
> > > > downtime? Is it really that bad, though? Bitmaps should be fairly small
> > > > for the usual image sizes and writing them out should be quick.
> > > What are usual ones? A bitmap of standard granularity of 64k for 16Tb disk
> > > is ~30mb. If we have several such bitmaps it may be significant downtime.
> > We could have an in-memory bitmap that tracks which parts of the
> > persistent bitmap are dirty so that you don't have to write out the
> > whole 30 MB during the migration downtime, but can already flush most of
> > the persistent bitmap before the VM is stopped.
> >
> > Kevin
>
> Yes it looks possible. But how to control that downtime? Introduce migration
> state, with specific _pending function? However, it may be not necessary.
>
> Anyway, I think we don't need to store it.
>
> If we decided to resume source, bitmap is already in memory, why to reload
> it? If someone already killed source (which was in paused mode), it is
> inconsistent anyway and loss of dirty bitmap is not the worst possible
> problem.
>
> So, finally, it looks safe enough, just to make bitmaps on source persistent
> again (or better, introduce another way to skip storing (may be with
> additional flag, so everybody will be happy), not dropping persistent flag).
This makes some sense to me. We'll then use the current persistent flag to
indicate the bitmap "is" a persistent one, instead of "should it be persisted".
They are apparently two different properties in the case discussed in this
thread.
> And, after source resume, we have one of the following situations:
>
> 1. disk was not changed during migration, so, all is ok and we have bitmaps
> 2. disk was changed. bitmaps are inconsistent. But not only bitmaps, the
> whole vm state is inconsistent with it's disk. This case is a bug in
> management layer and it should never happen. And possibly, we need some
> separate way, to catch such cases.
Fam
prev parent reply other threads:[~2018-05-17 2:14 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-04-18 14:00 [Qemu-devel] Restoring bitmaps after failed/cancelled migration Vladimir Sementsov-Ogievskiy
2018-04-23 18:41 ` Dr. David Alan Gilbert
2018-05-11 21:23 ` John Snow
2018-05-14 9:55 ` Vladimir Sementsov-Ogievskiy
2018-05-14 6:41 ` Fam Zheng
2018-05-14 10:09 ` Vladimir Sementsov-Ogievskiy
2018-05-14 10:23 ` Vladimir Sementsov-Ogievskiy
2018-05-15 2:03 ` Fam Zheng
2018-05-16 12:47 ` Kevin Wolf
2018-05-16 15:10 ` Vladimir Sementsov-Ogievskiy
2018-05-16 15:32 ` Kevin Wolf
2018-05-16 15:52 ` Vladimir Sementsov-Ogievskiy
2018-05-17 2:14 ` Fam Zheng [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20180517021441.GG6731@lemon.usersys.redhat.com \
--to=famz@redhat.com \
--cc=dgilbert@redhat.com \
--cc=jsnow@redhat.com \
--cc=kwolf@redhat.com \
--cc=mreitz@redhat.com \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.org \
--cc=quintela@redhat.com \
--cc=vsementsov@virtuozzo.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.