Adam Litke has uploaded a new change for review.

Change subject: Live Merge: Suspend disk stats collection during pivot
......................................................................

Live Merge: Suspend disk stats collection during pivot

When pivoting to the new volume after an active layer merge, there is a
brief period where the vdsm metadata is out of sync.  During this time,
the disk stats collection thread will raise an exception since the drive
cannot be referred to by its old path.  Therefore we disable stats
collection during this short window until the metadata can be
synchronized.

Change-Id: I08689aec4d61871a568a6f92661b560fbf4d0b57
Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1109918
Signed-off-by: Adam Litke <[email protected]>
---
M vdsm/virt/vm.py
1 file changed, 6 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/67/31367/1

diff --git a/vdsm/virt/vm.py b/vdsm/virt/vm.py
index 1347568..c2d8964 100644
--- a/vdsm/virt/vm.py
+++ b/vdsm/virt/vm.py
@@ -5545,6 +5545,7 @@
         if mode == LiveMergeCleanupThread.MODE_CLEANUP:
             self.log.info("Live merge job completed (job %s)", jobID)
             self._syncVolumeChain(drive)
+            self.startDisksStatsCollection()
         elif mode == LiveMergeCleanupThread.MODE_PIVOT:
             # We call imageSyncVolumeChain which will mark the current leaf
             # ILLEGAL.  We do this before requesting a pivot so that we can
@@ -5556,6 +5557,11 @@
             self.cif.irs.imageSyncVolumeChain(drive.domainID, drive.imageID,
                                               drive['volumeID'], newVols)
 
+            # A pivot changes the top volume being used for the VM Disk.  Until
+            # we can correct our metadata following the pivot we should not
+            # attempt to collect disk stats.
+            self.stopDisksStatsCollection()
+
             self.log.info("Requesting pivot to complete active layer commit "
                           "(job %s)", jobID)
             flags = libvirt.VIR_DOMAIN_BLOCK_JOB_ABORT_PIVOT


-- 
To view, visit http://gerrit.ovirt.org/31367
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I08689aec4d61871a568a6f92661b560fbf4d0b57
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Adam Litke <[email protected]>
_______________________________________________
vdsm-patches mailing list
[email protected]
https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches

Reply via email to