Gitweb: http://git.fedorahosted.org/git/?p=cluster.git;a=commitdiff;h=f478706e70f45b... Commit: f478706e70f45bee691cfedd6177226a81aedd16 Parent: 5a4cc0c888396c4efc8d7f6ffffd0e960b5259cb Author: Fabio M. Di Nitto fdinitto@redhat.com AuthorDate: Tue Oct 9 11:28:43 2012 +0200 Committer: Fabio M. Di Nitto fdinitto@redhat.com CommitterDate: Tue Oct 9 11:28:43 2012 +0200
cman init: make sure we start after fence_sanlockd and warn users
Resolves: rhbz#509056
Signed-off-by: Fabio M. Di Nitto fdinitto@redhat.com --- cman/init.d/cman.in | 13 +++++++++++-- 1 files changed, 11 insertions(+), 2 deletions(-)
diff --git a/cman/init.d/cman.in b/cman/init.d/cman.in index a88f52f..849739b 100644 --- a/cman/init.d/cman.in +++ b/cman/init.d/cman.in @@ -8,8 +8,8 @@ # ### BEGIN INIT INFO # Provides: cman -# Required-Start: $network $time -# Required-Stop: $network $time +# Required-Start: $network $time fence_sanlockd +# Required-Stop: $network $time fence_sanlockd # Default-Start: # Default-Stop: # Short-Description: Starts and stops cman @@ -740,6 +740,13 @@ stop_cmannotifyd() stop_daemon cmannotifyd }
+fence_sanlock_check() +{ + service fence_sanlockd status > /dev/null 2>&1 && + echo " fence_sanlockd detected. Unfencing might take several minutes!" + return 0 +} + unfence_self() { # fence_node returns 0 on success, 1 on failure, 2 if unconfigured @@ -881,6 +888,8 @@ start()
[ "$breakpoint" = "daemons" ] && exit 0
+ fence_sanlock_check + runwrap unfence_self \ none \ "Unfencing self"
cluster-commits@lists.stg.fedorahosted.org