diff --git a/docs/formatdomain.html.in b/docs/formatdomain.html.in index e851f852a1..93ee05c94e 100644 --- a/docs/formatdomain.html.in +++ b/docs/formatdomain.html.in @@ -1624,6 +1624,20 @@ </auth> <target dev='vda' bus='virtio'/> </disk> + <disk type='file' device='disk'> + <driver name='qemu' type='qcow2'/> + <source file='/var/lib/libvirt/images/domain.qcow'/> + <backingStore type='file'> + <format type='qcow2'/> + <source file='/var/lib/libvirt/images/snapshot.qcow'/> + <backingStore type='block'> + <format type='raw'/> + <source dev='/dev/mapper/base'/> + <backingStore/> + </backingStore> + </backingStore> + <target dev='vda' bus='virtio'/> + </disk> </devices> ... @@ -1814,6 +1828,53 @@ This feature doesn't support migration currently.

+
backingStore
+
+ This element describes the backing store used by the disk specified by + sibling source element. It is currently ignored on input + and only used for output to describe the detected backing chains. + Since 1.2.4. An empty + backingStore element means the sibling source is + self-contained and is not based on any backing store. The following + attributes and sub-elements are supported in + backingStore: +
+
type attribute
+
+ The type attribute represents the type of disk used + by the backing store, see disk type attribute above for more + details and possible values. +
+
index attribute
+
+ This attribute is only valid in output (and ignored on input) and + it can be used to refer to a specific part of the disk chain when + doing block operations (such as via the + virDomainBlockRebase API). For example, + vda[2] refers to the backing store with + index='2' of the disk with vda target. +
+
format sub-element
+
+ The format element contains type + attribute which specifies the internal format of the backing + store, such as raw or qcow2. +
+
source sub-element
+
+ This element has the same structure as the source + element in disk. It specifies which file, device, + or network location contains the data of the described backing + store. +
+
backingStore sub-element
+
+ If the backing store is not self-contained, the next element + in the chain is described by nested backingStore + element. +
+
+
mirror
This element is present if the hypervisor has started a block diff --git a/docs/schemas/domaincommon.rng b/docs/schemas/domaincommon.rng index d2235e1f56..4249ed56e6 100644 --- a/docs/schemas/domaincommon.rng +++ b/docs/schemas/domaincommon.rng @@ -1196,10 +1196,51 @@ - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -1232,7 +1273,6 @@ - @@ -1256,7 +1296,6 @@ - @@ -1276,7 +1315,6 @@ - @@ -1340,7 +1378,6 @@ - @@ -1373,7 +1410,6 @@ - diff --git a/tests/domainschemadata/backing-chains.xml b/tests/domainschemadata/backing-chains.xml new file mode 100644 index 0000000000..84df1dbd30 --- /dev/null +++ b/tests/domainschemadata/backing-chains.xml @@ -0,0 +1,94 @@ + + QEMUGuest1 + c7a5fdbd-edaf-9455-926a-d65c16db1809 + 219136 + 219136 + 1 + + hvm + + + + destroy + restart + destroy + + /usr/bin/qemu + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +