mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-11-03 20:01:16 +00:00
1b5c8d4cbc
I got annoyed at having to use both 'virsh vol-list $pool --details' AND 'virsh vol-dumpxml $vol $pool' to learn if I had populated the volume correctly. Since two-thirds of the data present in virStorageVolGetInfo() already appears in virStorageVolGetXMLDesc(), this just adds the remaining piece of information, as: <volume type='...'> ... </volume> * docs/formatstorage.html.in: Document new <volume type=...>. * docs/schemas/storagevol.rng (vol): Add it to RelaxNG. * src/conf/storage_conf.h (virStorageVolTypeToString): Declare. * src/conf/storage_conf.c (virStorageVolTargetDefFormat): Output the metatype. (virStorageVolDefParseXML): Parse it, for unit tests. * tests/storagevolxml2xmlout/vol-*.xml: Update tests to match. Signed-off-by: Eric Blake <eblake@redhat.com>
34 lines
920 B
XML
34 lines
920 B
XML
<volume type='file'>
|
|
<name>OtherDemo.img</name>
|
|
<key>/var/lib/libvirt/images/OtherDemo.img</key>
|
|
<source>
|
|
</source>
|
|
<capacity unit='bytes'>5368709120</capacity>
|
|
<allocation unit='bytes'>294912</allocation>
|
|
<target>
|
|
<path>/var/lib/libvirt/images/OtherDemo.img</path>
|
|
<format type='qcow2'/>
|
|
<permissions>
|
|
<mode>0644</mode>
|
|
<owner>0</owner>
|
|
<group>0</group>
|
|
<label>unconfined_u:object_r:virt_image_t:s0</label>
|
|
</permissions>
|
|
<encryption format='qcow'>
|
|
<secret type='passphrase' uuid='e78d4b51-a2af-485f-b0f5-afca709a80f4'/>
|
|
</encryption>
|
|
<compat>1.1</compat>
|
|
<features/>
|
|
</target>
|
|
<backingStore>
|
|
<path>/dev/null</path>
|
|
<format type='raw'/>
|
|
<permissions>
|
|
<mode>0644</mode>
|
|
<owner>0</owner>
|
|
<group>0</group>
|
|
<label>unconfined_u:object_r:virt_image_t:s0</label>
|
|
</permissions>
|
|
</backingStore>
|
|
</volume>
|