[Libvir] PATCH: 0/7 Implementation of storage APIs
Richard W.M. Jones
rjones at redhat.com
Mon Oct 29 14:49:16 UTC 2007
Daniel P. Berrange wrote:
> As we did with virsh attach-disk/attach-interface, vs attach-device
> I think it would be helpful to provide a 'virsh vol-create' variant
> which took a handful of explicit args as an alternative to the XML,
> eg virsh pool-create --type fs xenimages /var/lib/xen/images
Yes, vital really, and even better if it's a libvirt call.
> NB, <format> is actually optional - it defaults to raw. Permissions
> should be optional, but currently aren't. Allocation is optional too,
> without it, you will get a sparse file.
I didn't really understand the semantics of <allocation>. It should be
<sparse/> AFAICS. This underlines actually why XML is so much more
slippery than real typing.
>> <pool type="xxx">
>> <!-- target should make sense for the xxx driver, eg. path for fs,
>> LUN name for iSCSI, etc. There is no need for the dir=...
>> attribute -->
>> <!-- permissions should default to sensible values -->
> Yep, I intended permissions to be optional. Not all pools have a target,
> some only have a source. Basically name,and either target or source
> is the minimal set. Everything else should be optional.
But to avoid lots of switch/case in the caller we should also avoid
using an attribute name (<target> vs <target dir=...>).
Emerging Technologies, Red Hat - http://et.redhat.com/~rjones/
Registered Address: Red Hat UK Ltd, Amberley Place, 107-111 Peascod
Street, Windsor, Berkshire, SL4 1TE, United Kingdom. Registered in
England and Wales under Company Registration No. 03798903
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 3237 bytes
Desc: S/MIME Cryptographic Signature
More information about the libvir-list