From: Eric Blake <eblake@redhat.com>
To: Peter Lieven <pl@kamp.de>
Cc: kwolf@redhat.com, quintela@redhat.com, qemu-devel@nongnu.org,
owasserm@redhat.com, stefanha@redhat.com, pbonzini@redhat.com
Subject: Re: [Qemu-devel] [PATCHv3] block-migration: efficiently encode zero blocks
Date: Mon, 15 Jul 2013 15:27:01 -0600 [thread overview]
Message-ID: <51E46925.8040204@redhat.com> (raw)
In-Reply-To: <1373885705-13722-1-git-send-email-pl@kamp.de>
[-- Attachment #1: Type: text/plain, Size: 2730 bytes --]
On 07/15/2013 04:55 AM, Peter Lieven wrote:
> this patch adds an efficient encoding for zero blocks by
> adding a new flag indiciating a block is completly zero.
s/indiciating/indicating/
s/completly/completely/
>
> additionally bdrv_write_zeros() is used at the destination
> to efficiently write these zeroes.
>
> v2->v3:
patch revision history belongs outside of the commit message proper...
> - changed type of flags in blk_send() from int to uint64_t
> - added migration capability setting to enable sending
> of zero blocks.
>
> Signed-off-by: Peter Lieven <pl@kamp.de>
> ---
...here, after the --- separator.
> block-migration.c | 29 +++++++++++++++++++++++------
> include/migration/migration.h | 1 +
> migration.c | 9 +++++++++
> qapi-schema.json | 7 ++++++-
> 4 files changed, 39 insertions(+), 7 deletions(-)
>
> +++ b/qapi-schema.json
> @@ -613,10 +613,15 @@
> # Disabled by default. Experimental: may (or may not) be renamed after
> # further testing is complete. (since 1.6)
> #
> +# @zero-blocks: During storage migration encode blocks of zeroes efficiently. This
> +# essentially saves 1MB of zeroes per block on the wire. Enabling requires
> +# source and target VM to support this feature. Disabled by default. (since 1.6)
Does this capability have to be explicitly set on the receiving end, or
can it be automatic? I'd prefer automatic - where only the sending end
has to explicitly turn on the optimization.
Are there any downsides to unconditionally using this when it is
supported on both sides? With xbzrle, there are workloads where
enabling the feature can actually penalize performance, so libvirt
exposed the choice of using the feature through its API to the end user.
But if I understand this feature, there are no downsides to using it,
other than generating a migration stream that the destination will not
understand. Thus, I don't think libvirt public-facing APIs need to
change, and that it is just a matter of implementing this in libvirt
internals that coordinate the start of a migration:
old -> old: feature not present on source, not enabled
old -> new: feature not present on source, not enabled
new -> old: feature present on source, so query destination; feature not
present on destination, so not enabled
new -> new: feature present on source, so query destination; feature
present on destination, so use it
At any rate, the interface looks sane;
Reviewed-by: Eric Blake <eblake@redhat.com>
--
Eric Blake eblake redhat com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 621 bytes --]
next prev parent reply other threads:[~2013-07-15 21:27 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-15 10:55 [Qemu-devel] [PATCHv3] block-migration: efficiently encode zero blocks Peter Lieven
2013-07-15 21:27 ` Eric Blake [this message]
2013-07-16 7:10 ` Peter Lieven
2013-07-18 5:03 ` Stefan Hajnoczi
2013-07-18 6:02 ` Peter Lieven
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=51E46925.8040204@redhat.com \
--to=eblake@redhat.com \
--cc=kwolf@redhat.com \
--cc=owasserm@redhat.com \
--cc=pbonzini@redhat.com \
--cc=pl@kamp.de \
--cc=qemu-devel@nongnu.org \
--cc=quintela@redhat.com \
--cc=stefanha@redhat.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).