From: "Daniel P. Berrange" <berrange@redhat.com>
To: Eric Blake <eblake@redhat.com>
Cc: qemu-devel@nongnu.org, Kevin Wolf <kwolf@redhat.com>,
qemu-block@nongnu.org, Max Reitz <mreitz@redhat.com>,
Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Subject: Re: [Qemu-devel] [PATCH] qcow2: fix image corruption after committing qcow2 image into base
Date: Fri, 10 Nov 2017 17:22:53 +0000 [thread overview]
Message-ID: <20171110172253.GH30685@redhat.com> (raw)
In-Reply-To: <9b0c5170-c97a-51d5-b1e4-003f1628d7be@redhat.com>
On Fri, Nov 10, 2017 at 10:34:59AM -0600, Eric Blake wrote:
> On 11/03/2017 09:41 AM, Daniel P. Berrange wrote:
> > After committing the qcow2 image contents into the base image, qemu-img
> > will call bdrv_make_empty to drop the payload in the layered image.
> >
> > When this is done for qcow2 images, it blows away the LUKS encryption
> > header, making the resulting image unusable. There are two codepaths
> > for emptying a qcow2 image, and the second (slower) codepaths leaves
> > the LUKS header intact, so force use of that codepath.
> >
> > Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
> > ---
> >
> > NB, ideally we would fix the faster codepath in make_completely_empty, but
> > having looked at the code, I've really no idea how to even start on fixing that
> > to not kill the LUKS header clusters.
>
> Hmm - I wonder if persistent bitmaps are also corrupted in the fast path.
I also wonder if there's anything better we can do to make us safer by
default, so we default to the slow & safe path, unless we can provide
we *only* have the subset of features that are safe for the fast path ?
Regards,
Daniel
--
|: https://berrange.com -o- https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org -o- https://fstop138.berrange.com :|
|: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|
next prev parent reply other threads:[~2017-11-10 17:23 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-11-03 14:41 [Qemu-devel] [PATCH] qcow2: fix image corruption after committing qcow2 image into base Daniel P. Berrange
2017-11-03 18:00 ` Eric Blake
2017-11-10 16:28 ` Kevin Wolf
2017-11-10 16:34 ` Eric Blake
2017-11-10 17:06 ` Vladimir Sementsov-Ogievskiy
2017-11-10 17:22 ` Daniel P. Berrange [this message]
2017-11-14 13:52 ` Max Reitz
2017-11-17 14:33 ` Eric Blake
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=20171110172253.GH30685@redhat.com \
--to=berrange@redhat.com \
--cc=eblake@redhat.com \
--cc=kwolf@redhat.com \
--cc=mreitz@redhat.com \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.org \
--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.