cinder/cinder
Fernando Ferraz f70bfbf711 NetApp SolidFire: Fix duplicate volume when API response is lost
The SolidFire driver retries API requests in case a connection
error occurrs. When network is unstable, there may be the
possibility that the SolidFire backend successfully receive
and process a create volume operation, but fail to deliver the
response back to the driver.

When this scenario occurrs, the SolidFire driver automatically
resends the request, creating a second volume and leaving a
duplicate unused. Although this doesn't affect
driver functionality at first moment (the volume id from the
cluster is always correctly associated to cinder provider id),
further operations may hit the unused volume, leading to
unexpected hehavior.

This patch fixes this issue by:

1. Checking if the volume name already exists in the
backend before trying to create it. Volume creation will
raise a exception and abort in case of a volume is found.

2. Checking for volume creation right after a read timeout is
detected, preventing invalid API calls.

3. Adding option ´sf_volume_create_timeout´ to the SolidFire
driver, to allow users to set the appropriate timeout value for
their environment.

Closes-Bug: #1896112
Change-Id: I4383b691a8cc4aacb046332e418aafb88ba8ba56
(cherry picked from commit 42c92cc407)
(cherry picked from commit deb31a0c4d)
(cherry picked from commit d73da73283)
2021-03-24 22:43:30 +00:00
..
api API: os-reset_status notification fix 2021-02-08 15:16:20 +00:00
backup API: os-reset_status notification fix 2021-02-08 15:16:20 +00:00
brick Replace 'lvconvert' from rootwrap 2019-02-17 14:33:31 -05:00
cmd Untyped to Default Volume Type 2019-09-20 05:37:54 +00:00
common Change default glance_num_retries to 3 2020-11-16 07:03:27 +00:00
compute nova: use EndpointNotFound from keystoneauth1 2019-09-03 10:58:59 -04:00
db Modify default/delete volume type logic 2020-09-21 11:08:49 +00:00
group Continue renaming volume_utils (core) 2019-09-09 20:48:26 -04:00
image RBD: Cleanup temporary file during exception 2020-08-05 19:43:50 +00:00
interface Remove BackupDriverWithVerify class 2019-05-14 23:19:13 +03:00
keymgr Fix "import xxx as xxx" grammar 2019-01-23 15:35:53 +08:00
locale Imported Translations from Zanata 2019-10-04 06:44:38 +00:00
message Add user messages for some volume snapshot actions 2019-04-26 17:02:05 -04:00
objects Fix cross-project incremental backups 2020-07-02 19:39:00 -03:00
policies Correct group:reset_group_snapshot_status policy 2021-03-05 19:09:35 +00:00
privsep Revert "Remove truncate from rootwrap filters" 2019-03-06 10:08:10 -05:00
scheduler Fix: failed to create snapshot with DriverFilter 2020-04-08 13:29:27 +00:00
tests NetApp SolidFire: Fix duplicate volume when API response is lost 2021-03-24 22:43:30 +00:00
transfer Fix: show volume transfer by name for non-admins 2020-10-21 10:15:14 -04:00
volume NetApp SolidFire: Fix duplicate volume when API response is lost 2021-03-24 22:43:30 +00:00
wsgi Prevent double-attachment race in attachment_reserve 2019-07-29 12:57:51 -04:00
zonemanager Brocade: Fix lookup UnboundLocalError 2020-08-20 22:04:48 +02:00
__init__.py
context.py Preserve request id in Cinder logs when creating boot volume 2020-04-15 21:15:43 +00:00
coordination.py Remove deprecated heartbeat options 2017-10-03 14:41:18 -05:00
exception.py Modify default/delete volume type logic 2020-09-21 11:08:49 +00:00
flow_utils.py
i18n.py Replace http with https for doc links in cinder 2017-10-17 11:14:01 +08:00
manager.py Allow configuring tpool size 2018-03-08 15:59:29 +01:00
opts.py HPE 3PAR: Support duplicated FQDN in network 2020-07-02 03:28:20 -07:00
policy.py Correct default policy_file in the sample config 2019-01-15 13:54:17 -05:00
quota.py Bump hacking version to 1.1.x 2019-05-30 15:06:02 -04:00
quota_utils.py Enable split logging for cinder-keystoneclient interaction 2018-09-26 08:53:30 +00:00
rpc.py Replace assert to raise AssertionError 2019-06-05 18:41:21 +03:00
service.py Rename volume/utils.py to volume/volume_utils.py 2019-09-09 15:00:07 -04:00
service_auth.py Add service_token for cinder-nova interaction 2017-12-15 12:04:23 +05:30
ssh_utils.py Stop a connections leak when freeing an SSHPool 2018-02-14 18:16:55 -06:00
test.py Kaminario: Fix unique_fqdn_network option 2020-07-20 06:06:07 -07:00
utils.py Move some code out of utils.py 2019-08-26 11:34:20 -04:00
version.py