Gitweb: http://git.fedorahosted.org/git/?p=cluster.git;a=commitdiff;h=cdce3c1925cb75... Commit: cdce3c1925cb75e21c79c31b60269642e98e256d Parent: 5fa8099c3dad18712941a5fbea1379a6e2ffdadd 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: Wed Oct 10 10:25:58 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 b64bb17..0f40097 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 @@ -678,6 +678,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 @@ -818,6 +825,8 @@ start()
[ "$breakpoint" = "daemons" ] && exit 0
+ fence_sanlock_check + runwrap unfence_self \ none \ "Unfencing self"
cluster-commits@lists.stg.fedorahosted.org