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

[libvirt] [PATCH 0/7] virStorageVolCreateXMLFrom API



Hi all,

The following patches implement a new API call: virStorageVolCreateXMLFrom.

virStorageVolPtr
virStorageVolCreateXMLFrom(virStoragePoolPtr pool,
                           const char *xmldesc,
                           unsigned int flags,
                           virStorageVolPtr clonevol)

Arguments function similar to the regular volume create API, except the
parameter 'clonevol' is used as the input source. The API allows for
volume cloning, possibly across pools, or within the same pool but converting
volume formats.

Tests I performed (and ensured that a VM booted without complaints from the
new image):

Raw -> Raw (with successful sparse detection)
Raw -> QCOW2
QCOW2 -> Raw
QCOW2 -> QCOW2
QCOW2 -> VMDK
Raw partition ('disk' volume) -> Raw file

Thanks,
Cole

Cole Robinson (7):
  Add public API stubs for virStorageVolCreateXMLFrom
  Remote driver plumbing for virStorageVolCreateXMLFrom
  Test driver implementation of virStorageVolCreateXMLFrom
  Virsh commands vol-clone and vol-create-from
  Storage driver implementation for CreateXMLFrom
  Break out FS volume build routines to their own functions.
  VolumeCreateXMLFrom FS storage backend implementation.

 include/libvirt/libvirt.h          |    4 +
 include/libvirt/libvirt.h.in       |    4 +
 qemud/remote.c                     |   34 +++
 qemud/remote_dispatch_args.h       |    1 +
 qemud/remote_dispatch_prototypes.h |    7 +
 qemud/remote_dispatch_ret.h        |    1 +
 qemud/remote_dispatch_table.h      |    5 +
 qemud/remote_protocol.c            |   24 ++
 qemud/remote_protocol.h            |   18 ++
 qemud/remote_protocol.x            |   15 +-
 src/driver.h                       |    6 +
 src/libvirt.c                      |   61 +++++-
 src/libvirt_public.syms            |    5 +
 src/remote_internal.c              |   33 +++
 src/storage_backend.h              |    2 +
 src/storage_backend_fs.c           |  491 +++++++++++++++++++++++++-----------
 src/storage_driver.c               |  153 +++++++++++-
 src/test.c                         |   95 +++++++
 src/virsh.c                        |  177 +++++++++++++-
 19 files changed, 985 insertions(+), 151 deletions(-)


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