On Thu, Nov 22, 2012 at 1:00 PM, Dietmar Maurer <diet...@proxmox.com> wrote:
>> It is a stream of compressed "grains" (data).  They are out-of-order and each
>> grain comes with the virtual disk lba where the data should be visible to the
>> guest.
>>
>> The stream also contains "grain tables" and "grain directories".  This
>> metadata makes random read access to the file possible once you have
>> downloaded the entire file (i.e. it is seekable).  Although tools can choose 
>> to
>> consume the stream in sequential order too and ignore the metadata.
>>
>> In other words, the format is an out-of-order stream of data chunks plus
>> random access lookup tables at the end.
>>
>> QEMU's block/vmdk.c already has some support for this format although I
>> don't think we generate out-of-order yet.
>>
>> The benefit of reusing this code is that existing tools can consume these 
>> files.
>
> Compression format is hardcoded to RFC 1951 (defalte). I think this is a 
> major disadvantage,
> because it is really slow (compared to lzop).

It's a naughty thing to do but we could simply pick a new constant and
support LZO as an incompatible option.  The file is then no longer
compatible with existing vmdk tools but at least we then have a choice
of using compatible deflate or the LZO extension.

VMDK already has 99% of what you need and we already have a bunch of
code to handle this format.  This seems like a good opportunity to
flesh out VMDK support and avoid reinventing the wheel.

Stefan

Reply via email to