From dac3f7d23c97ec6b6329a7b472bb33431d609eb2 Mon Sep 17 00:00:00 2001 From: Ronnie Sahlberg Date: Sun, 3 Jun 2007 19:24:52 +1000 Subject: [PATCH] ubuntu uses a different style of init scripts than redhat and suse (This used to be ctdb commit 6d3bee5d1a7dd6718045c673cfd150e3207ea970) --- ctdb/config/ctdb.init | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/ctdb/config/ctdb.init b/ctdb/config/ctdb.init index 3f6575a2a93..ad7bd705312 100755 --- a/ctdb/config/ctdb.init +++ b/ctdb/config/ctdb.init @@ -66,8 +66,11 @@ CTDB_OPTIONS="$CTDB_OPTIONS --reclock=$CTDB_RECOVERY_LOCK" if [ -x /sbin/startproc ]; then init_style="suse" -else - init_style="redhat" +else if [ -x /sbin/start-stop-daemon ]; then + init_style="ubuntu" + else + init_style="redhat" + fi fi start() { @@ -85,6 +88,10 @@ start() { [ $RETVAL -eq 0 ] && touch /var/lock/subsys/ctdb || RETVAL=1 return $RETVAL ;; + ubuntu) + start-stop-daemon --start --quiet --background --exec /usr/sbin/ctdbd -- $CTDB_OPTIONS + return $? + ;; esac } -- 2.47.3