Eric Blake
ae6aa8c396
blockjob: enhance xml to track mirrors across libvirtd restart
...
In order to track a block copy job across libvirtd restarts, we
need to save internal XML that tracks the name of the file
holding the mirror. Displaying this name in dumpxml might also
be useful to the user, even if we don't yet have a way to (re-)
start a domain with mirroring enabled up front. This is done
with a new <mirror> sub-element to <disk>, as in:
<disk type='file' device='disk'>
<driver name='qemu' type='raw'/>
<source file='/var/lib/libvirt/images/original.img'/>
<mirror file='/var/lib/libvirt/images/copy.img' format='qcow2' ready='yes'/>
...
</disk>
For now, the element is output-only, in live domains; it is ignored
when defining a domain or hot-plugging a disk (since those contexts
use VIR_DOMAIN_XML_INACTIVE in parsing). The 'ready' attribute appears
when libvirt knows that the job has changed from the initial pulling
phase over to the mirroring phase, although absence of the attribute
is not a sure indicator of the current phase. If we come up with a way
to make qemu start with mirroring enabled, we can relax the xml
restriction, and allow <mirror> (but not attribute 'ready') on input.
Testing active-only XML meant tweaking the testsuite slightly, but it
was worth it.
* docs/schemas/domaincommon.rng (diskspec): Add diskMirror.
* docs/formatdomain.html.in (elementsDisks): Document it.
* src/conf/domain_conf.h (_virDomainDiskDef): New members.
* src/conf/domain_conf.c (virDomainDiskDefFree): Clean them.
(virDomainDiskDefParseXML): Parse them, but only internally.
(virDomainDiskDefFormat): Output them.
* tests/qemuxml2argvdata/qemuxml2argv-disk-mirror.xml: New test file.
* tests/qemuxml2xmloutdata/qemuxml2xmlout-disk-mirror.xml: Likewise.
* tests/qemuxml2xmltest.c (testInfo): Alter members.
(testCompareXMLToXMLHelper): Allow more test control.
(mymain): Run new test.
2012-04-23 08:43:33 -06:00
..
2012-01-17 12:22:19 +01:00
2012-01-17 12:09:51 -07:00
2012-01-17 12:09:51 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2012-04-10 16:34:39 +01:00
2012-04-10 16:34:39 +01:00
2011-11-30 11:36:11 -07:00
2012-03-07 18:24:43 -07:00
2011-11-29 12:26:21 -07:00
2012-03-07 18:24:43 -07:00
2011-02-08 11:43:45 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2012-01-09 10:55:53 -05:00
2012-03-07 18:24:43 -07:00
2012-01-09 10:55:53 -05:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-06-15 11:29:09 +02:00
2012-03-07 18:24:43 -07:00
2011-06-15 11:29:09 +02:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-06-15 11:29:09 +02:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2012-01-09 10:55:53 -05:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-15 12:24:56 +08:00
2011-02-04 09:17:01 -07:00
2012-03-15 12:24:56 +08:00
2011-02-03 21:14:50 -07:00
2012-03-15 12:24:56 +08:00
2011-11-03 12:01:05 +00:00
2012-03-15 12:24:56 +08:00
2011-11-03 12:01:05 +00:00
2012-03-15 12:24:56 +08:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-04-02 09:08:31 -06:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-11-03 12:01:05 +00:00
2012-03-15 12:24:56 +08:00
2011-11-03 12:01:05 +00:00
2012-03-15 12:24:56 +08:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2012-01-17 11:39:19 +01:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2012-01-17 11:39:19 +01:00
2012-03-07 18:24:43 -07:00
2012-01-27 16:51:50 +01:00
2012-03-07 18:24:43 -07:00
2012-01-17 12:22:19 +01:00
2012-03-07 18:24:43 -07:00
2012-03-07 18:24:43 -07:00
2012-01-17 12:22:19 +01:00
2012-03-07 18:24:43 -07:00
2012-01-17 12:22:19 +01:00
2012-03-07 18:24:43 -07:00
2012-01-27 16:51:50 +01:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2012-03-07 18:24:43 -07:00
2011-11-17 13:47:11 -07:00
2012-03-07 18:24:43 -07:00
2011-11-17 13:47:11 -07:00
2012-03-07 18:24:43 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-03-29 22:13:46 +08:00
2012-03-07 18:24:43 -07:00
2011-03-03 07:45:31 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2012-03-23 23:11:54 +08:00
2012-03-23 23:11:54 +08:00
2012-03-23 23:11:54 +08:00
2012-03-23 23:11:54 +08:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2012-01-13 10:08:15 +08:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-09-02 08:42:54 -06:00
2012-03-07 18:24:43 -07:00
2011-09-23 08:29:57 -06:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-10-26 11:55:39 -06:00
2012-03-07 18:24:43 -07:00
2011-10-26 11:55:39 -06:00
2012-03-07 18:24:43 -07:00
2011-10-26 11:55:39 -06:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-11-15 17:06:42 -07:00
2012-03-07 18:24:43 -07:00
2011-11-15 17:06:42 -07:00
2012-03-07 18:24:43 -07:00
2011-11-15 17:06:42 -07:00
2012-03-07 18:24:43 -07:00
2012-03-12 08:09:37 -06:00
2012-03-12 08:09:37 -06:00
2011-06-15 11:29:09 +02:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2012-03-23 23:11:54 +08:00
2012-03-23 23:11:54 +08:00
2012-03-23 23:11:54 +08:00
2012-03-23 23:11:54 +08:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2012-04-17 17:21:48 +08:00
2012-04-17 17:21:48 +08:00
2012-01-09 10:55:53 -05:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2012-04-23 08:43:33 -06:00
2012-01-09 10:55:53 -05:00
2012-03-07 18:24:43 -07:00
2011-10-17 15:44:21 -06:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2012-04-17 17:21:24 +08:00
2012-04-17 17:21:24 +08:00
2012-03-14 23:32:53 +08:00
2012-03-14 23:32:53 +08:00
2012-02-28 14:28:21 +08:00
2012-03-07 18:24:43 -07:00
2012-02-28 14:28:21 +08:00
2012-03-07 18:24:43 -07:00
2011-09-05 07:03:04 -06:00
2012-03-07 18:24:43 -07:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2012-01-09 10:55:53 -05:00
2012-03-07 18:24:43 -07:00
2012-01-09 10:55:53 -05:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2012-01-17 15:37:42 -07:00
2012-03-07 18:24:43 -07:00
2012-03-07 18:24:43 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2012-03-09 10:14:31 +01:00
2012-03-09 10:14:31 +01:00
2011-05-31 16:33:36 +02:00
2012-03-07 18:24:43 -07:00
2011-03-06 22:00:27 +08:00
2012-03-07 18:24:43 -07:00
2012-03-09 08:49:10 +01:00
2012-03-07 18:24:43 -07:00
2011-06-14 17:03:26 -06:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-05-24 10:33:53 -04:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-09-02 23:39:03 +08:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2012-01-27 16:51:50 +01:00
2012-03-07 18:24:43 -07:00
2011-06-02 10:54:00 +01:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:44 -07:00
2012-01-24 17:06:34 -07:00
2012-03-15 12:24:56 +08:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-15 12:24:56 +08:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-09-21 16:53:06 +02:00
2012-03-07 18:24:43 -07:00
2011-10-01 11:48:28 -04:00
2012-03-07 18:24:43 -07:00
2012-03-07 18:24:43 -07:00
2012-01-17 17:09:47 +08:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2012-03-05 23:24:34 -05:00
2012-03-07 18:24:43 -07:00
2012-01-17 17:09:47 +08:00
2012-03-07 18:24:43 -07:00
2012-01-17 17:09:47 +08:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-09-21 16:53:06 +02:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-06-20 15:17:43 +08:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2012-01-30 12:30:35 -05:00
2012-03-07 18:24:43 -07:00
2012-01-13 16:10:43 -07:00
2012-03-07 18:24:43 -07:00
2012-01-13 16:10:43 -07:00
2012-03-07 18:24:43 -07:00
2012-02-28 14:27:17 +08:00
2012-03-07 18:24:43 -07:00
2012-02-28 14:27:17 +08:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-12-30 10:38:37 +08:00
2012-03-15 12:24:56 +08:00
2011-12-30 10:57:59 +08:00
2012-03-15 12:24:56 +08:00
2011-12-30 10:38:37 +08:00
2012-03-15 12:24:56 +08:00
2012-02-06 12:04:33 -07:00
2012-03-15 12:24:56 +08:00
2011-12-30 10:38:37 +08:00
2012-03-15 12:24:56 +08:00
2011-12-30 10:38:37 +08:00
2012-03-15 12:24:56 +08:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-08-11 15:19:51 +08:00
2012-03-07 18:24:43 -07:00
2011-08-11 15:19:51 +08:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-10-01 11:48:28 -04:00
2012-03-07 18:24:43 -07:00
2011-09-05 15:03:27 +08:00
2012-03-07 18:24:43 -07:00
2011-09-05 15:03:27 +08:00
2012-03-07 18:24:43 -07:00
2011-10-01 11:48:28 -04:00
2012-03-07 18:24:43 -07:00
2011-10-01 11:48:28 -04:00
2012-03-07 18:24:43 -07:00
2011-10-01 11:48:28 -04:00
2012-03-07 18:24:43 -07:00
2011-09-05 15:03:27 +08:00
2012-03-07 18:24:43 -07:00
2011-10-01 11:48:28 -04:00
2012-03-07 18:24:43 -07:00
2012-01-31 13:36:23 -05:00
2012-03-07 18:24:43 -07:00
2011-04-06 10:05:14 -06:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00
2011-01-31 11:25:34 -07:00
2012-03-07 18:24:43 -07:00