!466 修复打开uppercase_attribute_name后,执行gs_om -t status和gs_om restart失败的问题

Merge pull request !466 from pengjiong/encode_sub
This commit is contained in:
opengauss-bot 2023-05-05 02:09:34 +00:00 committed by Gitee
commit 59f97639c8
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F

View File

@ -1357,14 +1357,14 @@ class dbClusterInfo():
roleStatus = "Unknown"
dbState = "Unknown"
else:
res = re.findall(r'local_role\s*:\s*(\w+)', output)
res = re.findall(r'local_role\s*:\s*(\w+)', output, re.IGNORECASE)
roleStatus = res[0]
res = re.findall(r'db_state\s*:\s*(\w+)', output)
res = re.findall(r'db_state\s*:\s*(\w+)', output, re.IGNORECASE)
dbState = res[0]
if (dbState == "Need"):
detailInformation = re.findall(
r'detail_information\s*:\s*(\w+)', output)
r'detail_information\s*:\s*(\w+)', output, re.IGNORECASE)
dbState = "Need repair(%s)" % detailInformation[0]
roleStatusArray.append(roleStatus)
dbStateArray.append(dbState)