]> git.sur5r.net Git - bacula/bacula/blob - bacula/patches/1.38.x/1.38.6-script.patch
Create patches/2.0.1-restart.patch. Fixes bug #755.
[bacula/bacula] / bacula / patches / 1.38.x / 1.38.6-script.patch
1
2  This patch fixes a bug in the bacula start/stop script where
3  the binary directory is used rather than the scripts directory.
4  Apply the patch to version 1.38.6 with:
5
6  cd <bacula-source>
7  patch -p0 <1.38.6-script.patch
8  make Makefiles
9  make install
10  ...
11
12 Index: scripts/bacula.in
13 ===================================================================
14 RCS file: /cvsroot/bacula/bacula/scripts/bacula.in,v
15 retrieving revision 1.13.2.3
16 diff -u -r1.13.2.3 bacula.in
17 --- scripts/bacula.in   28 Mar 2006 16:42:19 -0000      1.13.2.3
18 +++ scripts/bacula.in   29 Mar 2006 16:24:51 -0000
19 @@ -13,25 +13,22 @@
20  #  easier to "steal" this code for the development 
21  #  environment where they are different.
22  #  
23 -BACFDBIN=@sbindir@
24  BACFDCFG=@sysconfdir@
25 -BACSDBIN=@sbindir@
26  BACSDCFG=@sysconfdir@
27 -BACDIRBIN=@sbindir@
28  BACDIRCFG=@sysconfdir@
29  
30  case "$1" in
31     start)
32 -      [ -x ${BACSDBIN}/bacula-ctl-sd ] && ${BACSDBIN}/bacula-ctl-sd $1 $2
33 -      [ -x ${BACFDBIN}/bacula-ctl-fd ] && ${BACFDBIN}/bacula-ctl-fd $1 $2
34 -      [ -x ${BACDIRBIN}/bacula-ctl-dir ] && ${BACDIRBIN}/bacula-ctl-dir $1 $2
35 +      [ -x ${BACSDCFG}/bacula-ctl-sd ] && ${BACSDCFG}/bacula-ctl-sd $1 $2
36 +      [ -x ${BACFDCFG}/bacula-ctl-fd ] && ${BACFDCFG}/bacula-ctl-fd $1 $2
37 +      [ -x ${BACDIRCFG}/bacula-ctl-dir ] && ${BACDIRCFG}/bacula-ctl-dir $1 $2
38        ;;
39  
40     stop)
41        # Stop the FD first so that SD will fail jobs and update catalog
42 -      [ -x ${BACFDBIN}/bacula-ctl-fd ] && ${BACFDBIN}/bacula-ctl-fd $1 $2
43 -      [ -x ${BACSDBIN}/bacula-ctl-sd ] && ${BACSDBIN}/bacula-ctl-sd $1 $2
44 -      [ -x ${BACDIRBIN}/bacula-ctl-dir ] && ${BACDIRBIN}/bacula-ctl-dir $1 $2
45 +      [ -x ${BACFDCFG}/bacula-ctl-fd ] && ${BACFDCFG}/bacula-ctl-fd $1 $2
46 +      [ -x ${BACSDCFG}/bacula-ctl-sd ] && ${BACSDCFG}/bacula-ctl-sd $1 $2
47 +      [ -x ${BACDIRCFG}/bacula-ctl-dir ] && ${BACDIRCFG}/bacula-ctl-dir $1 $2
48        echo
49        sleep 6
50        ;;
51 @@ -42,9 +39,9 @@
52        ;;
53  
54     status)
55 -      [ -x ${BACSDBIN}/bacula-ctl-sd ] && ${BACSDBIN}/bacula-ctl-sd status
56 -      [ -x ${BACFDBIN}/bacula-ctl-fd ] && ${BACFDBIN}/bacula-ctl-fd status
57 -      [ -x ${BACDIRBIN}/bacula-ctl-dir ] && ${BACDIRBIN}/bacula-ctl-dir status
58 +      [ -x ${BACSDCFG}/bacula-ctl-sd ] && ${BACSDCFG}/bacula-ctl-sd status
59 +      [ -x ${BACFDCFG}/bacula-ctl-fd ] && ${BACFDCFG}/bacula-ctl-fd status
60 +      [ -x ${BACDIRCFG}/bacula-ctl-dir ] && ${BACDIRCFG}/bacula-ctl-dir status
61        ;;
62  
63     *)