]> review.fuel-infra Code Review - openstack-build/cinder-build.git/commit
Brick: Fix race in removing iSCSI device
authorWalter A. Boring IV <walter.boring@hp.com>
Fri, 27 Mar 2015 22:34:40 +0000 (15:34 -0700)
committerWalter A. Boring IV <walter.boring@hp.com>
Mon, 30 Mar 2015 16:26:57 +0000 (09:26 -0700)
commit43029941219505bc3861dd285e3393e08c76b433
tree993eabf2402afbbbd02b9ea75bc5b839302740cc
parent1387a5eb8bc8310e8597fab9fd15767d057ddaae
Brick: Fix race in removing iSCSI device

Some folks are seeing race conditions on overloaded
or slow machines, where the time between issuing the
remove volume command, and the volume being from
/dev/disk/by-path by the kernel isn't long enough.

This patch adds a simple verify loop for iSCSI only.
It will try 3 times and wait 2 seconds between tries.

Also, This patch will only fix attaches that happen
in cinder for copy volume <--> image operations.
Nova needs a separate patch to fix any potential
issues there.

Change-Id: I5db9744da6b865b7d903503db8a895b409f32f5c
Closes-Bug: 1437441
cinder/brick/exception.py
cinder/brick/initiator/connector.py
cinder/brick/initiator/linuxscsi.py
cinder/tests/brick/test_brick_linuxscsi.py