From fcb05df6aa47bfe65a05724abfcdf7baf350d085 Mon Sep 17 00:00:00 2001 From: Martin Schwenke Date: Tue, 11 Jan 2011 17:12:03 +1100 Subject: [PATCH] Eventscripts: only autostart during a monitor event. Otherwise we might short-circuit events that are run only once and actually need to do something. Signed-off-by: Martin Schwenke --- config/functions | 3 +++ 1 file changed, 3 insertions(+) diff --git a/config/functions b/config/functions index 8dac1619..6c44fb8d 100755 --- a/config/functions +++ b/config/functions @@ -692,6 +692,8 @@ ctdb_start_stop_service () { _service_name="${1:-${service_name}}" + [ "$event_name" = "monitor" ] || return 0 + _active="$ctdb_active_dir/$_service_name" if is_ctdb_managed_service "$_service_name"; then if ! [ -e "$_active" ] ; then @@ -887,3 +889,4 @@ update_tickles () script_name="${0##*/}" # basename service_name="$script_name" # default is just the script name service_fail_limit=1 +event_name="$1" -- 2.34.1