summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJiffin Tony Thottan <jthottan@redhat.com>2017-02-22 18:30:53 +0530
committerKaleb KEITHLEY <kkeithle@redhat.com>2017-02-23 10:27:15 -0500
commit24eed72f7359db33df9fe4b02fe3f2d3ce4a5665 (patch)
tree414d5d1f180f4a7d0f4d85a9b981156aac1a454d
parenta8e8bd57e25f79927ac33d51393b9e3c7441f575 (diff)
ganesha/scripts : restart pcs cluster during add node
In RHEL 6 due to this change https://review.gluster.org/#/c/16122/ restart of HA cluster become requirement after adding a node to cluster After add node "pcs cluster node add <hostname>" following message is coming up : Warning: Using udpu transport on a RHEL 6 cluster, cluster restart is required to apply node addition Thanks Manisha for founding issue and suggesting the fix. Change-Id: I9e55d4ba04ed2555d27f26f71b95b8bd6a67f94c BUG: 1425919 Signed-off-by: Jiffin Tony Thottan <jthottan@redhat.com> Reviewed-on: https://review.gluster.org/16721 Smoke: Gluster Build System <jenkins@build.gluster.org> NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org> Tested-by: Kaleb KEITHLEY <kkeithle@redhat.com> Reviewed-by: soumya k <skoduri@redhat.com> CentOS-regression: Gluster Build System <jenkins@build.gluster.org> Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com>
-rw-r--r--extras/ganesha/scripts/ganesha-ha.sh20
1 files changed, 14 insertions, 6 deletions
diff --git a/extras/ganesha/scripts/ganesha-ha.sh b/extras/ganesha/scripts/ganesha-ha.sh
index 5b26702a07b..cca2d84321b 100644
--- a/extras/ganesha/scripts/ganesha-ha.sh
+++ b/extras/ganesha/scripts/ganesha-ha.sh
@@ -671,12 +671,6 @@ addnode_create_resources()
local add_vip=${1}; shift
local cibfile=$(mktemp -u)
- # start HA on the new node
- pcs cluster start ${add_node}
- if [ $? -ne 0 ]; then
- logger "warning: pcs cluster start ${add_node} failed"
- fi
-
pcs cluster cib ${cibfile}
if [ $? -ne 0 ]; then
logger "warning: pcs cluster cib ${cibfile} failed"
@@ -696,6 +690,7 @@ addnode_create_resources()
logger "warning: pcs cluster cib-push ${cibfile} failed"
fi
rm -f ${cibfile}
+
}
@@ -1075,6 +1070,19 @@ main()
logger "warning: pcs cluster node add ${node} failed"
fi
+ sleep 2
+ # restart of HA cluster required on RHEL 6 because of BZ1404410
+ pcs cluster stop --all
+ if [ $? -ne 0 ]; then
+ logger "warning: pcs cluster stopping cluster failed"
+ fi
+
+ sleep 2
+ pcs cluster start --all
+ if [ $? -ne 0 ]; then
+ logger "warning: pcs cluster starting cluster failed"
+ fi
+
addnode_create_resources ${node} ${vip}
# Subsequent add-node recreates resources for all the nodes
# that already exist in the cluster. The nodes are picked up