From 5744301777e6c557bd44436ad5a45613631d0f08 Mon Sep 17 00:00:00 2001 From: Sean McGinnis Date: Fri, 28 Apr 2017 14:14:16 -0500 Subject: [PATCH] Give more time for LVM deactivation Current code retries three times for deactivation to complete, waiting one second between retries. On some heavily loaded systems, and apparently the gate, this is not enough time for the operation to complete. This attempts to work around those slower systems by increasing our retries to 5 and adding a backoff of 2 seconds to give it more time. Change-Id: I4f40a1984fe828c8ff965033f7e25b1d7516ab1e Closes-bug: #1687044 --- cinder/brick/local_dev/lvm.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cinder/brick/local_dev/lvm.py b/cinder/brick/local_dev/lvm.py index dde0d40f3a7..f7376ae5274 100644 --- a/cinder/brick/local_dev/lvm.py +++ b/cinder/brick/local_dev/lvm.py @@ -639,8 +639,8 @@ class LVM(executor.Executor): # order to prevent a race condition. self._wait_for_volume_deactivation(name) - @utils.retry(exceptions=exception.VolumeNotDeactivated, retries=3, - backoff_rate=1) + @utils.retry(exceptions=exception.VolumeNotDeactivated, retries=5, + backoff_rate=2) def _wait_for_volume_deactivation(self, name): LOG.debug("Checking to see if volume %s has been deactivated.", name)