cluster: STABLE3 - cman init: move unfencing operation down the line

Fabio M. Di Nitto fabbione at fedoraproject.org
Mon Nov 9 07:27:40 UTC 2009


Gitweb:        http://git.fedorahosted.org/git/cluster.git?p=cluster.git;a=commitdiff;h=bbeb27a249e0aba5d5c281bea2d533bff4b01d5f
Commit:        bbeb27a249e0aba5d5c281bea2d533bff4b01d5f
Parent:        07ad4fabbc55d7c58e427c2065bdbe8ecc7d80eb
Author:        Fabio M. Di Nitto <fdinitto at redhat.com>
AuthorDate:    Mon Nov 9 08:26:21 2009 +0100
Committer:     Fabio M. Di Nitto <fdinitto at redhat.com>
CommitterDate: Mon Nov 9 08:26:21 2009 +0100

cman init: move unfencing operation down the line

As per discussion on cluster-devel, move unfencing operations
right before join fence domain

Signed-off-by: Fabio M. Di Nitto <fdinitto at redhat.com>
---
 cman/init.d/cman.in |   32 ++++++++++++++++----------------
 1 files changed, 16 insertions(+), 16 deletions(-)

diff --git a/cman/init.d/cman.in b/cman/init.d/cman.in
index a58efaf..fc29101 100644
--- a/cman/init.d/cman.in
+++ b/cman/init.d/cman.in
@@ -563,18 +563,6 @@ stop_cman()
 	fi
 }
 
-unfence_self()
-{
-	# fence_node returns 0 on success, 1 on failure, 2 if unconfigured
-	# 0 and 2 are ok. Everything else should report error.
-	fence_node -U > /dev/null 2>&1
-	case $? in
-	0|2)
-		return 0
-	;;
-	esac
-}
-
 start_qdiskd()
 {
 	start_daemon qdiskd "-Q" || return 1
@@ -671,6 +659,18 @@ stop_cmannotifyd()
 	stop_daemon cmannotifyd
 }
 
+unfence_self()
+{
+	# fence_node returns 0 on success, 1 on failure, 2 if unconfigured
+	# 0 and 2 are ok. Everything else should report error.
+	fence_node -U > /dev/null 2>&1
+	case $? in
+	0|2)
+		return 0
+	;;
+	esac
+}
+
 join_fence_domain()
 {
 	if ! cman_tool status | grep Flags | grep 2node \
@@ -748,10 +748,6 @@ start()
 
 	[ "$breakpoint" = "join" ] && exit 0
 
-	runwrap unfence_self \
-		none \
-		"Unfencing self"
-
 	runwrap start_qdiskd \
 		qdiskd_enabled \
 		"Starting qdiskd"
@@ -788,6 +784,10 @@ start()
 
 	[ "$breakpoint" = "daemons" ] && exit 0
 
+	runwrap unfence_self \
+		none \
+		"Unfencing self"
+
 	runwrap join_fence_domain \
 		fence_join_enabled \
 		"Joining fence domain"


More information about the cluster-commits mailing list