summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKaleb S. KEITHLEY <kkeithle@redhat.com>2020-05-04 09:11:03 -0400
committerKaleb S. KEITHLEY <kkeithle@redhat.com>2020-05-04 09:12:55 -0400
commit251e43ca9fcf216d8f045d9e2937ad9870be15d8 (patch)
tree68ecc165b2950277c4d2f763ea6bb699355d5800
parent2ab575778d3c0c500e798ae83a41e700d118a6be (diff)
common-ha: cluster status shows "FAILOVER" when actually HEALTHY
pacemaker devs change the format of the ouput of `pcs status` Expected to find a line in the format: Online: .... but now it's * Online: ... And the `grep -E "^Online:" no longer finds the list of nodes that are online. Also other lines now have '*' in first few characters of the line throwing off `grep -x ...` Change-Id: Ia04a89e76914f2a455a755f0a93fa415f60aefd0 Fixes: #1169 Signed-off-by: Kaleb S. KEITHLEY <kkeithle@redhat.com>
-rw-r--r--extras/ganesha/scripts/ganesha-ha.sh5
1 files changed, 3 insertions, 2 deletions
diff --git a/extras/ganesha/scripts/ganesha-ha.sh b/extras/ganesha/scripts/ganesha-ha.sh
index df333a19f94..4ecf91b65e6 100644
--- a/extras/ganesha/scripts/ganesha-ha.sh
+++ b/extras/ganesha/scripts/ganesha-ha.sh
@@ -919,8 +919,9 @@ status()
local index=1
local nodes
- # change tabs to spaces, strip leading spaces
- pcs status | sed -e "s/\t/ /g" -e "s/^[ ]*//" > ${scratch}
+ # change tabs to spaces, strip leading spaces, including any
+ # new '*' at the beginning of a line introduced in pcs-0.10.x
+ pcs status | sed -e "s/\t/ /g" -e "s/^[ ]*\*//" -e "s/^[ ]*//" > ${scratch}
nodes[0]=${1}; shift