[SVF]:Bulk create Hyperswap volume is failing.
[Spectrum Virtualize Family] During HyperSwap create volume there is multiple lsmdiskgrp calls, which is causing more concurrent calls on SVC. This patch fixes the issue by caching the site information during initialization and checking for HyperSwap pool site information. Closes-Bug: #1917605 Change-Id: I3f734e55efeabcfdeca4c4f3e87bc4a5a0481875
This commit is contained in:
parent
babafa435c
commit
e6ad644046
@ -537,7 +537,7 @@ class StorwizeSVCManagementSimulator(object):
|
||||
'vdisk_count', 'capacity', 'extent_size',
|
||||
'free_capacity', 'virtual_capacity', 'used_capacity',
|
||||
'real_capacity', 'overallocation', 'warning',
|
||||
'easy_tier', 'easy_tier_status', 'site_id',
|
||||
'easy_tier', 'easy_tier_status', 'site_id', 'site_name',
|
||||
'data_reduction'])
|
||||
for i in range(pool_num):
|
||||
row_data = [str(i + 1),
|
||||
@ -546,32 +546,36 @@ class StorwizeSVCManagementSimulator(object):
|
||||
'3573412790272', '256', '3529926246400',
|
||||
'1693247906775',
|
||||
'26843545600', '38203734097', '47', '80', 'auto',
|
||||
'inactive', '', 'no']
|
||||
'inactive', '', '', 'no']
|
||||
rows.append(row_data)
|
||||
rows.append([str(pool_num + 1), 'openstack2', 'online',
|
||||
'1', '0', '3573412790272', '256',
|
||||
'3529432325160', '1693247906775', '26843545600',
|
||||
'38203734097', '47', '80', 'auto', 'inactive', '', 'no'])
|
||||
'38203734097', '47', '80', 'auto', 'inactive', '', '',
|
||||
'no'])
|
||||
rows.append([str(pool_num + 2), 'openstack3', 'offline',
|
||||
'1', '0', '3573412790272', '128',
|
||||
'3529432325160', '1693247906775', '26843545600',
|
||||
'38203734097', '47', '80', 'auto', 'inactive', '', 'yes'])
|
||||
'38203734097', '47', '80', 'auto', 'inactive', '', '',
|
||||
'yes'])
|
||||
rows.append([str(pool_num + 3), 'hyperswap1', 'online',
|
||||
'1', '0', '3573412790272', '256',
|
||||
'3529432325160', '1693247906775', '26843545600',
|
||||
'38203734097', '47', '80', 'auto', 'inactive', '1', 'no'])
|
||||
'38203734097', '47', '80', 'auto', 'inactive', '1',
|
||||
'site1', 'no'])
|
||||
rows.append([str(pool_num + 4), 'hyperswap2', 'online',
|
||||
'1', '0', '3573412790272', '128',
|
||||
'3529432325160', '1693247906775', '26843545600',
|
||||
'38203734097', '47', '80', 'auto', 'inactive', '2', 'no'])
|
||||
'38203734097', '47', '80', 'auto', 'inactive', '2',
|
||||
'site2', 'no'])
|
||||
rows.append([str(pool_num + 5), 'dr_pool1', 'online',
|
||||
'1', '0', '3573412790272', '128', '3529432325160',
|
||||
'1693247906775', '26843545600', '38203734097', '47', '80',
|
||||
'auto', 'inactive', '1', 'yes'])
|
||||
'auto', 'inactive', '1', 'site1', 'yes'])
|
||||
rows.append([str(pool_num + 6), 'dr_pool2', 'online',
|
||||
'1', '0', '3573412790272', '128', '3529432325160',
|
||||
'1693247906775', '26843545600', '38203734097', '47', '80',
|
||||
'auto', 'inactive', '2', 'yes'])
|
||||
'auto', 'inactive', '2', 'site2', 'yes'])
|
||||
if 'obj' not in kwargs:
|
||||
return self._print_info_cmd(rows=rows, **kwargs)
|
||||
else:
|
||||
|
@ -2649,8 +2649,19 @@ class StorwizeHelpers(object):
|
||||
raise exception.InvalidInput(
|
||||
reason=_('The peer pool is necessary for hyperswap volume, '
|
||||
'please configure the peer pool.'))
|
||||
pool_attr = self.get_pool_attrs(pool)
|
||||
peer_pool_attr = self.get_pool_attrs(peer_pool)
|
||||
pool_attr = None
|
||||
peer_pool_attr = None
|
||||
for stat_pool in self.stats.get('pools', []):
|
||||
if stat_pool['pool_name'] == pool:
|
||||
pool_attr = stat_pool
|
||||
elif stat_pool['pool_name'] == peer_pool:
|
||||
peer_pool_attr = stat_pool
|
||||
|
||||
if pool_attr is None:
|
||||
pool_attr = self.get_pool_attrs(pool)
|
||||
if peer_pool_attr is None:
|
||||
peer_pool_attr = self.get_pool_attrs(peer_pool)
|
||||
|
||||
if not peer_pool_attr:
|
||||
raise exception.InvalidInput(
|
||||
reason=_('The hyperswap peer pool %s '
|
||||
@ -2970,6 +2981,10 @@ class StorwizeSVCCommonDriver(san.SanDriver,
|
||||
self._secondary_pools = [self._replica_target.get('pool_name')]
|
||||
return self._secondary_pools
|
||||
|
||||
def _get_backend_peer_pool(self):
|
||||
if not self._active_backend_id:
|
||||
return self.configuration.storwize_peer_pool
|
||||
|
||||
def _validate_pools_exist(self):
|
||||
# Validate that the pool exists
|
||||
pools = self._get_backend_pools()
|
||||
@ -5695,6 +5710,12 @@ class StorwizeSVCCommonDriver(san.SanDriver,
|
||||
data['pools'] = [self._build_pool_stats(pool)
|
||||
for pool in
|
||||
self._get_backend_pools()]
|
||||
|
||||
if self._helpers.is_system_topology_hyperswap(self._state):
|
||||
peer_pool = self._get_backend_peer_pool()
|
||||
if peer_pool:
|
||||
data['pools'].append(self._build_pool_stats(peer_pool))
|
||||
|
||||
if self._replica_enabled:
|
||||
data['replication'] = self._replica_enabled
|
||||
data['replication_enabled'] = self._replica_enabled
|
||||
@ -5758,6 +5779,8 @@ class StorwizeSVCCommonDriver(san.SanDriver,
|
||||
'consistent_group_snapshot_enabled': True,
|
||||
'backend_state': backend_state,
|
||||
'data_reduction': is_dr_pool,
|
||||
'site_id': pool_data['site_id'],
|
||||
'site_name': pool_data['site_name'],
|
||||
}
|
||||
if self._replica_enabled:
|
||||
pool_stats.update({
|
||||
@ -5780,6 +5803,8 @@ class StorwizeSVCCommonDriver(san.SanDriver,
|
||||
'max_over_subscription_ratio': 0,
|
||||
'reserved_percentage': 0,
|
||||
'data_reduction': is_dr_pool,
|
||||
'site_id': None,
|
||||
'site_name': None,
|
||||
'backend_state': 'down'}
|
||||
|
||||
return pool_stats
|
||||
|
@ -0,0 +1,7 @@
|
||||
---
|
||||
fixes:
|
||||
- |
|
||||
IBM Spectrum Virtualize Family driver `Bug #1917605
|
||||
<https://bugs.launchpad.net/cinder/+bug/1917605>`_: Fixed issue
|
||||
in StorwizeSVCCommonDriver to save site and peer pool information
|
||||
in stats during initialization.
|
Loading…
x
Reference in New Issue
Block a user