qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v2 00/17] Add qemu-img subcommand to dump file m


From: Wenchao Xia
Subject: Re: [Qemu-devel] [PATCH v2 00/17] Add qemu-img subcommand to dump file metadata
Date: Fri, 19 Jul 2013 18:48:49 +0800
User-agent: Mozilla/5.0 (Windows NT 5.1; rv:17.0) Gecko/20130620 Thunderbird/17.0.7

于 2013-7-17 0:57, Paolo Bonzini 写道:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Il 16/07/2013 18:56, Eric Blake ha scritto:
On 07/16/2013 10:29 AM, Paolo Bonzini wrote:
This series adds a subcommand to "map" that can dump file
metadata. Metadata that is dumped includes:

- whether blocks are allocated in bs->file and, if so, where

- whether blocks are zero

- whether data is read from bs or bs->backing_hd

Is this command only usable from qemu-img, or is there a QMP
counterpart for getting at the same information on a live image
while qemu is running?

Not yet, we had no use case yet.  It may be exposed later to the
guests via the SCSI command GET LBA STATUS.

Paolo

  I think dump of allocated info in qemu-img in this series, can do
dirty change tracking job for backing chain snapshot now, qemu's QMP
interface is not very needed.
  Only thing not perfect, is that it talks with string. A library would
be better, but I am not selling libqblock:), instead I'd like to form
a better and clean library so want to adjust qemu's block layer first.


Metadata is dumped for an entire chain of images.  One example
usage is (for non-compressed, non-encrypted images) to transform
the metadata into a Linux device-mapper setup, and make a qcow2
image available (for read only) as a block device.  Another
possible usage is to determine the used areas of a file, and
convert it in place to another format. Alternatively, the richer
data can be used by block jobs to quickly determine if a block is
zero without reading it.

Definitely useful information!  I haven't looked at the
implementation yet, but there had better be a JSON representation
of the output :)


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.19 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQIcBAEBAgAGBQJR5XtfAAoJEBvWZb6bTYbypRUP/jadsxWgkWGbefpIqUL7Iykt
EiPeQfuwJNrq2uXU5orD11xkJbm5gElg/iLQBfBnpAZTJ9VNKTkGUwwhAPgLfIrT
LkTwd7Puqbe8q965K7kXqDoxT5fN+5nyyE9TbvlOEkThLRebWGVEgfViKoqnPYFW
ApejY05zmWrT9+wk984/ELNH0XAv54vITGGzrkgFKpt+h+MZ/1ZQfy3xapczBPTh
ui+U9Y2zJ3vdE3JxYGxNM0IVAWvrn0prCRpgGF+Id1uaT839UuYU1ukEFxJpynrh
iXHuryQgI2zNx4IDwSwIXfOLc1P0XR59eOaN+n+mw45faIOEaEOlChSC4SvDCtTT
3B1bK7ZqTFy8P8KQ+SjA4NIkl8yb7qLmEGmweJnSxSI1JUz/P3k+uC/FZd/Zxe/r
nFVdXYQtKVCZW0CMBMdHRE2T/3PFlx2nz/dzW+OrKyweKpDqcYjU+TyyrvXiT5Yv
E8ttpOzQsNJl+VdEWpfa4StgRgQxmazVM80OyE52cNKAixUyLpJ7pR4fsF1mcswc
BWdpSe/J8T6LRyTOAKoWoi2w8Mw/DMey4neQ1+py8tWuCqJix3NtyduVtsvrRiYd
aPcXvGfAvDbzEcMHnwz0SVpTqleK/7H7pYScBdWYnmUG5wJuxfhJHD/5JDQ1wmj0
jGHmCAddWW+8RrHZGrpX
=paUV
-----END PGP SIGNATURE-----



--
Best Regards

Wenchao Xia




reply via email to

[Prev in Thread] Current Thread [Next in Thread]