Bug 1089079 - RFE: Support virStorageVolCreateXMLFrom in the RBD Storage Driver
Summary: RFE: Support virStorageVolCreateXMLFrom in the RBD Storage Driver
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Virtualization Tools
Classification: Community
Component: libvirt
Version: unspecified
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Libvirt Maintainers
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-04-17 20:40 UTC by Solly Ross
Modified: 2016-04-10 18:24 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-04-10 18:24:34 UTC


Attachments (Terms of Use)

Description Solly Ross 2014-04-17 20:40:37 UTC
Currently, the RBD storage driver does not support the virStorageVolCreateXMLFrom,
as the RBD storage backend does not implement a buildVolFrom method.

Having support for such a method would be advantageous in situations where one had an RBD-based storage pool, and wished to duplicate a volume in it, or wished to duplicate a volume from an existing pool into the RBD pool.

For cases when the transferring is done entirely within the RBD pool, librbd's `copy` function can be used.  Otherwise, librbd supports uploading image data via the `write` function.

Comment 1 Dmitry Borodaenko 2014-05-15 16:06:49 UTC
Even better, librbd's `clone` function can be used to avoid data copy altogether when creating an image in the same RBD pool. A further optimization would be to introspect snapshots chain in RBD and flatten the image if clone depth reaches a certain limit.

Comment 2 Cole Robinson 2016-04-10 18:24:34 UTC
This is upstream nowadays:

commit 0b15f92032725a7943df1f035b649f4e030953e7
Author: Wido den Hollander <wido@widodh.nl>
Date:   Wed Jan 27 11:20:09 2016 +0100

    rbd: Implement buildVolFrom using RBD cloning


Note You need to log in before you can comment on or make changes to this bug.