[libvirt] [PATCH 1/2] resize: add virStorageVolResize() API

Eric Blake eblake at redhat.com
Sat Jan 28 03:00:37 UTC 2012


On 01/27/2012 06:14 PM, Zeeshan Ali (Khattak) wrote:
> On Sat, Jan 28, 2012 at 2:28 AM, Eric Blake <eblake at redhat.com> wrote:
>> From: "Zeeshan Ali (Khattak)" <zeeshanak at gnome.org>
>>
>> Add a new function to allow changing of capacity of storage volumes.
>> Plan out several flags, even if not all of them will be implemented
>> up front.
>>
>> Expose the new command via 'virsh vol-resize'.
> 
> ACK otherwise but i don't see how VIR_STORAGE_VOL_RESIZE_ALLOCATE can
> be implemented and also the inability of qemu-img to shrink images I
> mentioned in my previous mail.

We implement what makes sense, and reject what doesn't; and it's okay if
we have a partial implementation (such as raw files work in all aspects,
LVM partitions treat VIR_STORAGE_VOL_RESIZE_ALLOCATE as a no-op since
that is what happens automatically, and qcow2 supports enlarging but not
shrinking).  And perhaps when someone encounters a situation that they
need to work, they can help contribute patches - the important thing to
note is that we can backport patches that implement the features without
breaking API, but we can't backport the new API without bumping the .so
version, so the goal is to get an API that we can agree to in the source
now, but then we have a bit more breathing room on getting the
implementation working.

At any rate, I've gone ahead and pushed these two patches, so you can
rebase your implementation patches on top of this and see what flags you
can implement and for which file types.

-- 
Eric Blake   eblake at redhat.com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 620 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20120127/cab66f11/attachment-0001.sig>


More information about the libvir-list mailing list