bacula/bacula.patch

changeset 20
8adc5213fd55
child 21
5ba5c2911c12
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/bacula/bacula.patch	Wed Jan 07 00:25:41 2009 +0100
     1.3 @@ -0,0 +1,131 @@
     1.4 +Index: manpages/Makefile.in
     1.5 +--- manpages/Makefile.in.orig	2007-04-24 17:47:01 +0200
     1.6 ++++ manpages/Makefile.in	2008-07-09 07:45:59 +0200
     1.7 +@@ -20,23 +20,21 @@
     1.8 + install:
     1.9 + 	$(MKDIR) $(DESTDIR)/$(mandir)/man8
    1.10 + 	for I in ${MAN8}; \
    1.11 +-	  do ($(RMF) $$I.gz; gzip -c $$I >$$I.gz; \
    1.12 +-	     $(INSTALL_DATA) $$I.gz $(DESTDIR)$(mandir)/man8/$$I.gz; \
    1.13 +-	     rm -f $$I.gz); \
    1.14 ++	  do \
    1.15 ++	     $(INSTALL_DATA) $$I $(DESTDIR)$(mandir)/man8/$$I; \
    1.16 + 	done
    1.17 + 	$(MKDIR) $(DESTDIR)/$(mandir)/man1
    1.18 + 	for I in ${MAN1}; \
    1.19 +-	  do ($(RMF) $$I.gz; gzip -c $$I >$$I.gz; \
    1.20 +-	     $(INSTALL_DATA) $$I.gz $(DESTDIR)$(mandir)/man1/$$I.gz; \
    1.21 +-	     rm -f $$I.gz); \
    1.22 ++	  do  \
    1.23 ++	     $(INSTALL_DATA) $$I $(DESTDIR)$(mandir)/man1/$$I; \
    1.24 + 	done
    1.25 + 
    1.26 + uninstall:
    1.27 + 	for I in ${MAN8}; \
    1.28 +-	  do (rm -f $(DESTDIR)$(mandir)/man8/$$I.gz); \
    1.29 ++	  do (rm -f $(DESTDIR)$(mandir)/man8/$$I); \
    1.30 + 	done
    1.31 + 	for I in ${MAN1}; \
    1.32 +-	  do (rm -f $(DESTDIR)$(mandir)/man1/$$I.gz); \
    1.33 ++	  do (rm -f $(DESTDIR)$(mandir)/man1/$$I); \
    1.34 + 	done
    1.35 + 
    1.36 + clean:	dummy
    1.37 +Index: scripts/bacula.in
    1.38 +--- scripts/bacula.in.orig	2008-07-06 15:06:15 +0200
    1.39 ++++ scripts/bacula.in	2008-07-09 07:53:22 +0200
    1.40 +@@ -15,30 +15,36 @@
    1.41 + #  
    1.42 + SCRIPTDIR=@scriptdir@
    1.43 + 
    1.44 ++action=$1
    1.45 ++debug=$2
    1.46 ++[ -n "$3" ] && enable_dir=$3 || enable_dir=yes
    1.47 ++[ -n "$4" ] && enable_sd=$4  || enable_sd=yes
    1.48 ++[ -n "$5" ] && enable_fd=$5  || enable_fd=yes
    1.49 ++
    1.50 + case "$1" in
    1.51 +    start)
    1.52 +-      [ -x ${SCRIPTDIR}/bacula-ctl-sd ] && ${SCRIPTDIR}/bacula-ctl-sd $1 $2
    1.53 +-      [ -x ${SCRIPTDIR}/bacula-ctl-fd ] && ${SCRIPTDIR}/bacula-ctl-fd $1 $2
    1.54 +-      [ -x ${SCRIPTDIR}/bacula-ctl-dir ] && ${SCRIPTDIR}/bacula-ctl-dir $1 $2
    1.55 ++      [ "$enable_sd" = "yes" ] && [ -x ${SCRIPTDIR}/bacula-ctl-sd ] && ${SCRIPTDIR}/bacula-ctl-sd $1 $2
    1.56 ++      [ "$enable_fd" = "yes" ] && [ -x ${SCRIPTDIR}/bacula-ctl-fd ] && ${SCRIPTDIR}/bacula-ctl-fd $1 $2
    1.57 ++      [ "$enable_dir" = "yes" ] && [ -x ${SCRIPTDIR}/bacula-ctl-dir ] && ${SCRIPTDIR}/bacula-ctl-dir $1 $2
    1.58 +       ;;
    1.59 + 
    1.60 +    stop)
    1.61 +       # Stop the FD first so that SD will fail jobs and update catalog
    1.62 +-      [ -x ${SCRIPTDIR}/bacula-ctl-fd ] && ${SCRIPTDIR}/bacula-ctl-fd $1 $2
    1.63 +-      [ -x ${SCRIPTDIR}/bacula-ctl-sd ] && ${SCRIPTDIR}/bacula-ctl-sd $1 $2
    1.64 +-      [ -x ${SCRIPTDIR}/bacula-ctl-dir ] && ${SCRIPTDIR}/bacula-ctl-dir $1 $2
    1.65 ++      [ "$enable_fd" = "yes" ] && [ -x ${SCRIPTDIR}/bacula-ctl-fd ] && ${SCRIPTDIR}/bacula-ctl-fd $1 $2
    1.66 ++      [ "$enable_sd" = "yes" ] && [ -x ${SCRIPTDIR}/bacula-ctl-sd ] && ${SCRIPTDIR}/bacula-ctl-sd $1 $2
    1.67 ++      [ "$enable_dir" = "yes" ] && [ -x ${SCRIPTDIR}/bacula-ctl-dir ] && ${SCRIPTDIR}/bacula-ctl-dir $1 $2
    1.68 +       ;;
    1.69 + 
    1.70 +    restart)
    1.71 +-      $0 stop
    1.72 ++      $0 stop  $debug $enable_dir $enable_sd $enable_fd
    1.73 +       sleep 2
    1.74 +-      $0 start
    1.75 ++      $0 start $debug $enable_dir $enable_sd $enable_fd
    1.76 +       ;;
    1.77 + 
    1.78 +    status)
    1.79 +-      [ -x ${SCRIPTDIR}/bacula-ctl-sd ] && ${SCRIPTDIR}/bacula-ctl-sd status
    1.80 +-      [ -x ${SCRIPTDIR}/bacula-ctl-fd ] && ${SCRIPTDIR}/bacula-ctl-fd status
    1.81 +-      [ -x ${SCRIPTDIR}/bacula-ctl-dir ] && ${SCRIPTDIR}/bacula-ctl-dir status
    1.82 ++      [ "$enable_sd" = "yes" ] && [ -x ${SCRIPTDIR}/bacula-ctl-sd ] && ${SCRIPTDIR}/bacula-ctl-sd status
    1.83 ++      [ "$enable_fd" = "yes" ] && [ -x ${SCRIPTDIR}/bacula-ctl-fd ] && ${SCRIPTDIR}/bacula-ctl-fd status
    1.84 ++      [ "$enable_dir" = "yes" ] && [ -x ${SCRIPTDIR}/bacula-ctl-dir ] && ${SCRIPTDIR}/bacula-ctl-dir status
    1.85 +       ;;
    1.86 + 
    1.87 +    *)
    1.88 +Index: scripts/btraceback.in
    1.89 +--- scripts/btraceback.in.orig	2008-06-01 10:49:00 +0200
    1.90 ++++ scripts/btraceback.in	2008-07-09 07:45:59 +0200
    1.91 +@@ -12,6 +12,9 @@
    1.92 + PNAME="${PNAME} on `hostname`"
    1.93 + if test `uname -s` = SunOS ; then
    1.94 +   gcore -o @working_dir@/${PNAME} $2
    1.95 ++fi
    1.96 ++if test `uname -s` = SunOS &&
    1.97 ++   test -n `which dbx 2>/dev/null` ; then
    1.98 +   dbx $1 $2 <@scriptdir@/btraceback.dbx 2>&1 \
    1.99 +    | @sbindir@/bsmtp -h @smtp_host@ -f @dump_email@ -s "Bacula DBX traceback of ${PNAME}" @dump_email@
   1.100 + else
   1.101 +Index: src/dird/bacula-dir.conf.in
   1.102 +--- src/dird/bacula-dir.conf.in.orig	2008-06-19 21:44:34 +0200
   1.103 ++++ src/dird/bacula-dir.conf.in	2008-07-09 07:45:59 +0200
   1.104 +@@ -29,7 +29,8 @@
   1.105 +   Level = Incremental
   1.106 +   Client = @hostname@-fd 
   1.107 +   FileSet = "Full Set"
   1.108 +-  Schedule = "WeeklyCycle"
   1.109 ++ #Schedule = "WeeklyCycle"
   1.110 ++  Schedule = "NEVER"
   1.111 +   Storage = File
   1.112 +   Messages = Standard
   1.113 +   Pool = Default
   1.114 +@@ -109,7 +110,7 @@
   1.115 + #    directory to give a reasonable FileSet to backup to
   1.116 + #    disk storage during initial testing.
   1.117 + #
   1.118 +-    File = @BUILD_DIR@
   1.119 ++    File = @scriptdir@
   1.120 +   }
   1.121 + 
   1.122 + #
   1.123 +@@ -124,6 +125,11 @@
   1.124 +   }
   1.125 + }
   1.126 + 
   1.127 ++# This schedule can be used to disable automatic scheduling
   1.128 ++Schedule {
   1.129 ++  Name = NEVER
   1.130 ++}
   1.131 ++
   1.132 + #
   1.133 + # When to do the backups, full backup on first sunday of the month,
   1.134 + #  differential (i.e. incremental since full) every other sunday,

mercurial