Dan Kenigsberg has submitted this change and it was merged.
Change subject: vm.py: State saving in hotunplugDisk.
......................................................................
vm.py: State saving in hotunplugDisk.
VM's state was saved before detatching a disk in hotunplugDisk.
Saving vm's state should be performed only AFTER vdsm is actually
detaching the disk, otherwise the disk will remain in xmlDesc and
be calculated in the vm's hash.
This causes a bug in the engine's VM monitoring: the engine
gets the same hash as before the disk was unplugged, thus does not
update the disk's status.
Due to a possible race while hotunplugging, where VM monitoring starts
updating the VM devices while the disk is still plugged- then
hotplugging is performed and succeeds, then monitoring is resumed and
sets the disk to be still plugged, this patch is critical for the
engine to be synced with the actual state of the VM's disks.
Please note that this patch is partial, as detachDevice is async. That
means that still the hash can be calculated wrong in case the disk was
not detached yet. This fix will be included in a following patch.
Change-Id: I2cf18186cbba33d7e74fd15651ffec3149c98e1d
Bug-Url:https://bugzilla.redhat.com/1206696
Signed-off-by: Amit Aviram <aaviram(a)redhat.com>
Reviewed-on:
https://gerrit.ovirt.org/45077
Reviewed-by: Nir Soffer <nsoffer(a)redhat.com>
Reviewed-by: Francesco Romani <fromani(a)redhat.com>
Continuous-Integration: Jenkins CI
---
M vdsm/virt/vm.py
1 file changed, 10 insertions(+), 19 deletions(-)
Approvals:
Nir Soffer: Looks good to me, approved
Jenkins CI: Passed CI tests
Amit Aviram: Verified
Francesco Romani: Looks good to me, approved
--
To view, visit
https://gerrit.ovirt.org/45077
To unsubscribe, visit
https://gerrit.ovirt.org/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I2cf18186cbba33d7e74fd15651ffec3149c98e1d
Gerrit-PatchSet: 13
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Amit Aviram <aaviram(a)redhat.com>
Gerrit-Reviewer: Adam Litke <alitke(a)redhat.com>
Gerrit-Reviewer: Allon Mureinik <amureini(a)redhat.com>
Gerrit-Reviewer: Amit Aviram <aaviram(a)redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <danken(a)redhat.com>
Gerrit-Reviewer: Francesco Romani <fromani(a)redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Liron Aravot <laravot(a)redhat.com>
Gerrit-Reviewer: Nir Soffer <nsoffer(a)redhat.com>
Gerrit-Reviewer: automation(a)ovirt.org