EMC VMAX - Changing PercentSynced to CopyState in isSynched
In SE 8.x PercentSynced no longer works for VMAX3 as a criteria to determine whether a device is synched or not. Luckily 'CopyState' works for both VMAX2 and VMAX3 and is backward compatible with 7.6.x. Change-Id: I443e5f17f3c0e779ebdfd868bcd05cb85b52f525 Closes-Bug: #1517103
This commit is contained in:
@@ -53,6 +53,7 @@ INTERVAL = 'storagetype:interval'
|
||||
RETRIES = 'storagetype:retries'
|
||||
CIM_ERR_NOT_FOUND = 6
|
||||
VOLUME_ELEMENT_NAME_PREFIX = 'OS-'
|
||||
SYNCHRONIZED = 4
|
||||
|
||||
|
||||
class EMCVMAXUtils(object):
|
||||
@@ -439,15 +440,11 @@ class EMCVMAXUtils(object):
|
||||
"""
|
||||
syncInstance = conn.GetInstance(syncName,
|
||||
LocalOnly=False)
|
||||
percentSynced = syncInstance['PercentSynced']
|
||||
copyState = syncInstance['CopyState']
|
||||
LOG.debug("CopyState is %(copyState)lu.",
|
||||
{'copyState': copyState})
|
||||
|
||||
LOG.debug("Percent synced is %(percentSynced)lu.",
|
||||
{'percentSynced': percentSynced})
|
||||
|
||||
if percentSynced < 100:
|
||||
return False
|
||||
else:
|
||||
return True
|
||||
return copyState == SYNCHRONIZED
|
||||
|
||||
def get_num(self, numStr, datatype):
|
||||
"""Get the ecom int from the number.
|
||||
|
||||
Reference in New Issue
Block a user