[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Clarification regarding new qemu-img convert --target-is-zero flag
From: |
David Edmondson |
Subject: |
Re: Clarification regarding new qemu-img convert --target-is-zero flag |
Date: |
Wed, 10 Jun 2020 12:56:36 +0100 |
On Wednesday, 2020-06-10 at 08:28:29 +03, Sam Eiderman wrote:
> Hi,
>
> 168468fe19c8 ("qemu-img: Add --target-is-zero to convert") has added a
> nice functionality for cloud scenarios:
>
> * Create a virtual disk
> * Convert a sparse image (qcow2, vmdk) to the virtual disk using
> --target-is-zero
> * Use the virtual disk
>
> This saves many unnecessary writes - a qcow2 with 1MB of allocated
> data but with 100GB virtual size will be converted efficiently.
>
> However, does this pose a problem if the virtual disk is not zero initialized?
As Vladimir indicated, the intent of the flag is supposed to be clear
from the name :-) If your storage doesn't read zeroes absent any earlier
writes, you probably don't want to be using it.
> Theoretically - if all unallocated blocks contain garbage - this
> shouldn't matter, however what about allocated blocks of zero? Will
> convert skip copying allocated zero blocks in the source image to the
> target since it assumes that the target is zeroed out first thing?
So something like a "--no-need-to-zero" flag would do what you want,
presuming that it would write known zeroes but no longer clean the
device before use?
dme.
--
You can't hide from the flipside.
- Clarification regarding new qemu-img convert --target-is-zero flag, Sam Eiderman, 2020/06/10
- Re: Clarification regarding new qemu-img convert --target-is-zero flag,
David Edmondson <=
- Re: Clarification regarding new qemu-img convert --target-is-zero flag, Sam Eiderman, 2020/06/10
- Re: Clarification regarding new qemu-img convert --target-is-zero flag, Vladimir Sementsov-Ogievskiy, 2020/06/10
- Re: Clarification regarding new qemu-img convert --target-is-zero flag, Kevin Wolf, 2020/06/10
- Re: Clarification regarding new qemu-img convert --target-is-zero flag, Sam Eiderman, 2020/06/10
- Re: Clarification regarding new qemu-img convert --target-is-zero flag, Sam Eiderman, 2020/06/10
- Re: Clarification regarding new qemu-img convert --target-is-zero flag, David Edmondson, 2020/06/10
- Re: Clarification regarding new qemu-img convert --target-is-zero flag, Sam Eiderman, 2020/06/10
- Re: Clarification regarding new qemu-img convert --target-is-zero flag, Eric Blake, 2020/06/10
- Re: Clarification regarding new qemu-img convert --target-is-zero flag, David Edmondson, 2020/06/10
- Re: Clarification regarding new qemu-img convert --target-is-zero flag, Eric Blake, 2020/06/10