Merge "[Pure Storage] Remove SafeMode PGs from Replication Pods"
This commit is contained in:
commit
5f21510c45
@ -2821,6 +2821,31 @@ class PureBaseVolumeDriver(san.SanDriver):
|
|||||||
" eradicated - will recreate.", name)
|
" eradicated - will recreate.", name)
|
||||||
source_array.delete_pods(names=[name])
|
source_array.delete_pods(names=[name])
|
||||||
self._create_pod_if_not_exist(source_array, name)
|
self._create_pod_if_not_exist(source_array, name)
|
||||||
|
else:
|
||||||
|
if self._array.safemode:
|
||||||
|
# Now we check to ensure that the created pod does not have a
|
||||||
|
# safemode protection group attached to it as this is not
|
||||||
|
# supported by Cinder
|
||||||
|
safemode_pg = list(
|
||||||
|
source_array.get_container_default_protections(
|
||||||
|
names=[name]).items)[0].default_protections
|
||||||
|
if safemode_pg:
|
||||||
|
pgname = safemode_pg[0].name
|
||||||
|
res = source_array.patch_container_default_protections(
|
||||||
|
names=[name],
|
||||||
|
container_default_protection=(
|
||||||
|
flasharray.ContainerDefaultProtection(
|
||||||
|
default_protections=[])))
|
||||||
|
if res.status_code != 200:
|
||||||
|
LOG.warning("Failed to remove Default Protection "
|
||||||
|
"Container: %s", res.errors[0])
|
||||||
|
else:
|
||||||
|
source_array.patch_protection_groups(
|
||||||
|
names=[pgname],
|
||||||
|
protection_group=flasharray.ProtectionGroup(
|
||||||
|
destroyed=True))
|
||||||
|
source_array.delete_protection_groups(
|
||||||
|
names=[pgname])
|
||||||
|
|
||||||
@pure_driver_debug_trace
|
@pure_driver_debug_trace
|
||||||
def _create_protection_group_if_not_exist(self, source_array, pgname):
|
def _create_protection_group_if_not_exist(self, source_array, pgname):
|
||||||
|
@ -0,0 +1,6 @@
|
|||||||
|
---
|
||||||
|
fixes:
|
||||||
|
- |
|
||||||
|
[Pure Storage] When using synchronous replication, ensure that
|
||||||
|
FlashArray pods used by Cinder do not have SafeMode protection
|
||||||
|
groups attached, as SafeMode is not supported by Cinder.
|
Loading…
x
Reference in New Issue
Block a user