mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-02-07 05:57:30 +03:00
conf: Save translated disk definition for disk type='volume' to status XML
Re-translating the disk source pools when reconnecting to a VM makes no sense as the volume might have changed or pool became inactive. The VM still uses the original volume though. Failing to re-translate the pool also causes the VM to be killed. Fix this by storing the original translation in the status XML. Resolves: https://issues.redhat.com/browse/RHEL-7345 Signed-off-by: Peter Krempa <pkrempa@redhat.com> Reviewed-by: Ján Tomko <jtomko@redhat.com>
This commit is contained in:
parent
9f49bd6452
commit
433f0d2b9a
@ -28247,7 +28247,8 @@ virDomainObjSave(virDomainObj *obj,
|
||||
VIR_DOMAIN_DEF_FORMAT_STATUS |
|
||||
VIR_DOMAIN_DEF_FORMAT_ACTUAL_NET |
|
||||
VIR_DOMAIN_DEF_FORMAT_PCI_ORIG_STATES |
|
||||
VIR_DOMAIN_DEF_FORMAT_CLOCK_ADJUST);
|
||||
VIR_DOMAIN_DEF_FORMAT_CLOCK_ADJUST |
|
||||
VIR_DOMAIN_DEF_FORMAT_VOLUME_TRANSLATED);
|
||||
|
||||
g_autofree char *xml = NULL;
|
||||
|
||||
|
@ -532,7 +532,8 @@ virDomainObjListLoadStatus(virDomainObjList *doms,
|
||||
VIR_DOMAIN_DEF_PARSE_ACTUAL_NET |
|
||||
VIR_DOMAIN_DEF_PARSE_PCI_ORIG_STATES |
|
||||
VIR_DOMAIN_DEF_PARSE_SKIP_VALIDATE |
|
||||
VIR_DOMAIN_DEF_PARSE_ALLOW_POST_PARSE_FAIL)))
|
||||
VIR_DOMAIN_DEF_PARSE_ALLOW_POST_PARSE_FAIL |
|
||||
VIR_DOMAIN_DEF_PARSE_VOLUME_TRANSLATED)))
|
||||
goto error;
|
||||
|
||||
virUUIDFormat(obj->def->uuid, uuidstr);
|
||||
|
Loading…
x
Reference in New Issue
Block a user