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.
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.
This is upstream nowadays:
Author: Wido den Hollander <firstname.lastname@example.org>
Date: Wed Jan 27 11:20:09 2016 +0100
rbd: Implement buildVolFrom using RBD cloning