DAEMON=@sbindir@/${NAME}
BUSER=@sd_user@
BGROUP=@sd_group@
-BOPTIONS="-c @sysconfdir@/${NAME}.conf"
+BOPTIONS="-dt -c @sysconfdir@/${NAME}.conf"
BPORT=@sd_port@
PATH=/sbin:/bin:/usr/sbin:/usr/bin
DAEMON_USER=yes
SD_USER=@sd_user@
SD_GROUP=@sd_group@
-SD_OPTIONS=''
+SD_OPTIONS='-dt'
OS=`uname -s`
# if /lib/tls exists, force Bacula to use the glibc pthreads instead
[ -x ${BACSDBIN}/bacula-sd ] && {
sleep 2
echo -n "Starting the Storage daemon: "
- OPTIONS=''
+ OPTIONS='-dt'
if [ "${SD_USER}" != '' ]; then
OPTIONS="${OPTIONS} -u ${SD_USER}"
fi
# this gives us funtion rc_status -v to tell us if we succeed or fail
. /etc/rc.status
+DAEMON_OPTIONS=''
+DAEMON_USER=yes
+SD_USER=@sd_user@
+SD_GROUP=@sd_group@
+SD_OPTIONS='-dt'
+OS=`uname -s`
+
+# pull in any user defined SD_OPTIONS, SD_USER, SD_GROUP or DAEMON_USER
+[ -f /etc/sysconfig/bacula ] && . /etc/sysconfig/bacula
+
RETVAL=0
case "$1" in
start)
case "$1" in
start)
echo "Starting the Storage daemon"
- @sbindir@/bacula-sd $2 -v -c @sysconfdir@//bacula-sd.conf
+ @sbindir@/bacula-sd $2 -dt -v -c @sysconfdir@//bacula-sd.conf
echo "Starting the File daemon"
@sbindir@/bacula-fd $2 -v -c @sysconfdir@//bacula-fd.conf
sleep 2
Type=simple
User=@sd_user@
Group=@sd_group@
-ExecStart=@sbindir@/bacula-sd -fP -c @sysconfdir@/bacula-sd.conf
-SuccessExitStatus=15
+Environment="LD_LIBRARY_PATH=@libdir@"
+# comment out to get traces working at startup using -T and -d options
+#WorkingDirectory=@working_dir@
+ExecStart=@sbindir@/bacula-sd -dt -c @sysconfdir@/bacula-sd.conf
+StandardError=syslog
+TimeoutStopSec=3min
LimitMEMLOCK=infinity
[Install]