Fix volume attach error in generic driver
The generic driver doesn't understand the new 'reserved' volume state and errors out when it detects that state. Closes-Bug: #1741568 Change-Id: Ic14186d47b4d16a03c5c1e52933be5fa4660ee28
This commit is contained in:
parent
c4b59336c2
commit
f28ef954ba
@ -411,7 +411,7 @@ class GenericShareDriver(driver.ExecuteMixin, driver.ShareDriver):
|
||||
volume = self.volume_api.get(context, volume['id'])
|
||||
if volume['status'] == 'in-use':
|
||||
return volume
|
||||
elif volume['status'] != 'attaching':
|
||||
elif volume['status'] not in ('attaching', 'reserved'):
|
||||
raise exception.ManilaException(
|
||||
_('Failed to attach volume %s') % volume['id'])
|
||||
time.sleep(1)
|
||||
|
Loading…
x
Reference in New Issue
Block a user