From f386d5ed7e88bbeaddc6992eefaf9efcc074dfa4 Mon Sep 17 00:00:00 2001 From: alexpeshkoff Date: Fri, 25 Apr 2008 16:37:30 +0000 Subject: [PATCH] Use -daemon switch to start fbguard directly - without fbmgr. --- .../arch-specific/linux/misc/firebird.init.d.debian.in | 8 ++++---- .../arch-specific/linux/misc/firebird.init.d.generic.in | 6 +++--- .../arch-specific/linux/misc/firebird.init.d.gentoo.in | 6 +++--- .../arch-specific/linux/misc/firebird.init.d.mandrake.in | 4 ++-- .../arch-specific/linux/misc/firebird.init.d.slackware.in | 6 +++--- .../arch-specific/linux/misc/firebird.init.d.suse.in | 3 +-- 6 files changed, 16 insertions(+), 17 deletions(-) diff --git a/builds/install/arch-specific/linux/misc/firebird.init.d.debian.in b/builds/install/arch-specific/linux/misc/firebird.init.d.debian.in index ab284956af..394d7bd67d 100644 --- a/builds/install/arch-specific/linux/misc/firebird.init.d.debian.in +++ b/builds/install/arch-specific/linux/misc/firebird.init.d.debian.in @@ -18,19 +18,19 @@ FIREBIRD=@prefix@ FBRunUser=firebird pidfile=/var/run/firebird/`basename $0`.pid -FB_OPTS="-pidfile $pidfile -start -forever" +FB_OPTS="-pidfile $pidfile -daemon -forever" export FIREBIRD # Check the file is there and is executable. -MANAGER=$FIREBIRD/bin/fbmgr.bin -[ -x $MANAGER ] || exit 0 +GUARDIAN=$FIREBIRD/bin/fbguard +[ -x $GUARDIAN ] || exit 0 # See how we were called. case "$1" in start) echo -n "Starting Firebird server: " - start-stop-daemon --start --quiet --oknodo --chuid $FBRunUser --exec $MANAGER -- $FB_OPTS + start-stop-daemon --start --quiet --oknodo --chuid $FBRunUser --exec $GUARDIAN -- $FB_OPTS RETVAL=$? ;; stop) diff --git a/builds/install/arch-specific/linux/misc/firebird.init.d.generic.in b/builds/install/arch-specific/linux/misc/firebird.init.d.generic.in index ac03739847..fd50a4a4e0 100644 --- a/builds/install/arch-specific/linux/misc/firebird.init.d.generic.in +++ b/builds/install/arch-specific/linux/misc/firebird.init.d.generic.in @@ -18,16 +18,16 @@ LD_LIBRARY_PATH=$FIREBIRD/lib export FIREBIRD LD_LIBRARY_PATH -MANAGER=$FIREBIRD/bin/fbmgr.bin +GUARDIAN=$FIREBIRD/bin/fbguard # Check the file is there and is executable. -[ -x $MANAGER ] || exit 0 +[ -x $GUARDIAN ] || exit 0 # See how we were called. case "$1" in start) echo -n "Starting $FULLNAME: " - echo "$MANAGER -pidfile $pidfile -start -forever" | su $FBRunUser + echo "$GUARDIAN -pidfile $pidfile -daemon -forever" | su $FBRunUser RETVAL=$? ;; stop) diff --git a/builds/install/arch-specific/linux/misc/firebird.init.d.gentoo.in b/builds/install/arch-specific/linux/misc/firebird.init.d.gentoo.in index c0711aca80..2f5a2146ac 100644 --- a/builds/install/arch-specific/linux/misc/firebird.init.d.gentoo.in +++ b/builds/install/arch-specific/linux/misc/firebird.init.d.gentoo.in @@ -22,15 +22,15 @@ FBRunUser=firebird pidfile=/var/run/firebird/$INSTANCE.pid FULLNAME="firebird server [$INSTANCE]" LD_LIBRARY_PATH=$FIREBIRD/lib -FB_OPTS="-pidfile $pidfile -start -forever" +FB_OPTS="-pidfile $pidfile -daemon -forever" export FIREBIRD LD_LIBRARY_PATH -MANAGER=$FIREBIRD/bin/fbmgr.bin +GUARDIAN=$FIREBIRD/bin/fbguard start(){ ebegin "Starting $FULLNAME" - start-stop-daemon --oknodo --start --pidfile $pidfile --chuid $FBRunUser --startas $MANAGER -- $FB_OPTS + start-stop-daemon --oknodo --start --pidfile $pidfile --chuid $FBRunUser --startas $GUARDIAN -- $FB_OPTS eend $? } diff --git a/builds/install/arch-specific/linux/misc/firebird.init.d.mandrake.in b/builds/install/arch-specific/linux/misc/firebird.init.d.mandrake.in index 41b84f2eef..a6bd17e1b6 100644 --- a/builds/install/arch-specific/linux/misc/firebird.init.d.mandrake.in +++ b/builds/install/arch-specific/linux/misc/firebird.init.d.mandrake.in @@ -29,14 +29,14 @@ LD_LIBRARY_PATH=$FIREBIRD/lib export FIREBIRD LD_LIBRARY_PATH # Check the file is there and is executable. -[ -x $FIREBIRD/bin/fbmgr.bin ] || exit 1 +GUARDIAN=$FIREBIRD/bin/fbguard # See how we were called. case "$1" in start) echo -n "Starting $FULLNAME " - runuser -s /bin/bash $FBRunUser -c "$FIREBIRD/bin/fbmgr.bin -pidfile $pidfile -start -forever" + runuser -s /bin/bash $FBRunUser -c "$GUARDIAN -pidfile $pidfile -daemon -forever" RETVAL=$? [ $RETVAL -eq 0 ] && success || failure echo diff --git a/builds/install/arch-specific/linux/misc/firebird.init.d.slackware.in b/builds/install/arch-specific/linux/misc/firebird.init.d.slackware.in index a0677be3a5..db039c5ecc 100644 --- a/builds/install/arch-specific/linux/misc/firebird.init.d.slackware.in +++ b/builds/install/arch-specific/linux/misc/firebird.init.d.slackware.in @@ -22,14 +22,14 @@ LD_LIBRARY_PATH=$FIREBIRD/lib export FIREBIRD LD_LIBRARY_PATH -MANAGER=$FIREBIRD/bin/fbmgr.bin +GUARDIAN=$FIREBIRD/bin/fbguard # Check the file is there and is executable. -[ -x $MANAGER ] || exit 0 +[ -x $GUARDIAN ] || exit 0 case "$1" in 'start') echo -n "Starting $FULLNAME: " - echo $MANAGER -pidfile $pidfile -start -forever | su $FBRunUser ;; + echo $GUARDIAN -pidfile $pidfile -daemon -forever | su $FBRunUser ;; 'stop') echo -n "Stopping $FULLNAME: " if [ -f $pidfile ]; then kill `cat $pidfile`; echo "done."; else echo "error: no PID file."; fi ;; 'restart') $0 stop ; sleep 1; $0 start ;; diff --git a/builds/install/arch-specific/linux/misc/firebird.init.d.suse.in b/builds/install/arch-specific/linux/misc/firebird.init.d.suse.in index 9b177fabf3..b233f29372 100644 --- a/builds/install/arch-specific/linux/misc/firebird.init.d.suse.in +++ b/builds/install/arch-specific/linux/misc/firebird.init.d.suse.in @@ -46,8 +46,7 @@ pidfile=/var/run/firebird/firebird.pid export FIREBIRD -# Check the file is there and is executable. -[ -x $FIREBIRD/bin/fbmgr ] || exit 5 +# Check the files are there and are executable. [ -x $FIREBIRD/bin/fbguard ] || exit 5 [ -x $FIREBIRD/bin/fbserver ] || exit 5