QEMU-Devel Archive mirror
 help / color / mirror / Atom feed
From: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
To: Kevin Wolf <kwolf@redhat.com>, Eric Blake <eblake@redhat.com>
Cc: qemu-devel@nongnu.org,
	"open list:Block layer core" <qemu-block@nongnu.org>,
	Markus Armbruster <armbru@redhat.com>,
	mreitz@redhat.com, nsoffer@redhat.com
Subject: Re: [PATCH v2 2/1] qemu-img: Add "backing":true to unallocated map segments
Date: Tue, 22 Jun 2021 20:51:09 +0300	[thread overview]
Message-ID: <0b897b00-9c52-9841-8a2a-1a1eff09e32c@virtuozzo.com> (raw)
In-Reply-To: <YNID9rbo+RdwklCf@redhat.com>

22.06.2021 18:38, Kevin Wolf wrote:
> Am 11.06.2021 um 21:03 hat Eric Blake geschrieben:
>> To save the user from having to check 'qemu-img info --backing-chain'
>> or other followup command to determine which "depth":n goes beyond the
>> chain, add a boolean field "backing" that is set only for unallocated
>> portions of the disk.
>>
>> Signed-off-by: Eric Blake <eblake@redhat.com>
>> ---
>>
>> Touches the same iotest output as 1/1.  If we decide that switching to
>> "depth":n+1 is too risky, and that the mere addition of "backing":true
>> while keeping "depth":n is good enough, then we'd have just one patch,
>> instead of this double churn.  Preferences?
> 
> I think the additional flag is better because it's guaranteed to be
> backwards compatible, and because you don't need to know the number of
> layers to infer whether a cluster was allocated in the whole backing
> chain. And by exposing ALLOCATED we definitely give access to the whole
> information that exists in QEMU.
> 
> However, to continue with the bike shedding: I won't insist on
> "allocated" even if that is what the flag is called internally and
> consistency is usually helpful, but "backing" is misleading, too,
> because intuitively it doesn't cover the top layer or standalone images
> without a backing file. How about something like "present"?
> 

IMHO, it does cover. If we have qcow2 image with unallocated clusters, but unspecified backing file it's good to know that these unallocated clusters are not simply ZERO, but actually point to backing file, which is just absent now (and therefore read returns zeros). User may start qemu and specify backing file by options, or set backing file in the image, etc. So, the information does make sense anyway.

I think it would be good to start saying about backing chains explicitly, and not hide them under "allocated" concept which has different meanings.


-- 
Best regards,
Vladimir


  parent reply	other threads:[~2021-06-22 17:52 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-11 14:01 [PATCH v2] qemu-img: Make unallocated part of backing chain obvious in map Eric Blake
2021-06-11 14:35 ` Vladimir Sementsov-Ogievskiy
2021-06-11 14:59   ` Eric Blake
2021-06-11 18:13     ` Nir Soffer
2021-06-11 19:03 ` [PATCH v2 2/1] qemu-img: Add "backing":true to unallocated map segments Eric Blake
2021-06-15  8:54   ` Vladimir Sementsov-Ogievskiy
2021-06-15 13:09     ` Nir Soffer
2021-06-22 15:38   ` Kevin Wolf
2021-06-22 16:56     ` Nir Soffer
2021-06-23  8:57       ` Kevin Wolf
2021-06-23 13:58         ` Nir Soffer
2021-06-23 16:04           ` Kevin Wolf
2021-06-23 16:35             ` Nir Soffer
2021-06-28 17:42             ` Eric Blake
2021-06-29  7:23               ` Vladimir Sementsov-Ogievskiy
2021-06-29 14:40                 ` Kevin Wolf
2021-06-29 15:53                   ` Nir Soffer
2021-06-22 17:51     ` Vladimir Sementsov-Ogievskiy [this message]
2021-06-22 17:04   ` Nir Soffer

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=0b897b00-9c52-9841-8a2a-1a1eff09e32c@virtuozzo.com \
    --to=vsementsov@virtuozzo.com \
    --cc=armbru@redhat.com \
    --cc=eblake@redhat.com \
    --cc=kwolf@redhat.com \
    --cc=mreitz@redhat.com \
    --cc=nsoffer@redhat.com \
    --cc=qemu-block@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    /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 read-only IMAP folder(s) and NNTP newsgroup(s).