3 # Copyright (C) 2000-2015 Kern Sibbald
4 # License: BSD 2-Clause; see file LICENSE-FOSS
6 # bacula This shell script takes care of starting and stopping
7 # the bacula Storage daemon.
9 # description: The Leading Open Source Backup Solution.
11 # For Bacula release @VERSION@ (@DATE@) -- @DISTNAME@
20 if [ ! -z "${DIR_USER}" ]; then
21 [ -z "${DIR_OPTIONS}" ] && DIR_OPTIONS="-u ${DIR_USER}" || \
22 DIR_OPTIONS="${DIR_OPTIONS} -u ${DIR_USER}"
24 if [ ! -z "${DIR_GROUP}" ]; then
25 [ -z "${DIR_OPTIONS}" ] && DIR_OPTIONS="-g ${DIR_GROUP}" || \
26 DIR_OPTIONS="${DIR_OPTIONS} -g ${DIR_GROUP}"
29 echo "Starting the Bacula Storage daemon: "
30 @sbindir@/bacula-sd $2 ${SD_OPTIONS} -c @sysconfdir@/bacula-sd.conf
33 echo "Stopping the Bacula Storage daemon: "
34 if [ -x /usr/bin/zonename ]; then
35 case `/usr/bin/zonename` in
37 pkill -z global -x bacula-sd
53 echo "Usage: $0 {start|stop|restart}"