1 \chapter{New Features in 7.4.0}
2 This chapter presents the new features that have been added to
3 the various versions of Bacula.
5 \section{New Features in 7.4.0}
6 \subsection{Verify Volume Data}
8 It is now possible to have a Verify Job configured with \texttt{level=Data} to
9 reread all records from a job and optionally check the size and the checksum
13 # Verify Job definition
17 Client = 127.0.0.1-fd # Use local file daemon
18 FileSet = Dummy # Will be adapted during the job
19 Storage = File # Should be the right one
24 # Backup Job definition
45 To run the Verify job, it is possible to use the ``jobid'' parameter of the ``run'' command.
48 *run job=VerifyData jobid=10
54 Pool: Default (From Job resource)
55 Storage: File (From Job resource)
56 Verify Job: MyBackupJob.2015-11-11_09.41.55_03
57 Verify List: /opt/bacula/working/working/VerifyVol.bsr
58 When: 2015-11-11 09:47:38
60 OK to run? (yes/mod/no): yes
65 11-Nov 09:46 my-dir JobId 13: Bacula 7.4.0 (13Nov15):
66 Build OS: x86_64-unknown-linux-gnu archlinux
68 Job: VerifyData.2015-11-11_09.46.29_03
74 Start time: 11-Nov-2015 09:46:31
75 End time: 11-Nov-2015 09:46:32
78 Non-fatal FD errors: 0
80 FD termination status: Verify differences
81 SD termination status: OK
82 Termination: Verify Differences
85 The current Verify Data implementation requires specifying the correct Storage
86 resource in the Verify job. The Storage resource can be changed with the bconsole
87 command line and with the menu.
89 \subsection{Bconsole ``list jobs'' command options}
91 The \texttt{list jobs} bconsole command now accepts new command line options:
94 \item \textbf{joberrors} Display jobs with JobErrors
95 \item \textbf{jobstatus=T} Display jobs with the specified status code
96 \item \textbf{client=cli} Display jobs for a specified client
97 \item \textbf{order=asc/desc} Change the output format of the job list. The
98 jobs are sorted by start time and JobId, the sort can use ascendant (asc) or
99 descendant (desc) (default) value.
102 \subsection{Minor Enhancements}
104 \subsubsection{New Bconsole "Tee All" Command}
106 The ``@tall'' command allows logging all input/output from a console session.
114 \subsection{Windows Encrypted File System (EFS) Support}
116 The Bacula Enterprise Windows File Daemon for the community version
117 7.4.0 now automatically supports files and
118 directories that are encrypted on Windows filesystem.
120 \subsection{SSL Connections to MySQL}
122 There are five new Directives for the Catalog resource in the
123 \bf{bacula-dir.conf} file that you can use to encrypt the
124 communications between Bacula and MySQL for additional
128 \item [dbsslkey] takes a string variable that specifies the filename of an
130 \item [dbsslcert] takes a string variable that specifies the filename of an
131 SSL certificate file.
132 \item [dbsslca] takes a string variable that specifies the filename of a
133 SSL CA (certificate authority) certificate.
134 \item [dbsslcipher] takes a string variable that specifies the cipher
138 \subsection{Max Virtual Full Interval}
139 This is a new Job resource directive that specifies the time in seconds
140 that is a maximum time between Virtual Full jobs. It is much like the
141 Max Full Interval directive but applies to Virtual Full jobs rather
146 \chapter{New Features in 7.2.0}
147 This chapter presents the new features that have been added to
148 the various versions of Bacula.
150 \section{New Features in 7.2.0}
152 \subsection{New Job Edit Codes \%E \%R}
153 In various places such as RunScripts, you have now access to \%E to get the
154 number of non-fatal errors for the current Job and \%R to get the number of
155 bytes read from disk or from the network during a job.
157 \subsection{Enable/Disable commands}
158 The \textbf{bconsole} \textbf{enable} and \textbf{disable} commands have
159 been extended from enabling/disabling Jobs to include Clients, Schedule,
160 and Storage devices. Examples:
163 disable Job=NightlyBackup Client=Windows-fd
166 will disable the Job named \textbf{NightlyBackup} as well as the
167 client named \textbf{Windows-fd}.
170 disable Storage=LTO-changer Drive=1
173 will disable the first drive in the autochanger named \textbf{LTO-changer}.
175 Please note that doing a \textbf{reload} command will set any values
176 changed by the enable/disable commands back to the values in the
177 bacula-dir.conf file.
179 The Client and Schedule resources in the bacula-dir.conf file now permit
180 the directive Enable = yes or Enable = no.
185 \subsection{Snapshot Management}
187 Bacula 7.2 is now able to handle Snapshots on Linux/Unix
188 systems. Snapshots can be automatically created and used to backup files. It is
189 also possible to manage Snapshots from Bacula's \texttt{bconsole} tool through a
192 \subsubsection{Snapshot Backends}
194 The following Snapshot backends are supported with Bacula Enterprise 8.2:
199 \item LVM\footnote{Some restrictions described in \vref{LVMBackend} applies to
203 By default, Snapshots are mounted (or directly available) under
204 \textbf{.snapshots} directory on the root filesystem. (On ZFS, the default
205 is \textbf{.zfs/snapshots}).
209 The Snapshot backend program is called \textbf{bsnapshot} and is available in
210 the \textbf{bacula-enterprise-snapshot} package. In order to use the Snapshot
211 Management feature, the package must be installed on the Client.
214 \label{bsnapshotconf}
215 The \textbf{bsnapshot} program can be configured using
216 \texttt{/opt/bacula/etc/bsnapshot.conf} file. The following parameters can
217 be adjusted in the configuration file:
220 \item \texttt{trace=<file>} Specify a trace file
221 \item \texttt{debug=<num>} Specify a debug level
222 \item \texttt{sudo=<yes/no>} Use sudo to run commands
223 \item \texttt{disabled=<yes/no>} Disable snapshot support
224 \item \texttt{retry=<num>} Configure the number of retries for some operations
225 \item \texttt{snapshot\_dir=<dirname>} Use a custom name for the Snapshot directory. (\textbf{.SNAPSHOT}, \textbf{.snapdir}, etc...)
226 \item \texttt{lvm\_snapshot\_size=<lvpath:size>} Specify a custom snapshot size for a given LVM volume
230 # cat /opt/bacula/etc/bsnapshot.conf
233 lvm_snapshot_size=/dev/ubuntu-vg/root:5%
237 \subsubsection{Application Quiescing}
239 When using Snapshots, it is very important to quiesce applications that are
240 running on the system. The simplest way to quiesce an application is to stop
241 it. Usually, taking the Snapshot is very fast, and the downtime is only about a
242 couple of seconds. If downtime is not possible and/or the application provides
243 a way to quiesce, a more advanced script can be used. An example is
244 described on \vref{SnapRunScriptExample}.
246 \subsubsection{New Director Directives}
248 The use of the Snapshot Engine on the FileDaemon is determined by the
249 new \textbf{Enable Snapshot} FileSet directive. The default is \textbf{no}.
255 Enable Snapshot = yes
258 Options = { Compression = LZO }
264 By default, Snapshots are deleted from the Client at the end of the backup. To
265 keep Snapshots on the Client and record them in the Catalog for a determined
266 period, it is possible to use the \textbf{Snapshot Retention} directive in the
267 Client or in the Job resource. The default value is 0 secconds. If, for a given Job,
268 both Client and Job \textbf{Snapshot Retention} directives are set, the Job
269 directive will be used.
276 Snapshot Retention = 5 days
280 To automatically prune Snapshots, it is possible to use the following RunScript
290 Console = "prune snapshot client=%c yes"
301 In RunScripts, the \texttt{AfterSnapshot} keyword for the \texttt{RunsWhen} directive will
302 allow a command to be run just after the Snapshot creation. \texttt{AfterSnapshot} is a
303 synonym for the \texttt{AfterVSS} keyword.
305 \label{SnapRunScriptExample}
310 Command = "/etc/init.d/mysql start"
311 RunsWhen = AfterSnapshot
315 Command = "/etc/init.d/mysql stop"
322 \subsubsection{Job Output Information}
324 Information about Snapshots are displayed in the Job output. The list of all
325 devices used by the Snapshot Engine is displayed, and the Job summary
326 indicates if Snapshots were available.
329 JobId 3: Create Snapshot of /home/build
330 JobId 3: Create Snapshot of /home/build/subvol
331 JobId 3: Delete snapshot of /home/build
332 JobId 3: Delete snapshot of /home/build/subvol
334 JobId 3: Bacula 127.0.0.1-dir 7.2.0 (23Jul15):
335 Build OS: x86_64-unknown-linux-gnu archlinux
337 Job: Incremental.2015-02-24_11.20.27_08
342 Termination: Backup OK
346 \subsubsection{New ``snapshot'' Bconsole Commands}
348 The new \textbf{snapshot} command will display by default the following menu:
352 1: List snapshots in Catalog
353 2: List snapshots on Client
356 5: Update snapshot parameters
357 6: Update catalog with Client snapshots
359 Select action to perform on Snapshot Engine (1-7):
362 The \textbf{snapshot} command can also have the following parameters:
364 [client=<client-name> | job=<job-name> | jobid=<jobid>]
365 [delete | list | listclient | prune | sync | update]
368 It is also possible to use traditional \texttt{list}, \texttt{llist},
369 \texttt{update}, \texttt{prune} or \texttt{delete} commands on Snapshots.
372 *llist snapshot jobid=5
374 name: NightlySave.2015-02-24_12.01.00_04
375 createdate: 2015-02-24 12:01:03
379 volume: /home/.snapshots/NightlySave.2015-02-24_12.01.00_04
387 * snapshot listclient
388 Automatically selected Client: 127.0.0.1-fd
389 Connecting to Client 127.0.0.1-fd at 127.0.0.1:8102
390 Snapshot NightlySave.2015-02-24_12.01.00_04:
391 Volume: /home/.snapshots/NightlySave.2015-02-24_12.01.00_04
393 CreateDate: 2015-02-24 12:01:03
401 With the \textsl{Update catalog with Client snapshots} option (or
402 \textbf{snapshot sync}), the Director contacts the FileDaemon, lists snapshots
403 of the system and creates catalog records of the Snapshots.
407 Automatically selected Client: 127.0.0.1-fd
408 Connecting to Client 127.0.0.1-fd at 127.0.0.1:8102
409 Snapshot NightlySave.2015-02-24_12.35.47_06:
410 Volume: /home/.snapshots/NightlySave.2015-02-24_12.35.47_06
412 CreateDate: 2015-02-24 12:35:47
416 Snapshot added in Catalog
420 name: NightlySave.2015-02-24_12.35.47_06
421 createdate: 2015-02-24 12:35:47
425 volume: /home/.snapshots/NightlySave.2015-02-24_12.35.47_06
439 \subsubsection{LVM Backend Restrictions}
442 LVM Snapshots are quite primitive compared to ZFS, BTRFS, NetApp and other
443 systems. For example, it is not possible to use Snapshots if the Volume Group
444 (VG) is full. The administrator must keep some free space in the VG
445 to create Snapshots. The amount of free space required depends on the activity of the
446 Logical Volume (LV). \textbf{bsnapshot} uses 10\% of the LV by
447 default. This number can be configured per LV in the
448 \textbf{bsnapshot.conf} file.
451 [root@system1]# vgdisplay
460 Alloc PE / Size 125 / 500,00 MiB
461 Free PE / Size 7507 / 29,32 GiB
465 It is also not advisable to leave snapshots on the LVM backend. Having multiple
466 snapshots of the same LV on LVM will slow down the system.
468 \subsubsection{Debug Options}
470 To get low level information about the Snapshot Engine, the debug tag ``snapshot''
471 should be used in the \textbf{setdebug} command.
474 * setdebug level=10 tags=snapshot client
475 * setdebug level=10 tags=snapshot dir
478 \subsection{Minor Enhancements}
479 \subsubsection{Storage Daemon Reports Disk Usage}
481 The \texttt{status storage} command now reports the space available on disk devices:
486 Device file: "FileStorage" (/bacula/arch1) is not open.
487 Available Space=5.762 GB
490 Device file: "FileStorage1" (/bacula/arch2) is not open.
491 Available Space=5.862 GB
494 \subsection{Data Encryption Cipher Configuration}
495 Bacula Enterprise version 8.0 and later now allows configuration of the data
496 encryption cipher and the digest algorithm. Previously, the cipher was forced to AES 128,
497 but it is now possible to choose between the following ciphers:
500 \item AES128 (default)
506 The digest algorithm was set to SHA1 or SHA256 depending on the local OpenSSL
507 options. We advise you to not modify the PkiDigest default setting. Please,
508 refer to the OpenSSL documentation to understand the pros and cons regarding these options.
517 \subsubsection*{New Option Letter ``M'' for Accurate Directive in FileSet}
519 % waa - 20150317 - is 8.0.5 correct here?
520 Added in version 8.0.5, the new ``M'' option letter for the Accurate directive
521 in the FileSet Options block, which allows comparing the modification time and/or
522 creation time against the last backup timestamp. This is in contrast to the
523 existing options letters ``m'' and/or ``c'', mtime and ctime, which are checked
524 against the stored catalog values, which can vary accross different machines
525 when using the BaseJob feature.
527 The advantage of the new ``M'' option letter for Jobs that refer to BaseJobs is
528 that it will instruct Bacula to backup files based on the last backup time, which
529 is more useful because the mtime/ctime timestamps may differ on various Clients,
530 causing files to be needlessly backed up.
563 Accurate = Ms # check for mtime/ctime of last backup timestamp and Size
572 \subsubsection*{New Debug Options}
574 In Bacula Enterprise version 8.0 and later, we introduced a new \texttt{options} parameter for
575 the \texttt{setdebug} bconsole command.
579 The following arguments to the new \texttt{option} parameter are available to control debug functions.
582 \item [0] Clear debug flags
583 \item [i] Turn off, ignore bwrite() errors on restore on File Daemon
584 \item [d] Turn off decomp of BackupRead() streams on File Daemon
585 \item [t] Turn on timestamps in traces
586 \item [T] Turn off timestamps in traces
588 % waa - 20150306 - does this "c" item mean to say "Truncate trace file if one exists, otherwise append to it" ???
589 \item [c] Truncate trace file if trace file is activated
591 \item [l] Turn on recoding events on P() and V()
592 \item [p] Turn on the display of the event ring when doing a bactrace
597 The following command will enable debugging for the File Daemon, truncate an existing trace file,
598 and turn on timestamps when writing to the trace file.
601 * setdebug level=10 trace=1 options=ct fd
606 It is now possible to use a \textsl{class} of debug messages called \texttt{tags}
607 to control the debug output of Bacula daemons.
610 \item [all] Display all debug messages
611 \item [bvfs] Display BVFS debug messages
612 \item [sql] Display SQL related debug messages
613 \item [memory] Display memory and poolmem allocation messages
614 \item [scheduler] Display scheduler related debug messages
618 * setdebug level=10 tags=bvfs,sql,memory
619 * setdebug level=10 tags=!bvfs
621 # bacula-dir -t -d 200,bvfs,sql
624 The \texttt{tags} option is composed of a list of tags. Tags are separated by
625 ``,'' or ``+'' or ``-'' or ``!''. To disable a specific tag, use ``-'' or ``!''
626 in front of the tag. Note that more tags are planned for future versions.
628 %%\LTXtable{\linewidth}{table_debugtags}
630 \subsection{Read Only Storage Devices}
631 This version of Bacula allows you to define a Storage deamon device
632 to be read-only. If the {\bf Read Only} directive is specified and
633 enabled, the drive can only be used for read operations.
634 The {\bf Read Only} directive can be defined in any bacula-sd.conf
635 Device resource, and is most useful for reserving one or more
636 drives for restores. An example is:
642 \subsection{New Truncate Command}
643 We have added a new truncate command to bconsole which
644 will truncate a volume if the volume is purged, and if
645 the volume is also marked {\bf Action On Purge = Truncate}.
646 This feature was originally added in Bacula version 5.0.1,
647 but the mechanism for actually doing the truncate required
648 the user to enter a complicated command such as:
651 purge volume action=truncate storage=File pool=Default
654 The above command is now simplified to be:
657 truncate storage=File pool=Default
660 \subsection{New Resume Command}
661 The new \texttt{resume} command does exactly the same thing as a
662 {\bf restart} command, but for some users the
663 name may be more logical because in general the
664 {\bf restart} command is used to resume running
665 a Job that was incomplete.
667 \subsection{New Prune ``Expired'' Volume Command}
668 In Bacula Enterprise 6.4, it is now possible to prune all volumes
669 (from a pool, or globally) that are ``expired''. This option can be
670 scheduled after or before the backup of the catalog and can be
671 combined with the \texttt{Truncate On Purge} option. The \texttt{prune expired volme} command may
672 be used instead of the \texttt{manual\_prune.pl} script.
675 * prune expired volume
677 * prune expired volume pool=FullPool
680 To schedule this option automatically, it can be added to the Catalog backup job
688 Console = "prune expired volume yes"
695 \subsection{New Job Edit Codes \%P \%C}
696 In various places such as RunScripts, you have now access to \%P to get the
697 current Bacula process ID (PID) and \%C to know if the current job is a
700 \subsection{Enhanced Status and Error Messages}
701 We have enhanced the Storage daemon status output to be more
702 readable. This is important when there are a large number of
703 devices. In addition to formatting changes, it also includes more
704 details on which devices are reading and writing.
706 A number of error messages have been enhanced to have more specific
707 data on what went wrong.
709 If a file changes size while being backed up the old and new size
712 \subsection{Miscellaneous New Features}
714 \item Allow unlimited line lengths in .conf files (previously limited
717 \item Allow /dev/null in ChangerCommand to indicated a Virtual Autochanger.
719 \item Add a --fileprune option to the manual\_prune.pl script.
721 \item Add a -m option to make\_catalog\_backup.pl to do maintenance
724 \item Safer code that cleans up the working directory when starting
725 the daemons. It limits what files can be deleted, hence enhances
728 \item Added a new .ls command in bconsole to permit browsing a client's
731 \item Fixed a number of bugs, includes some obscure seg faults, and a
732 race condition that occurred infrequently when running Copy, Migration,
733 or Virtual Full backups.
735 \item Upgraded to a newer version of Qt4 for bat. All indications
736 are that this will improve bat's stability on Windows machines.
738 \item The Windows installers now detect and refuse to install on
739 an OS that does not match the 32/64 bit value of the installer.
742 \subsection{FD Storage Address}
744 When the Director is behind a NAT, in a WAN area, to connect to
746 the StorageDaemon, the Director uses an ``external'' ip address,
747 and the FileDaemon should use an ``internal'' IP address to contact the
750 The normal way to handle this situation is to use a canonical name such as
751 ``storage-server'' that will be resolved on the Director side as the WAN
752 address and on the Client side as the LAN address. This is now possible to
753 configure this parameter using the new directive \texttt{FDStorageAddress} in
754 the Storage or Client resource.
757 %%\bsysimageH{BackupOverWan1}{Backup Over WAN}{figbs6:fdstorageaddress}
758 % \label{fig:fdstorageaddress}
764 FD Storage Address = 10.0.0.1
770 % # or in the Client resouce
777 FD Storage Address = 10.0.0.1
783 Note that using the Client \texttt{FDStorageAddress} directive will not allow
784 to use multiple Storage Daemon, all Backup or Restore requests will be sent to
785 the specified \texttt{FDStorageAddress}.
787 \subsection{Maximum Concurrent Read Jobs}
788 This is a new directive that can be used in the {\bf bacula-dir.conf} file
789 in the Storage resource. The main purpose is to limit the number
790 of concurrent Copy, Migration, and VirtualFull jobs so that
791 they don't monopolize all the Storage drives causing a deadlock situation
792 where all the drives are allocated for reading but none remain for
793 writing. This deadlock situation can occur when running multiple
794 simultaneous Copy, Migration, and VirtualFull jobs.
797 The default value is set to 0 (zero), which means there is no
798 limit on the number of read jobs. Note, limiting the read jobs
799 does not apply to Restore jobs, which are normally started by
800 hand. A reasonable value for this directive is one half the number
801 of drives that the Storage resource has rounded down. Doing so,
802 will leave the same number of drives for writing and will generally
803 avoid over committing drives and a deadlock.
805 \subsection{Incomplete Jobs}
806 During a backup, if the Storage daemon experiences disconnection
807 with the File daemon during backup (normally a comm line problem
808 or possibly an FD failure), under conditions that the SD determines
809 to be safe it will make the failed job as Incomplete rather than
810 failed. This is done only if there is sufficient valid backup
811 data that was written to the Volume. The advantage of an Incomplete
812 job is that it can be restarted by the new bconsole {\bf restart}
813 command from the point where it left off rather than from the
814 beginning of the jobs as is the case with a cancel.
816 \subsection{The Stop Command}
817 Bacula has been enhanced to provide a {\bf stop} command,
818 very similar to the {\bf cancel} command with the main difference
819 that the Job that is stopped is marked as Incomplete so that
820 it can be restarted later by the {\bf restart} command where
821 it left off (see below). The {\bf stop} command with no
822 arguments, will like the cancel command, prompt you with the
823 list of running jobs allowing you to select one, which might
824 look like the following:
829 1: JobId=3 Job=Incremental.2012-03-26_12.04.26_07
830 2: JobId=4 Job=Incremental.2012-03-26_12.04.30_08
831 3: JobId=5 Job=Incremental.2012-03-26_12.04.36_09
832 Choose Job to stop (1-3): 2
833 2001 Job "Incremental.2012-03-26_12.04.30_08" marked to be stopped.
834 3000 JobId=4 Job="Incremental.2012-03-26_12.04.30_08" marked to be stopped.
837 \subsection{The Restart Command}
838 The new {\bf Restart command} allows console users to restart
839 a canceled, failed, or incomplete Job. For canceled and failed
840 Jobs, the Job will restart from the beginning. For incomplete
841 Jobs the Job will restart at the point that it was stopped either
842 by a stop command or by some recoverable failure.
845 If you enter the {\bf restart} command in bconsole, you will get the
850 You have the following choices:
855 Select termination code: (1-4):
858 If you select the {\bf All} option, you may see something like:
861 Select termination code: (1-4): 4
862 +-------+-------------+---------------------+------+-------+----------+-----------+-----------+
863 | jobid | name | starttime | type | level | jobfiles |
864 jobbytes | jobstatus |
865 +-------+-------------+---------------------+------+-------+----------+-----------+-----------+
866 | 1 | Incremental | 2012-03-26 12:15:21 | B | F | 0 |
868 | 2 | Incremental | 2012-03-26 12:18:14 | B | F | 350 |
870 | 3 | Incremental | 2012-03-26 12:18:30 | B | F | 0 |
872 | 4 | Incremental | 2012-03-26 12:18:38 | B | F | 331 |
874 +-------+-------------+---------------------+------+-------+----------+-----------+-----------+
875 Enter the JobId list to select:
878 Then you may enter one or more JobIds to be restarted, which may
879 take the form of a list of JobIds separated by commas, and/or JobId
880 ranges such as {\bf 1-4}, which indicates you want to restart JobIds
881 1 through 4, inclusive.
883 \subsection{Job Bandwidth Limitation}
885 The new {\bf Job Bandwidth Limitation} directive may be added to the File
886 daemon's and/or Director's configuration to limit the bandwidth used by a
887 Job on a Client. It can be set in the File daemon's conf file for all Jobs
888 run in that File daemon, or it can be set for each Job in the Director's
889 conf file. The speed is always specified in bytes per second.
895 Working Directory = /some/path
896 Pid Directory = /some/path
898 Maximum Bandwidth Per Job = 5Mb/s
902 The above example would cause any jobs running with the FileDaemon to not
903 exceed 5 megabytes per second of throughput when sending data to the
904 Storage Daemon. Note, the speed is always specified in bytes per second
905 (not in bits per second), and the case (upper/lower) of the specification
906 characters is ignored (i.e. 1MB/s = 1Mb/s).
908 You may specify the following speed parameter modifiers:
909 k/s (1,000 bytes per second), kb/s (1,024 bytes per second),
910 m/s (1,000,000 bytes per second), or mb/s (1,048,576 bytes per second).
916 FileSet = FS_localhost
919 Maximum Bandwidth = 5Mb/s
924 The above example would cause Job \texttt{localhost-data} to not exceed 5MB/s
925 of throughput when sending data from the File daemon to the Storage daemon.
927 A new console command \texttt{setbandwidth} permits to set dynamically the
928 maximum throughput of a running Job or for future jobs of a Client.
931 * setbandwidth limit=1000 jobid=10
934 Please note that the value specified for the \texttt{limit} command
935 line parameter is always in units of 1024 bytes (i.e. the number
936 is multiplied by 1024 to give the number of bytes per second). As
937 a consequence, the above limit of 1000 will be interpreted as a
938 limit of 1000 * 1024 = 1,024,000 bytes per second.
940 \subsection{Always Backup a File}
942 When the Accurate mode is turned on, you can decide to always backup a file
943 by using then new {\bf A} Accurate option in your FileSet. For example:
966 This project was funded by Bacula Systems based on an idea of James Harper and
967 is available with the Bacula Enterprise Edition.
969 \subsection{Setting Accurate Mode at Runtime}
971 You are now able to specify the Accurate mode on the \texttt{run} command and
972 in the Schedule resource.
975 * run accurate=yes job=Test
981 Run = Full 1st sun at 23:05
982 Run = Differential accurate=yes 2nd-5th sun at 23:05
983 Run = Incremental accurate=no mon-sat at 23:05
987 It can allow you to save memory and and CPU resources on the catalog server in
991 These advanced tuning options are available with the Bacula Enterprise Edition.
993 % Common with community
994 \subsection{Additions to RunScript variables}
995 You can have access to JobBytes, JobFiles and Director name using \%b, \%F and \%D
996 in your runscript command. The Client address is now available through \%h.
999 RunAfterJob = "/bin/echo Job=%j JobBytes=%b JobFiles=%F ClientAddress=%h Dir=%D"
1002 \subsection{LZO Compression}
1004 LZO compression was added in the Unix File Daemon. From the user point of view,
1005 it works like the GZIP compression (just replace {\bf compression=GZIP} with
1006 {\bf compression=LZO}).
1011 Options { compression=LZO }
1017 LZO provides much faster compression and decompression speed but lower
1018 compression ratio than GZIP. It is a good option when you backup to disk. For
1019 tape, the built-in compression may be a better option.
1021 LZO is a good alternative for GZIP1 when you don't want to slow down your
1022 backup. On a modern CPU it should be able to run almost as fast as:
1025 \item your client can read data from disk. Unless you have very fast disks like
1026 SSD or large/fast RAID array.
1027 \item the data transfers between the file daemon and the storage daemon even on
1031 Note that bacula only use one compression level LZO1X-1.
1034 The code for this feature was contributed by Laurent Papier.
1036 \subsection{Purge Migration Job}
1038 The new {\bf Purge Migration Job} directive may be added to the Migration
1039 Job definition in the Director's configuration file. When it is enabled
1040 the Job that was migrated during a migration will be purged at
1041 the end of the migration job.
1046 Name = "migrate-job"
1049 Client = localhost-fd
1050 FileSet = "Full Set"
1052 Storage = DiskChanger
1054 Selection Type = Job
1055 Selection Pattern = ".*Save"
1057 Purge Migration Job = yes
1063 This project was submitted by Dunlap Blake; testing and documentation was funded
1066 \subsection{Changes in the Pruning Algorithm}
1068 We rewrote the job pruning algorithm in this version. Previously, in some users
1069 reported that the pruning process at the end of jobs was very long. It should
1070 not be longer the case. Now, Bacula won't prune automatically a Job if this
1071 particular Job is needed to restore data. Example:
1074 JobId: 1 Level: Full
1075 JobId: 2 Level: Incremental
1076 JobId: 3 Level: Incremental
1077 JobId: 4 Level: Differential
1078 .. Other incrementals up to now
1081 In this example, if the Job Retention defined in the Pool or in the Client
1082 resource causes that Jobs with Jobid in 1,2,3,4 can be pruned, Bacula will
1083 detect that JobId 1 and 4 are essential to restore data at the current state
1084 and will prune only JobId 2 and 3.
1086 \texttt{Important}, this change affect only the automatic pruning step after a
1087 Job and the \texttt{prune jobs} Bconsole command. If a volume expires after the
1088 \texttt{VolumeRetention} period, important jobs can be pruned.
1090 \subsection{Ability to Verify any specified Job}
1091 You now have the ability to tell Bacula which Job should verify instead of
1092 automatically verify just the last one.
1094 This feature can be used with VolumeToCatalog, DiskToCatalog and Catalog level.
1096 To verify a given job, just specify the Job jobid in argument when starting the
1099 *run job=VerifyVolume jobid=1 level=VolumeToCatalog
1101 JobName: VerifyVolume
1102 Level: VolumeToCatalog
1103 Client: 127.0.0.1-fd
1105 Pool: Default (From Job resource)
1106 Storage: File (From Job resource)
1107 Verify Job: VerifyVol.2010-09-08_14.17.17_03
1108 Verify List: /tmp/regress/working/VerifyVol.bsr
1109 When: 2010-09-08 14:17:31
1111 OK to run? (yes/mod/no):
1116 \chapter{New Features in 7.0.0}
1117 This chapter presents the new features that have been added to
1118 the various versions of Bacula.
1120 \section{New Features in 7.0.0}
1122 \subsection{Storage daemon to Storage daemon}
1123 Bacula version 7.0 permits SD to SD transfer of Copy and Migration
1124 Jobs. This permits what is commonly referred to as replication or
1125 off-site transfer of Bacula backups. It occurs automatically, if
1126 the source SD and destination SD of a Copy or Migration job are
1127 different. The following picture shows how this works.
1129 \includegraphics[width=0.8\linewidth]{sd-to-sd}
1131 \subsection{SD Calls Client}
1132 If the {\bf SD Calls Client} directive is set to true in a Client resource
1133 any Backup, Restore, Verify, Copy, or Migration Job where the client
1134 is involved, the client will wait for the Storage daemon to contact it.
1135 By default this directive is set to false, and the Client will call
1136 the Storage daemon. This directive can be useful if your Storage daemon
1137 is behind a firewall that permits outgoing connections but not incoming
1138 one. The following picture shows the communications connection paths in
1141 \includegraphics[width=0.8\linewidth]{sd-calls-client}
1143 \subsection{Next Pool}
1144 In previous versions of Bacula the Next Pool directive could be
1145 specified in the Pool resource for use with Migration and Copy Jobs.
1146 The Next Pool concept has been
1147 extended in Bacula version 7.0.0 to allow you to specify the
1148 Next Pool directive in the Job resource as well. If specified in
1149 the Job resource, it will override any value specified in the Pool
1152 In addition to being permitted in the Job resource, the
1153 {\bf nextpool=xxx} specification can be specified as a run
1154 override in the {\bf run} directive of a Schedule resource.
1155 Any {\bf nextpool} specification in a {\bf run}
1156 directive will override any other specification in either
1157 the Job or the Pool.
1159 In general, more information is displayed in the Job log
1160 on exactly which Next Pool specification is ultimately used.
1162 \subsection{status storage}
1163 The bconsole {\bf status storage} has been modified to attempt to eliminate
1164 duplicate storage resources and only show one that references any given
1165 storage daemon. This might be confusing at first, but tends to make a
1166 much more compact list of storage resource from which to select if there
1167 are multiple storage devices in the same storage daemon.
1169 If you want the old behavior (always display all storage resources) simply
1170 add the keyword {\bf select} to the command -- i.e. use
1171 {\bf status select storage}.
1177 \subsection{status schedule}
1178 A new status command option called {\bf scheduled} has been implemented
1179 in bconsole. By default it will display 20 lines of the next scheduled
1180 jobs. For example, with the default bacula-dir.conf configuration file,
1181 a bconsole command {\bf status scheduled} produces:
1185 Level Type Pri Scheduled Job Name Schedule
1186 ======================================================================
1187 Differential Backup 10 Sun 30-Mar 23:05 BackupClient1 WeeklyCycle
1188 Incremental Backup 10 Mon 24-Mar 23:05 BackupClient1 WeeklyCycle
1189 Incremental Backup 10 Tue 25-Mar 23:05 BackupClient1 WeeklyCycle
1191 Full Backup 11 Mon 24-Mar 23:10 BackupCatalog WeeklyCycleAfterBackup
1192 Full Backup 11 Wed 26-Mar 23:10 BackupCatalog WeeklyCycleAfterBackup
1197 Note, the output is listed by the Jobs found, and is not sorted
1201 This command has a number of options, most of which act as filters:
1203 \item {\bf days=nn} This specifies the number of days to list. The default is
1204 10 but can be set from 0 to 500.
1205 \item {\bf limit=nn} This specifies the limit to the number of lines to print.
1206 The default is 100 but can be any number in the range 0 to 2000.
1207 \item {\bf time="YYYY-MM-DD HH:MM:SS"} Sets the start time for listing the
1208 scheduled jobs. The default is to use the current time. Note, the
1209 time value must be specified inside double quotes and must be in
1210 the exact form shown above.
1211 \item {\bf schedule=schedule-name} This option restricts the output to
1213 \item {\bf job=job-name} This option restricts the output to the specified
1217 \subsection{Data Encryption Cipher Configuration}
1218 Bacula version 7.0 and later now allows to configure the data
1219 encryption cipher and the digest algorithm. The cipher was forced to AES
1220 128, and it is now possible to choose between the following ciphers:
1223 \item AES128 (default)
1229 The digest algorithm was set to SHA1 or SHA256 depending on the local
1231 options. We advise you to not modify the PkiDigest default setting. Please,
1232 refer to OpenSSL documentation to know about pro and cons on these options.
1241 \subsection{New Truncate Command}
1242 We have added a new truncate command to bconsole, which
1243 will truncate a Volume if the Volume is purged and if
1244 the Volume is also marked {\bf Action On Purge = Truncate}.
1245 This feature was originally added in Bacula version 5.0.1,
1246 but the mechanism for actually doing the truncate required
1247 the user to enter a command such as:
1250 purge volume action=truncate storage=File pool=Default
1253 The above command is now simplified to be:
1256 truncate storage=File pool=Default
1259 \subsection{Migration/Copy/VirtualFull Performance Enhancements}
1260 The Bacula Storage daemon now permits multiple jobs to simultaneously read
1261 the same disk Volume, which gives substantial performance enhancements when
1262 running Migration, Copy, or VirtualFull jobs that read disk Volumes. Our
1263 testing shows that when running multiple simultaneous jobs, the jobs can
1264 finish up to ten times faster with this version of Bacula. This is
1265 built-in to the Storage daemon, so it happens automatically and
1268 \subsection{VirtualFull Backup Consolidation Enhancements}
1269 By default Bacula selects jobs automatically for a VirtualFull,
1270 however, you may want to create the Virtual backup based on a
1271 particular backup (point in time) that exists.
1273 For example, if you have the following backup Jobs in your catalog:
1275 +-------+---------+-------+----------+----------+-----------+
1276 | JobId | Name | Level | JobFiles | JobBytes | JobStatus |
1277 +-------+---------+-------+----------+----------+-----------+
1278 | 1 | Vbackup | F | 1754 | 50118554 | T |
1279 | 2 | Vbackup | I | 1 | 4 | T |
1280 | 3 | Vbackup | I | 1 | 4 | T |
1281 | 4 | Vbackup | D | 2 | 8 | T |
1282 | 5 | Vbackup | I | 1 | 6 | T |
1283 | 6 | Vbackup | I | 10 | 60 | T |
1284 | 7 | Vbackup | I | 11 | 65 | T |
1285 | 8 | Save | F | 1758 | 50118564 | T |
1286 +-------+---------+-------+----------+----------+-----------+
1289 and you want to consolidate only the first 3 jobs and create a
1290 virtual backup equivalent to Job 1 + Job 2 + Job 3, you will use
1291 \texttt{jobid=3} in the \texttt{run} command, then Bacula will select the
1292 previous Full backup, the previous Differential (if any) and all subsequent
1296 run job=Vbackup jobid=3 level=VirtualFull
1299 If you want to consolidate a specific job list, you must specify the exact
1300 list of jobs to merge in the run command line. For example, to consolidate
1301 the last Differential and all subsequent Incremental, you will use
1302 \texttt{jobid=4,5,6,7} or \texttt{jobid=4-7} on the run command line. As one
1303 of the Job in the list is a Differential backup, Bacula will set the new job
1304 level to Differential. If the list is composed only with Incremental jobs,
1305 the new job will have a level set to Incremental.
1308 run job=Vbackup jobid=4-7 level=VirtualFull
1311 When using this feature, Bacula will automatically discard jobs that are
1312 not related to the current Job. For example, specifying
1313 \texttt{jobid=7,8}, Bacula will discard JobId 8 because it is not
1314 part of the same backup Job.
1316 We do not recommend it, but really want to consolidate jobs that have
1317 different names (so probably different clients, filesets, etc...), you must
1318 use \texttt{alljobid=} keyword instead of \texttt{jobid=}.
1321 run job=Vbackup alljobid=1-3,6-8 level=VirtualFull
1325 \subsection{FD Storage Address}
1327 When the Director is behind a NAT, in a WAN area, to connect to
1329 the StorageDaemon, the Director uses an ``external'' ip address,
1330 and the FileDaemon should use an ``internal'' IP address to contact the
1333 The normal way to handle this situation is to use a canonical name such as
1334 ``storage-server'' that will be resolved on the Director side as the WAN
1335 address and on the Client side as the LAN address. This is now possible to
1336 configure this parameter using the new directive \texttt{FDStorageAddress} in
1337 the Storage or Client resource.
1340 \includegraphics[width=0.8\linewidth]{BackupOverWan1}
1341 \label{fig:fdstorageaddress}
1347 FD Storage Address = 10.0.0.1
1353 % # or in the Client resouce
1360 FD Storage Address = 10.0.0.1
1366 Note that using the Client \texttt{FDStorageAddress} directive will not allow
1367 to use multiple Storage Daemon, all Backup or Restore requests will be sent to
1368 the specified \texttt{FDStorageAddress}.
1370 \subsection{Job Bandwidth Limitation}
1372 The new {\bf Job Bandwidth Limitation} directive may be added to the File
1373 daemon's and/or Director's configuration to limit the bandwidth used by a
1374 Job on a Client. It can be set in the File daemon's conf file for all Jobs
1375 run in that File daemon, or it can be set for each Job in the Director's
1376 conf file. The speed is always specified in bytes per second.
1382 Working Directory = /some/path
1383 Pid Directory = /some/path
1385 Maximum Bandwidth Per Job = 5Mb/s
1389 The above example would cause any jobs running with the FileDaemon to not
1390 exceed 5 megabytes per second of throughput when sending data to the
1391 Storage Daemon. Note, the speed is always specified in bytes per second
1392 (not in bits per second), and the case (upper/lower) of the specification
1393 characters is ignored (i.e. 1MB/s = 1Mb/s).
1395 You may specify the following speed parameter modifiers:
1396 k/s (1,000 bytes per second), kb/s (1,024 bytes per second),
1397 m/s (1,000,000 bytes per second), or mb/s (1,048,576 bytes per second).
1402 Name = locahost-data
1403 FileSet = FS_localhost
1406 Maximum Bandwidth = 5Mb/s
1411 The above example would cause Job \texttt{localhost-data} to not exceed 5MB/s
1412 of throughput when sending data from the File daemon to the Storage daemon.
1414 A new console command \texttt{setbandwidth} permits to set dynamically the
1415 maximum throughput of a running Job or for future jobs of a Client.
1418 * setbandwidth limit=1000 jobid=10
1421 Please note that the value specified for the \texttt{limit} command
1422 line parameter is always in units of 1024 bytes (i.e. the number
1423 is multiplied by 1024 to give the number of bytes per second). As
1424 a consequence, the above limit of 1000 will be interpreted as a
1425 limit of 1000 * 1024 = 1,024,000 bytes per second.
1428 This project was funded by Bacula Systems.
1431 \subsection{Maximum Concurrent Read Jobs}
1432 This is a new directive that can be used in the {\bf bacula-dir.conf} file
1433 in the Storage resource. The main purpose is to limit the number
1434 of concurrent Copy, Migration, and VirtualFull jobs so that
1435 they don't monopolize all the Storage drives causing a deadlock situation
1436 where all the drives are allocated for reading but none remain for
1437 writing. This deadlock situation can occur when running multiple
1438 simultaneous Copy, Migration, and VirtualFull jobs.
1441 The default value is set to 0 (zero), which means there is no
1442 limit on the number of read jobs. Note, limiting the read jobs
1443 does not apply to Restore jobs, which are normally started by
1444 hand. A reasonable value for this directive is one half the number
1445 of drives that the Storage resource has rounded down. Doing so,
1446 will leave the same number of drives for writing and will generally
1447 avoid over committing drives and a deadlock.
1450 \subsection{Director job Codes in Message Resource Commands}
1451 Before submitting the specified mail command to the operating system, Bacula
1452 performs character substitution like in Runscript commands. Bacula will now
1453 perform also specific Director character substitution.
1456 The code for this feature was contributed by Bastian Friedrich.
1458 \subsection{Additions to RunScript variables}
1459 The following variables are now available in runscripts:
1461 \item current PID using \%P
1462 \item if the job is a clone job using \%C
1466 RunAfterJob = "/bin/echo Pid=%P isCloned=%C"
1470 \subsection{Read Only Storage Devices}
1471 This version of Bacula permits defining a Storage daemon device
1472 to be read-only. That is if the {\bf ReadOnly} directive is specified and
1473 enabled, the drive can only be used for read operations.
1474 The the {\bf ReadOnly} directive can be defined in any bacula-sd.conf
1475 Device resource, and is most useful to reserve one or more
1476 drives for restores. An example is:
1482 \subsection{New Prune ``Expired'' Volume Command}
1483 It is now possible to prune all volumes
1484 (from a pool, or globally) that are ``expired''. This option can be
1485 scheduled after or before the backup of the Catalog and can be
1486 combined with the Truncate On Purge option. The Expired Prune option can
1487 be used instead of the \texttt{manual\_prune.pl} script.
1490 * prune expired volumes
1492 * prune expired volumes pool=FullPool
1495 To schedule this option automatically, it can be added to the BackupCatalog job
1500 Name = CatalogBackup
1503 Console = "prune expired volume yes"
1509 \subsection{Hardlink Performance Enhancements}
1510 If you use a program such as Cyrus IMAP that creates very large numbers
1511 of hardlinks, the time to build the interactive restore tree can be
1512 excessively long. This version of Bacula has a new feature that
1513 automatically keeps the hardlinks associated with the restore tree
1514 in memory, which consumes a bit more memory but vastly speeds up
1515 building the tree. If the memory usage is too big for your system, you
1516 can reduce the amount of memory used during the restore command by
1517 adding the option {\bf optimizespeed=false} on the bconsole run
1520 This feature was developed by Josip Almasi, and enhanced to be runtime
1521 dynamic by Kern Sibbald.
1523 \subsection{DisableCommand Directive}
1524 There is a new Directive named {\bf Disable Command} that
1525 can be put in the File daemon Client or Director resource.
1526 If it is in the Client, it applies globally, otherwise the
1527 directive applies only to the Director in which it is found.
1528 The Disable Command adds security to your File daemon by
1529 disabling certain commands. The commands that can be
1555 On or more of these command keywords can be placed in quotes and separated
1556 by spaces on the Disable Command directive line. Note: the commands must
1557 be written exactly as they appear above.
1559 \subsection{Multiple Console Directors}
1560 Support for multiple bconsole and bat Directors in the bconsole.conf and
1561 bat.conf files has been implemented and/or improved.
1563 \subsection{Restricted Consoles}
1564 Better support for Restricted consoles has been implement for bconsole and
1567 \subsection{Configuration Files}
1568 In previous versions of Bacula the configuration files for each component
1569 were limited to a maximum of 499 bytes per configuration file line. This
1570 version of Bacula permits unlimited input line lengths. This can be
1571 especially useful for specifying more complicated Migration/Copy SQL
1572 statements and in creating long restricted console ACL lists.
1574 \subsection{Maximum Spawned Jobs}
1575 The Job resource now permits specifying a number of {\bf Maximum Spawn
1576 Jobs}. The default is 300. This directive can be useful if you have
1577 big hardware and you do a lot of Migration/Copy jobs which start
1578 at the same time. In prior versions of Bacula, Migration/Copy
1579 was limited to spawning a maximum of 100 jobs at a time.
1581 \subsection{Progress Meter}
1582 The new File daemon has been enhanced to send its progress (files
1583 processed and bytes written) to the Director every 30 seconds. These
1584 figures can then be displayed with a bconsole {\bf status dir}
1587 \subsection{Scheduling a 6th Week}
1588 Prior version of Bacula permits specifying 1st through 5th week of
1589 a month (first through fifth) as a keyword on the {\bf run}
1590 directive of a Schedule resource. This version of Bacula also permits
1591 specifying the 6th week of a month with the keyword {\bf sixth} or
1594 \subsection{Scheduling the Last Day of a Month}
1595 This version of Bacula now permits specifying the {\bf lastday}
1596 keyword in the {\bf run} directive of a Schedule resource.
1597 If {\bf lastday} is specified, it will apply only to those months
1598 specified on the {\bf run} directive. Note: by default all months
1601 \subsection{Improvements to Cancel and Restart bconsole Commands}
1602 The Restart bconsole command now allow selection of either
1603 canceled or failed jobs to be restarted. In addition both the
1604 {\bf cancel} and {\bf restart} bconsole commands permit entering
1605 a number of JobIds separated by commas or a range of JobIds indicated
1606 by a dash between the begin and end range (e.g. 3-10). Finally the
1607 two commands also allow one to enter the special keyword {\bf all}
1608 to select all the appropriate Jobs.
1610 \subsection{bconsole Performance Improvements}
1611 In previous versions of Bacula certain bconsole commands could wait a long
1612 time due to catalog lock contention. This was especially noticeable
1613 when a large number of jobs were running and putting their attributes
1614 into the catalog. This version uses a separate catalog connection that
1615 should significantly enhance performance.
1617 \subsection{New .bvfs\_decode\_lstat Command}
1618 There is a new bconsole command, which is
1619 {\bf .bvfs\_decode\_lstat} it requires one argument, which
1620 is {\bf lstat="lstat value to decode"}. An example command
1621 in bconsole and the output might be:
1625 .bvfs_decode_lstat lstat="A A EHt B A A A JP BAA B BTL/A7 BTL/A7 BTL/A7 A A C"
1643 \subsection*{New Debug Options}
1645 In Bacula Enterprise version 8.0 and later, we introduced new options to
1646 the \texttt{setdebug} command.
1650 If the \texttt{options} parameter is set, the following arguments can be
1651 used to control debug functions.
1654 \item [0] clear debug flags
1655 \item [i] Turn off, ignore bwrite() errors on restore on File Daemon
1656 \item [d] Turn off decomp of BackupRead() streams on File Daemon
1657 \item [t] Turn on timestamp in traces
1658 \item [T] Turn off timestamp in traces
1659 \item [c] Truncate trace file if trace file is activated
1660 \item [l] Turn on recoding events on P() and V()
1661 \item [p] Turn on the display of the event ring when doing a bactrace
1666 The following command will truncate the trace file and will turn on timestamps
1670 * setdebug level=10 trace=1 options=ct fd
1675 It is now possible to use \textsl{class} of debug messages called \texttt{tags}
1676 to control the debug output of Bacula daemons.
1679 \item [all] Display all debug messages
1680 \item [bvfs] Display BVFS debug messages
1681 \item [sql] Display SQL related debug messages
1682 \item [memory] Display memory and poolmem allocation messages
1683 \item [scheduler] Display scheduler related debug messages
1687 * setdebug level=10 tags=bvfs,sql,memory
1688 * setdebug level=10 tags=!bvfs
1690 # bacula-dir -t -d 200,bvfs,sql
1693 The \texttt{tags} option is composed of a list of tags, tags are separated by
1694 ``,'' or ``+'' or ``-'' or ``!''. To disable a specific tag, use ``-'' or ``!''
1695 in front of the tag. Note that more tags will come in future versions.
1697 %\LTXtable{\linewidth}{table_debugtags}
1700 \chapter{New Features in 5.2.13}
1701 This chapter presents the new features that have been added to the current
1702 Community version of Bacula that is now released.
1704 \subsection{Additions to RunScript variables}
1705 You can have access to Director name using \%D in your runscript
1709 RunAfterJob = "/bin/echo Director=%D
1712 \section{New Features in 5.2.1}
1713 This chapter presents the new features were added in the
1714 Community release version 5.2.1.
1716 There are additional features (plugins) available in the Enterprise version
1717 that are described in another chapter. A subscription to Bacula Systems
1718 is required for the Enterprise version.
1720 \subsection{LZO Compression}
1722 LZO compression has been to the File daemon. From the user's point of view,
1723 it works like the GZIP compression (just replace {\bf compression=GZIP} with
1724 {\bf compression=LZO}).
1729 Options {compression=LZO }
1735 LZO provides a much faster compression and decompression speed but lower
1736 compression ratio than GZIP. It is a good option when you backup to disk. For
1737 tape, the hardware compression is almost always a better option.
1739 LZO is a good alternative for GZIP1 when you don't want to slow down your
1740 backup. With a modern CPU it should be able to run almost as fast as:
1743 \item your client can read data from disk. Unless you have very fast disks like
1744 SSD or large/fast RAID array.
1745 \item the data transfers between the file daemon and the storage daemon even on
1749 Note, Bacula uses compression level LZO1X-1.
1752 The code for this feature was contributed by Laurent Papier.
1754 \subsection{New Tray Monitor}
1756 Since the old integrated Windows tray monitor doesn't work with
1757 recent Windows versions, we have written a new Qt Tray Monitor that is available
1758 for both Linux and Windows. In addition to all the previous features,
1759 this new version allows you to run Backups from
1760 the tray monitor menu.
1762 \begin{figure}[htbp]
1764 \includegraphics[width=0.8\linewidth]{tray-monitor}
1765 \label{fig:traymonitor}
1766 \caption{New tray monitor}
1769 \begin{figure}[htbp]
1771 \includegraphics[width=0.8\linewidth]{tray-monitor1}
1772 \label{fig:traymonitor1}
1773 \caption{Run a Job through the new tray monitor}
1777 To be able to run a job from the tray monitor, you need to
1778 allow specific commands in the Director monitor console:
1783 CommandACL = status, .clients, .jobs, .pools, .storage, .filesets, .messages, run
1784 ClientACL = *all* # you can restrict to a specific host
1796 This project was funded by Bacula Systems and is available with Bacula
1797 the Enterprise Edition and the Community Edition.
1799 \subsection{Purge Migration Job}
1801 The new {\bf Purge Migration Job} directive may be added to the Migration
1802 Job definition in the Director's configuration file. When it is enabled
1803 the Job that was migrated during a migration will be purged at
1804 the end of the migration job.
1809 Name = "migrate-job"
1812 Client = localhost-fd
1813 FileSet = "Full Set"
1815 Storage = DiskChanger
1817 Selection Type = Job
1818 Selection Pattern = ".*Save"
1820 Purge Migration Job = yes
1826 This project was submitted by Dunlap Blake; testing and documentation was funded
1829 \subsection{Changes in Bvfs (Bacula Virtual FileSystem)}
1831 Bat has now a bRestore panel that uses Bvfs to display files and
1834 \begin{figure}[htbp]
1836 \includegraphics[width=0.8\linewidth]{bat-brestore}
1837 \label{fig:batbrestore}
1838 \caption{Bat Brestore Panel}
1841 the Bvfs module works correctly with BaseJobs, Copy and Migration jobs.
1844 This project was funded by Bacula Systems.
1846 \subsubsection*{General notes}
1849 \item All fields are separated by a tab
1850 \item You can specify \texttt{limit=} and \texttt{offset=} to list smoothly
1851 records in very big directories
1852 \item All operations (except cache creation) are designed to run instantly
1853 \item At this time, Bvfs works faster on PostgreSQL than MySQL catalog. If you
1854 can contribute new faster SQL queries we will be happy, else don't complain
1856 \item The cache creation is dependent of the number of directories. As Bvfs
1857 shares information across jobs, the first creation can be slow
1858 \item All fields are separated by a tab
1859 \item Due to potential encoding problem, it's advised to always use pathid in
1863 \subsubsection*{Get dependent jobs from a given JobId}
1865 Bvfs allows you to query the catalog against any combination of jobs. You
1866 can combine all Jobs and all FileSet for a Client in a single session.
1868 To get all JobId needed to restore a particular job, you can use the
1869 \texttt{.bvfs\_get\_jobids} command.
1872 .bvfs_get_jobids jobid=num [all]
1876 .bvfs_get_jobids jobid=10
1878 .bvfs_get_jobids jobid=10 all
1882 In this example, a normal restore will need to use JobIds 1,2,5,10 to
1883 compute a complete restore of the system.
1885 With the \texttt{all} option, the Director will use all defined FileSet for
1888 \subsubsection*{Generating Bvfs cache}
1890 The \texttt{.bvfs\_update} command computes the directory cache for jobs
1891 specified in argument, or for all jobs if unspecified.
1894 .bvfs_update [jobid=numlist]
1899 .bvfs_update jobid=1,2,3
1902 You can run the cache update process in a RunScript after the catalog backup.
1904 \subsubsection*{Get all versions of a specific file}
1906 Bvfs allows you to find all versions of a specific file for a given Client with
1907 the \texttt{.bvfs\_version} command. To avoid problems with encoding, this
1908 function uses only PathId and FilenameId. The jobid argument is mandatory but
1912 .bvfs_versions client=filedaemon pathid=num filenameid=num jobid=1
1913 PathId FilenameId FileId JobId LStat Md5 VolName Inchanger
1914 PathId FilenameId FileId JobId LStat Md5 VolName Inchanger
1921 .bvfs_versions client=localhost-fd pathid=1 fnid=47 jobid=1
1922 1 47 52 12 gD HRid IGk D Po Po A P BAA I A /uPgWaxMgKZlnMti7LChyA Vol1 1
1925 \subsubsection*{List directories}
1927 Bvfs allows you to list directories in a specific path.
1929 .bvfs_lsdirs pathid=num path=/apath jobid=numlist limit=num offset=num
1930 PathId FilenameId FileId JobId LStat Path
1931 PathId FilenameId FileId JobId LStat Path
1932 PathId FilenameId FileId JobId LStat Path
1936 You need to \texttt{pathid} or \texttt{path}. Using \texttt{path=""} will list
1937 ``/'' on Unix and all drives on Windows. If FilenameId is 0, the record
1938 listed is a directory.
1941 .bvfs_lsdirs pathid=4 jobid=1,11,12
1942 4 0 0 0 A A A A A A A A A A A A A A .
1943 5 0 0 0 A A A A A A A A A A A A A A ..
1944 3 0 0 0 A A A A A A A A A A A A A A regress/
1947 In this example, to list directories present in \texttt{regress/}, you can use
1949 .bvfs_lsdirs pathid=3 jobid=1,11,12
1950 3 0 0 0 A A A A A A A A A A A A A A .
1951 4 0 0 0 A A A A A A A A A A A A A A ..
1952 2 0 0 0 A A A A A A A A A A A A A A tmp/
1955 \subsubsection*{List files}
1957 Bvfs allows you to list files in a specific path.
1959 .bvfs_lsfiles pathid=num path=/apath jobid=numlist limit=num offset=num
1960 PathId FilenameId FileId JobId LStat Path
1961 PathId FilenameId FileId JobId LStat Path
1962 PathId FilenameId FileId JobId LStat Path
1966 You need to \texttt{pathid} or \texttt{path}. Using \texttt{path=""} will list
1967 ``/'' on Unix and all drives on Windows. If FilenameId is 0, the record listed
1971 .bvfs_lsfiles pathid=4 jobid=1,11,12
1972 4 0 0 0 A A A A A A A A A A A A A A .
1973 5 0 0 0 A A A A A A A A A A A A A A ..
1974 1 0 0 0 A A A A A A A A A A A A A A regress/
1977 In this example, to list files present in \texttt{regress/}, you can use
1979 .bvfs_lsfiles pathid=1 jobid=1,11,12
1980 1 47 52 12 gD HRid IGk BAA I BMqcPH BMqcPE BMqe+t A titi
1981 1 49 53 12 gD HRid IGk BAA I BMqe/K BMqcPE BMqe+t B toto
1982 1 48 54 12 gD HRie IGk BAA I BMqcPH BMqcPE BMqe+3 A tutu
1983 1 45 55 12 gD HRid IGk BAA I BMqe/K BMqcPE BMqe+t B ficheriro1.txt
1984 1 46 56 12 gD HRie IGk BAA I BMqe/K BMqcPE BMqe+3 D ficheriro2.txt
1987 \subsubsection*{Restore set of files}
1989 Bvfs allows you to create a SQL table that contains files that you want to
1990 restore. This table can be provided to a restore command with the file option.
1993 .bvfs_restore fileid=numlist dirid=numlist hardlink=numlist path=b2num
1995 restore file=?b2num ...
1998 To include a directory (with \texttt{dirid}), Bvfs needs to run a query to
1999 select all files. This query could be time consuming.
2001 \texttt{hardlink} list is always composed of a series of two numbers (jobid,
2002 fileindex). This information can be found in the LinkFI field of the LStat
2005 The \texttt{path} argument represents the name of the table that Bvfs will
2006 store results. The format of this table is \texttt{b2[0-9]+}. (Should start by
2007 b2 and followed by digits).
2012 .bvfs_restore fileid=1,2,3,4 hardlink=10,15,10,20 jobid=10 path=b20001
2016 \subsubsection*{Cleanup after Restore}
2018 To drop the table used by the restore command, you can use the
2019 \texttt{.bvfs\_cleanup} command.
2022 .bvfs_cleanup path=b20001
2025 \subsubsection*{Clearing the BVFS Cache}
2027 To clear the BVFS cache, you can use the \texttt{.bvfs\_clear\_cache} command.
2030 .bvfs_clear_cache yes
2034 \subsection{Changes in the Pruning Algorithm}
2036 We rewrote the job pruning algorithm in this version. Previously, in some users
2037 reported that the pruning process at the end of jobs was very long. It should
2038 not be longer the case. Now, Bacula won't prune automatically a Job if this
2039 particular Job is needed to restore data. Example:
2042 JobId: 1 Level: Full
2043 JobId: 2 Level: Incremental
2044 JobId: 3 Level: Incremental
2045 JobId: 4 Level: Differential
2046 .. Other incrementals up to now
2049 In this example, if the Job Retention defined in the Pool or in the Client
2050 resource causes that Jobs with Jobid in 1,2,3,4 can be pruned, Bacula will
2051 detect that JobId 1 and 4 are essential to restore data at the current state
2052 and will prune only JobId 2 and 3.
2054 \texttt{Important}, this change affect only the automatic pruning step after a
2055 Job and the \texttt{prune jobs} Bconsole command. If a volume expires after the
2056 \texttt{VolumeRetention} period, important jobs can be pruned.
2058 \subsection{Ability to Verify any specified Job}
2059 You now have the ability to tell Bacula which Job should verify instead of
2060 automatically verify just the last one.
2062 This feature can be used with VolumeToCatalog, DiskToCatalog and Catalog level.
2064 To verify a given job, just specify the Job jobid in argument when starting the
2067 *run job=VerifyVolume jobid=1 level=VolumeToCatalog
2069 JobName: VerifyVolume
2070 Level: VolumeToCatalog
2071 Client: 127.0.0.1-fd
2073 Pool: Default (From Job resource)
2074 Storage: File (From Job resource)
2075 Verify Job: VerifyVol.2010-09-08_14.17.17_03
2076 Verify List: /tmp/regress/working/VerifyVol.bsr
2077 When: 2010-09-08 14:17:31
2079 OK to run? (yes/mod/no):
2083 This project was funded by Bacula Systems and is available with Bacula
2084 Enterprise Edition and Community Edition.
2086 \subsection{Additions to RunScript variables}
2087 You can have access to JobBytes and JobFiles using \%b and \%F in your runscript
2088 command. The Client address is now available through \%h.
2091 RunAfterJob = "/bin/echo Job=%j JobBytes=%b JobFiles=%F ClientAddress=%h"
2094 %\subsection{Changes in drivetype.exe}
2096 %Now the \texttt{drivetype.exe} program allows you to list all local hard
2097 %drives. It can help to build dynamic FileSet on Windows.
2100 %File = "\\|\"c:/program files/bacula/bin32/drivetype\" -l -a"
2104 \subsection{Additions to the Plugin API}
2105 The bfuncs structure has been extended to include a number of
2108 \subsubsection{bfuncs}
2109 The bFuncs structure defines the callback entry points within Bacula
2110 that the plugin can use register events, get Bacula values, set
2111 Bacula values, and send messages to the Job output or debug output.
2113 The exact definition as of this writing is:
2115 typedef struct s_baculaFuncs {
2118 bRC (*registerBaculaEvents)(bpContext *ctx, ...);
2119 bRC (*getBaculaValue)(bpContext *ctx, bVariable var, void *value);
2120 bRC (*setBaculaValue)(bpContext *ctx, bVariable var, void *value);
2121 bRC (*JobMessage)(bpContext *ctx, const char *file, int line,
2122 int type, utime_t mtime, const char *fmt, ...);
2123 bRC (*DebugMessage)(bpContext *ctx, const char *file, int line,
2124 int level, const char *fmt, ...);
2125 void *(*baculaMalloc)(bpContext *ctx, const char *file, int line,
2127 void (*baculaFree)(bpContext *ctx, const char *file, int line, void *mem);
2129 /* New functions follow */
2130 bRC (*AddExclude)(bpContext *ctx, const char *file);
2131 bRC (*AddInclude)(bpContext *ctx, const char *file);
2132 bRC (*AddIncludeOptions)(bpContext *ctx, const char *opts);
2133 bRC (*AddRegex)(bpContext *ctx, const char *item, int type);
2134 bRC (*AddWild)(bpContext *ctx, const char *item, int type);
2135 bRC (*checkChanges)(bpContext *ctx, struct save_pkt *sp);
2141 \item [AddExclude] can be called to exclude a file. The file
2142 string passed may include wildcards that will be interpreted by
2143 the {\bf fnmatch} subroutine. This function can be called
2144 multiple times, and each time the file specified will be added
2145 to the list of files to be excluded. Note, this function only
2146 permits adding excludes of specific file or directory names,
2147 or files matched by the rather simple fnmatch mechanism.
2148 See below for information on doing wild-card and regex excludes.
2150 \item [NewPreInclude] can be called to create a new Include block. This
2151 block will be added after the current defined Include block. This
2152 function can be called multiple times, but each time, it will create
2153 a new Include section (not normally needed). This function should
2154 be called only if you want to add an entirely new Include block.
2156 \item [NewInclude] can be called to create a new Include block. This
2157 block will be added before any user defined Include blocks. This
2158 function can be called multiple times, but each time, it will create
2159 a new Include section (not normally needed). This function should
2160 be called only if you want to add an entirely new Include block.
2162 \item [AddInclude] can be called to add new files/directories to
2163 be included. They are added to the current Include block. If
2164 NewInclude has not been included, the current Include block is
2165 the last one that the user created. This function
2166 should be used only if you want to add totally new files/directories
2167 to be included in the backup.
2169 \item [NewOptions] adds a new Options block to the current Include
2170 in front of any other Options blocks. This permits the plugin to
2171 add exclude directives (wild-cards and regexes) in front of the
2172 user Options, and thus prevent certain files from being backed up.
2173 This can be useful if the plugin backs up files, and they should
2174 not be also backed up by the main Bacula code. This function
2175 may be called multiple times, and each time, it creates a new
2176 prepended Options block. Note: normally you want to call this
2177 entry point prior to calling AddOptions, AddRegex, or AddWild.
2179 \item [AddOptions] allows the plugin it set options in
2180 the current Options block, which is normally created with the
2181 NewOptions call just prior to adding Include Options.
2182 The permitted options are passed as a character string, where
2183 each character has a specific meaning as defined below:
2186 \item [a] always replace files (default).
2187 \item [e] exclude rather than include.
2188 \item [h] no recursion into subdirectories.
2189 \item [H] do not handle hard links.
2190 \item [i] ignore case in wildcard and regex matches.
2191 \item [M] compute an MD5 sum.
2192 \item [p] use a portable data format on Windows (not recommended).
2193 \item [R] backup resource forks and Findr Info.
2194 \item [r] read from a fifo
2195 \item [S1] compute an SHA1 sum.
2196 \item [S2] compute an SHA256 sum.
2197 \item [S3] comput an SHA512 sum.
2198 \item [s] handle sparse files.
2199 \item [m] use st\_mtime only for file differences.
2200 \item [k] restore the st\_atime after accessing a file.
2201 \item [A] enable ACL backup.
2202 \item [Vxxx:] specify verify options. Must terminate with :
2203 \item [Cxxx:] specify accurate options. Must terminate with :
2204 \item [Jxxx:] specify base job Options. Must terminate with :
2205 \item [Pnnn:] specify integer nnn paths to strip. Must terminate with :
2207 \item [Zn] specify gzip compression level n.
2208 \item [K] do not use st\_atime in backup decision.
2209 \item [c] check if file changed during backup.
2210 \item [N] honor no dump flag.
2211 \item [X] enable backup of extended attributes.
2214 \item [AddRegex] adds a regex expression to the current Options block.
2215 The following options are permitted:
2217 \item [ ] (a blank) regex applies to whole path and filename.
2218 \item [F] regex applies only to the filename (directory or path stripped).
2219 \item [D] regex applies only to the directory (path) part of the name.
2222 \item [AddWild] adds a wildcard expression to the current Options block.
2223 The following options are permitted:
2225 \item [ ] (a blank) regex applies to whole path and filename.
2226 \item [F] regex applies only to the filename (directory or path stripped).
2227 \item [D] regex applies only to the directory (path) part of the name.
2230 \item [checkChanges] call the \texttt{check\_changes()} function in Bacula code
2231 that can use Accurate code to compare the file information in argument with
2232 the previous file information. The \texttt{delta\_seq} attribute of the
2233 \texttt{save\_pkt} will be updated, and the call will return
2234 \texttt{bRC\_Seen} if the core code wouldn't decide to backup it.
2239 \subsubsection{Bacula events}
2240 The list of events has been extended to include:
2246 bEventStartBackupJob = 3,
2247 bEventEndBackupJob = 4,
2248 bEventStartRestoreJob = 5,
2249 bEventEndRestoreJob = 6,
2250 bEventStartVerifyJob = 7,
2251 bEventEndVerifyJob = 8,
2252 bEventBackupCommand = 9,
2253 bEventRestoreCommand = 10,
2258 bEventCancelCommand = 13,
2259 bEventVssBackupAddComponents = 14,
2260 bEventVssRestoreLoadComponentMetadata = 15,
2261 bEventVssRestoreSetComponentsSelected = 16,
2262 bEventRestoreObject = 17,
2263 bEventEndFileSet = 18,
2264 bEventPluginCommand = 19,
2265 bEventVssBeforeCloseRestore = 20,
2266 bEventVssPrepareSnapshot = 21
2272 \item [bEventCancelCommand] is called whenever the currently
2273 running Job is canceled */
2275 \item [bEventVssBackupAddComponents]
2277 \item [bEventVssPrepareSnapshot] is called before creating VSS snapshots, it
2278 provides a char[27] table where the plugin can add Windows drives that will
2279 be used during the Job. You need to add them without duplicates, and you can
2280 use in \texttt{fd\_common.h} \texttt{add\_drive()} and \texttt{copy\_drives()}
2284 \subsection{ACL enhancements}
2286 The following enhancements are made to the Bacula Filed with regards to
2287 Access Control Lists (ACLs)
2290 \item Added support for AIX 5.3 and later new aclx\_get interface which supports
2291 POSIX and NFSv4 ACLs.
2292 \item Added support for new acl types on FreeBSD 8.1 and later which supports
2293 POSIX and NFSv4 ACLs.
2294 \item Some generic cleanups for internal ACL handling.
2295 \item Fix for acl storage on OSX
2296 \item Cleanup of configure checks for ACL detection, now configure only
2297 tests for a certain interface type based on the operating system
2298 this should give less false positives on detection. Also when ACLs
2299 are detected no other acl checks are performed anymore.
2303 This project was funded by Planets Communications B.V. and ELM Consultancy B.V.
2304 and is available with Bacula Enterprise Edition and Community Edition.
2306 \subsection{XATTR enhancements}
2308 The following enhancements are made to the Bacula Filed with regards to
2309 Extended Attributes (XATTRs)
2312 \item Added support for IRIX extended attributes using the attr\_get interface.
2313 \item Added support for Tru64 (OSF1) extended attributes using the
2314 getproplist interface.
2315 \item Added support for AIX extended attributes available in AIX 6.x
2316 and higher using the listea/getea/setea interface.
2317 \item Added some debugging to generic xattr code so it easier to
2319 \item Cleanup of configure checks for XATTR detection, now configure only
2320 tests for a certain interface type based on the operating system
2321 this should give less false positives on detection. Also when xattrs
2322 are detected no other xattr checks are performed anymore.
2326 This project was funded by Planets Communications B.V. and ELM Consultancy B.V.
2327 and is available with Bacula Enterprise Edition and Community Edition.
2329 \subsection{Class Based Database Backend Drivers}
2331 The main Bacula Director code is independent of the SQL backend
2332 in version 5.2.0 and greater. This means that the Bacula Director can be
2333 packaged by itself, then each of the different SQL backends supported can
2334 be packaged separately. It is possible to build all the DB backends at the
2335 same time by including multiple database options at the same time.
2337 ./configure can be run with multiple database configure options.
2344 Order of testing for databases is:
2351 Each configured backend generates a file named:
2352 \verb+libbaccats-<sql_backend_name>-<version>.so+
2353 A dummy catalog library is created named libbaccats-version.so
2355 At configure time the first detected backend is used as the so called
2356 default backend and at install time the dummy
2357 \verb+libbaccats-<version>.so+ is replaced with the default backend type.
2359 If you configure all three backends you get three backend libraries and the
2360 postgresql gets installed as the default.
2362 When you want to switch to another database, first save any old catalog you
2363 may have then you can copy one of the three backend libraries over the
2364 \verb+libbaccats-<version>.so+ e.g.
2366 An actual command, depending on your Bacula version might be:
2368 cp libbaccats-postgresql-5.2.2.so libbaccats-5.2.2.so
2371 where the \verb+5.2.2+ must be replaced by the Bacula release
2374 Then you must update the default backend in the following files:
2377 create_bacula_database
2378 drop_bacula_database
2380 grant_bacula_privileges
2383 update_bacula_tables
2386 And re-run all the above scripts. Please note, this means
2387 you will have a new empty database and if you had a previous
2388 one it will be lost.
2390 All current database backend drivers for catalog information are rewritten
2391 to use a set of multi inherited C++ classes which abstract the specific
2392 database specific internals and make sure we have a more stable generic
2393 interface with the rest of SQL code. From now on there is a strict
2394 boundary between the SQL code and the low-level database functions. This
2395 new interface should also make it easier to add a new backend for a
2396 currently unsupported database. As part of the rewrite the SQLite 2 code
2397 was removed (e.g. only SQLite 3 is now supported). An extra bonus of the
2398 new code is that you can configure multiple backends in the configure and
2399 build all backends in one compile session and select the correct database
2400 backend at install time. This should make it a lot easier for packages
2406 We also added cursor support for PostgreSQL backend, this improves memory
2407 usage for large installation.
2410 This project was implemented by Planets Communications B.V. and ELM
2411 Consultancy B.V. and Bacula Systems and is available with both the Bacula
2412 Enterprise Edition and the Community Edition.
2414 \subsection{Hash List Enhancements}
2416 The htable hash table class has been extended with extra hash functions for
2417 handling next to char pointer hashes also 32 bits and 64 bits hash keys.
2418 Also the hash table initialization routines have been enhanced with
2419 support for passing a hint as to the number of initial pages to use
2420 for the size of the hash table. Until now the hash table always used
2421 a fixed value of 10 Mb. The private hash functions of the mountpoint entry
2422 cache have been rewritten to use the new htable class with a small memory
2426 This project was funded by Planets Communications B.V. and ELM Consultancy B.V.
2427 and Bacula Systems and is available with Bacula Enterprise Edition and
2432 %%% =====================================================================
2437 \section{Release Version 5.0.3}
2439 There are no new features in version 5.0.2. This version simply fixes a
2440 number of bugs found in version 5.0.1 during the ongoing development
2443 \section{Release Version 5.0.2}
2445 There are no new features in version 5.0.2. This version simply fixes a
2446 number of bugs found in version 5.0.1 during the ongoing development
2452 \section{New Features in 5.0.1}
2454 This chapter presents the new features that are in the released Bacula version
2455 5.0.1. This version mainly fixes a number of bugs found in version 5.0.0 during
2456 the ongoing development process.
2458 \subsection{Truncate Volume after Purge}
2459 \label{sec:actiononpurge}
2461 The Pool directive \textbf{ActionOnPurge=Truncate} instructs Bacula to truncate
2462 the volume when it is purged with the new command \texttt{purge volume
2463 action}. It is useful to prevent disk based volumes from consuming too much
2469 Action On Purge = Truncate
2474 As usual you can also set this property with the \texttt{update volume} command
2476 *update volume=xxx ActionOnPurge=Truncate
2477 *update volume=xxx actiononpurge=None
2480 To ask Bacula to truncate your \texttt{Purged} volumes, you need to use the
2481 following command in interactive mode or in a RunScript as shown after:
2483 *purge volume action=truncate storage=File allpools
2484 # or by default, action=all
2485 *purge volume action storage=File pool=Default
2488 This is possible to specify the volume name, the media type, the pool, the
2489 storage, etc\dots (see \texttt{help purge}) Be sure that your storage device is
2490 idle when you decide to run this command.
2494 Name = CatalogBackup
2499 Console = "purge volume action=all allpools storage=File"
2504 \textbf{Important note}: This feature doesn't work as
2505 expected in version 5.0.0. Please do not use it before version 5.0.1.
2507 \subsection{Allow Higher Duplicates}
2508 This directive did not work correctly and has been depreciated
2509 (disabled) in version 5.0.1. Please remove it from your bacula-dir.conf
2510 file as it will be removed in a future release.
2512 \subsection{Cancel Lower Level Duplicates}
2513 This directive was added in Bacula version 5.0.1. It compares the
2514 level of a new backup job to old jobs of the same name, if any,
2515 and will kill the job which has a lower level than the other one.
2516 If the levels are the same (i.e. both are Full backups), then
2517 nothing is done and the other Cancel XXX Duplicate directives
2520 \section{New Features in 5.0.0}
2522 \subsection{Maximum Concurrent Jobs for Devices}
2523 \label{sec:maximumconcurrentjobdevice}
2525 {\bf Maximum Concurrent Jobs} is a new Device directive in the Storage
2526 Daemon configuration permits setting the maximum number of Jobs that can
2527 run concurrently on a specified Device. Using this directive, it is
2528 possible to have different Jobs using multiple drives, because when the
2529 Maximum Concurrent Jobs limit is reached, the Storage Daemon will start new
2530 Jobs on any other available compatible drive. This facilitates writing to
2531 multiple drives with multiple Jobs that all use the same Pool.
2533 This project was funded by Bacula Systems.
2535 \subsection{Restore from Multiple Storage Daemons}
2536 \index[general]{Restore}
2538 Previously, you were able to restore from multiple devices in a single Storage
2539 Daemon. Now, Bacula is able to restore from multiple Storage Daemons. For
2540 example, if your full backup runs on a Storage Daemon with an autochanger, and
2541 your incremental jobs use another Storage Daemon with lots of disks, Bacula
2542 will switch automatically from one Storage Daemon to an other within the same
2545 You must upgrade your File Daemon to version 3.1.3 or greater to use this
2548 This project was funded by Bacula Systems with the help of Equiinet.
2550 \subsection{File Deduplication using Base Jobs}
2551 A base job is sort of like a Full save except that you will want the FileSet to
2552 contain only files that are unlikely to change in the future (i.e. a snapshot
2553 of most of your system after installing it). After the base job has been run,
2554 when you are doing a Full save, you specify one or more Base jobs to be used.
2555 All files that have been backed up in the Base job/jobs but not modified will
2556 then be excluded from the backup. During a restore, the Base jobs will be
2557 automatically pulled in where necessary.
2559 This is something none of the competition does, as far as we know (except
2560 perhaps BackupPC, which is a Perl program that saves to disk only). It is big
2561 win for the user, it makes Bacula stand out as offering a unique optimization
2562 that immediately saves time and money. Basically, imagine that you have 100
2563 nearly identical Windows or Linux machine containing the OS and user files.
2564 Now for the OS part, a Base job will be backed up once, and rather than making
2565 100 copies of the OS, there will be only one. If one or more of the systems
2566 have some files updated, no problem, they will be automatically restored.
2568 See the \ilink{Base Job Chapter}{basejobs} for more information.
2570 This project was funded by Bacula Systems.
2572 \subsection{AllowCompression = \lt{}yes\vb{}no\gt{}}
2573 \index[dir]{AllowCompression}
2575 This new directive may be added to Storage resource within the Director's
2576 configuration to allow users to selectively disable the client compression for
2577 any job which writes to this storage resource.
2583 Address = ultrium-tape
2584 Password = storage_password # Password for Storage Daemon
2587 AllowCompression = No # Tape drive has hardware compression
2590 The above example would cause any jobs running with the UltriumTape storage
2591 resource to run without compression from the client file daemons. This
2592 effectively overrides any compression settings defined at the FileSet level.
2594 This feature is probably most useful if you have a tape drive which supports
2595 hardware compression. By setting the \texttt{AllowCompression = No} directive
2596 for your tape drive storage resource, you can avoid additional load on the file
2597 daemon and possibly speed up tape backups.
2599 This project was funded by Collaborative Fusion, Inc.
2601 \subsection{Accurate Fileset Options}
2602 \label{sec:accuratefileset}
2604 In previous versions, the accurate code used the file creation and modification
2605 times to determine if a file was modified or not. Now you can specify which
2606 attributes to use (time, size, checksum, permission, owner, group, \dots),
2607 similar to the Verify options.
2623 \item {\bf i} compare the inodes
2624 \item {\bf p} compare the permission bits
2625 \item {\bf n} compare the number of links
2626 \item {\bf u} compare the user id
2627 \item {\bf g} compare the group id
2628 \item {\bf s} compare the size
2629 \item {\bf a} compare the access time
2630 \item {\bf m} compare the modification time (st\_mtime)
2631 \item {\bf c} compare the change time (st\_ctime)
2632 \item {\bf d} report file size decreases
2633 \item {\bf 5} compare the MD5 signature
2634 \item {\bf 1} compare the SHA1 signature
2637 \textbf{Important note:} If you decide to use checksum in Accurate jobs,
2638 the File Daemon will have to read all files even if they normally would not
2639 be saved. This increases the I/O load, but also the accuracy of the
2640 deduplication. By default, Bacula will check modification/creation time
2643 This project was funded by Bacula Systems.
2645 \subsection{Tab-completion for Bconsole}
2646 \label{sec:tabcompletion}
2648 If you build \texttt{bconsole} with readline support, you will be able to use
2649 the new auto-completion mode. This mode supports all commands, gives help
2650 inside command, and lists resources when required. It works also in the restore
2653 To use this feature, you should have readline development package loaded on
2654 your system, and use the following option in configure.
2656 ./configure --with-readline=/usr/include/readline --disable-conio ...
2659 The new bconsole won't be able to tab-complete with older directors.
2661 This project was funded by Bacula Systems.
2663 \subsection{Pool File and Job Retention}
2664 \label{sec:poolfilejobretention}
2666 We added two new Pool directives, \texttt{FileRetention} and
2667 \texttt{JobRetention}, that take precedence over Client directives of the same
2668 name. It allows you to control the Catalog pruning algorithm Pool by Pool. For
2669 example, you can decide to increase Retention times for Archive or OffSite Pool.
2671 It seems obvious to us, but apparently not to some users, that given the
2672 definition above that the Pool File and Job Retention periods is a global
2673 override for the normal Client based pruning, which means that when the
2674 Job is pruned, the pruning will apply globally to that particular Job.
2676 Currently, there is a bug in the implementation that causes any Pool
2677 retention periods specified to apply to {\bf all} Pools for that
2678 particular Client. Thus we suggest that you avoid using these two
2679 directives until this implementation problem is corrected.
2681 \subsection{Read-only File Daemon using capabilities}
2682 \label{sec:fdreadonly}
2683 This feature implements support of keeping \textbf{ReadAll} capabilities after
2684 UID/GID switch, this allows FD to keep root read but drop write permission.
2686 It introduces new \texttt{bacula-fd} option (\texttt{-k}) specifying that
2687 \textbf{ReadAll} capabilities should be kept after UID/GID switch.
2690 root@localhost:~# bacula-fd -k -u nobody -g nobody
2693 The code for this feature was contributed by our friends at AltLinux.
2695 \subsection{Bvfs API}
2698 To help developers of restore GUI interfaces, we have added new \textsl{dot
2699 commands} that permit browsing the catalog in a very simple way.
2702 \item \texttt{.bvfs\_update [jobid=x,y,z]} This command is required to update
2703 the Bvfs cache in the catalog. You need to run it before any access to the
2706 \item \texttt{.bvfs\_lsdirs jobid=x,y,z path=/path | pathid=101} This command
2707 will list all directories in the specified \texttt{path} or
2708 \texttt{pathid}. Using \texttt{pathid} avoids problems with character
2709 encoding of path/filenames.
2711 \item \texttt{.bvfs\_lsfiles jobid=x,y,z path=/path | pathid=101} This command
2712 will list all files in the specified \texttt{path} or \texttt{pathid}. Using
2713 \texttt{pathid} avoids problems with character encoding.
2716 You can use \texttt{limit=xxx} and \texttt{offset=yyy} to limit the amount of
2717 data that will be displayed.
2720 * .bvfs_update jobid=1,2
2722 * .bvfs_lsdir path=/ jobid=1,2
2725 This project was funded by Bacula Systems.
2727 \subsection{Testing your Tape Drive}
2728 \label{sec:btapespeed}
2730 To determine the best configuration of your tape drive, you can run the new
2731 \texttt{speed} command available in the \texttt{btape} program.
2733 This command can have the following arguments:
2735 \item[\texttt{file\_size=n}] Specify the Maximum File Size for this test
2736 (between 1 and 5GB). This counter is in GB.
2737 \item[\texttt{nb\_file=n}] Specify the number of file to be written. The amount
2738 of data should be greater than your memory ($file\_size*nb\_file$).
2739 \item[\texttt{skip\_zero}] This flag permits to skip tests with constant
2741 \item[\texttt{skip\_random}] This flag permits to skip tests with random
2743 \item[\texttt{skip\_raw}] This flag permits to skip tests with raw access.
2744 \item[\texttt{skip\_block}] This flag permits to skip tests with Bacula block
2749 *speed file_size=3 skip_raw
2750 btape.c:1078 Test with zero data and bacula block structure.
2751 btape.c:956 Begin writing 3 files of 3.221 GB with blocks of 129024 bytes.
2752 ++++++++++++++++++++++++++++++++++++++++++
2753 btape.c:604 Wrote 1 EOF to "Drive-0" (/dev/nst0)
2754 btape.c:406 Volume bytes=3.221 GB. Write rate = 44.128 MB/s
2756 btape.c:383 Total Volume bytes=9.664 GB. Total Write rate = 43.531 MB/s
2758 btape.c:1090 Test with random data, should give the minimum throughput.
2759 btape.c:956 Begin writing 3 files of 3.221 GB with blocks of 129024 bytes.
2760 +++++++++++++++++++++++++++++++++++++++++++
2761 btape.c:604 Wrote 1 EOF to "Drive-0" (/dev/nst0)
2762 btape.c:406 Volume bytes=3.221 GB. Write rate = 7.271 MB/s
2763 +++++++++++++++++++++++++++++++++++++++++++
2765 btape.c:383 Total Volume bytes=9.664 GB. Total Write rate = 7.365 MB/s
2769 When using compression, the random test will give your the minimum throughput
2770 of your drive . The test using constant string will give you the maximum speed
2771 of your hardware chain. (CPU, memory, SCSI card, cable, drive, tape).
2773 You can change the block size in the Storage Daemon configuration file.
2775 \subsection{New {\bf Block Checksum} Device Directive}
2776 You may now turn off the Block Checksum (CRC32) code
2777 that Bacula uses when writing blocks to a Volume. This is
2784 doing so can reduce the Storage daemon CPU usage slightly. It
2785 will also permit Bacula to read a Volume that has corrupted data.
2787 The default is {\bf yes} -- i.e. the checksum is computed on write
2788 and checked on read.
2790 We do not recommend to turn this off particularly on older tape
2791 drives or for disk Volumes where doing so may allow corrupted data
2794 \subsection{New Bat Features}
2796 Those new features were funded by Bacula Systems.
2798 \subsubsection{Media List View}
2800 By clicking on ``Media'', you can see the list of all your volumes. You will be
2801 able to filter by Pool, Media Type, Location,\dots And sort the result directly
2802 in the table. The old ``Media'' view is now known as ``Pool''.
2803 \begin{figure}[htbp]
2805 \includegraphics[width=0.8\linewidth]{bat-mediaview}
2806 \label{fig:mediaview}
2810 \subsubsection{Media Information View}
2812 By double-clicking on a volume (on the Media list, in the Autochanger content
2813 or in the Job information panel), you can access a detailed overview of your
2814 Volume. (cf figure \vref{fig:mediainfo}.)
2815 \begin{figure}[htbp]
2817 \includegraphics[width=0.8\linewidth]{bat11}
2818 \caption{Media information}
2819 \label{fig:mediainfo}
2822 \subsubsection{Job Information View}
2824 By double-clicking on a Job record (on the Job run list or in the Media
2825 information panel), you can access a detailed overview of your Job. (cf
2826 figure \vref{fig:jobinfo}.)
2827 \begin{figure}[htbp]
2829 \includegraphics[width=0.8\linewidth]{bat12}
2830 \caption{Job information}
2834 \subsubsection{Autochanger Content View}
2836 By double-clicking on a Storage record (on the Storage list panel), you can
2837 access a detailed overview of your Autochanger. (cf figure \vref{fig:jobinfo}.)
2838 \begin{figure}[htbp]
2840 \includegraphics[width=0.8\linewidth]{bat13}
2841 \caption{Autochanger content}
2842 \label{fig:achcontent}
2845 To use this feature, you need to use the latest mtx-changer script
2846 version. (With new \texttt{listall} and \texttt{transfer} commands)
2848 \subsection{Bat on Windows}
2849 We have ported {\bf bat} to Windows and it is now installed
2850 by default when the installer is run. It works quite well
2851 on Win32, but has not had a lot of testing there, so your
2852 feedback would be welcome. Unfortunately, even though it is
2853 installed by default, it does not yet work on 64 bit Windows
2856 \subsection{New Win32 Installer}
2857 The Win32 installer has been modified in several very important
2860 \item You must deinstall any current version of the
2861 Win32 File daemon before upgrading to the new one.
2862 If you forget to do so, the new installation will fail.
2863 To correct this failure, you must manually shutdown
2864 and deinstall the old File daemon.
2865 \item All files (other than menu links) are installed
2866 in {\bf c:/Program Files/Bacula}.
2867 \item The installer no longer sets this
2868 file to require administrator privileges by default. If you want
2869 to do so, please do it manually using the {\bf cacls} program.
2872 cacls "C:\Program Files\Bacula" /T /G SYSTEM:F Administrators:F
2874 \item The server daemons (Director and Storage daemon) are
2875 no longer included in the Windows installer. If you want the
2876 Windows servers, you will either need to build them yourself (note
2877 they have not been ported to 64 bits), or you can contact
2878 Bacula Systems about this.
2881 \subsection{Win64 Installer}
2882 We have corrected a number of problems that required manual
2883 editing of the conf files. In most cases, it should now
2884 install and work. {\bf bat} is by default installed in
2885 {\bf c:/Program Files/Bacula/bin32} rather than
2886 {\bf c:/Program Files/Bacula} as is the case with the 32
2887 bit Windows installer.
2889 \subsection{Linux Bare Metal Recovery USB Key}
2890 We have made a number of significant improvements in the
2891 Bare Metal Recovery USB key. Please see the README files
2892 it the {\bf rescue} release for more details.
2894 We are working on an equivalent USB key for Windows bare
2895 metal recovery, but it will take some time to develop it (best
2896 estimate 3Q2010 or 4Q2010)
2899 \subsection{bconsole Timeout Option}
2900 You can now use the -u option of {\bf bconsole} to set a timeout in seconds
2901 for commands. This is useful with GUI programs that use {\bf bconsole}
2902 to interface to the Director.
2904 \subsection{Important Changes}
2905 \label{sec:importantchanges}
2908 \item You are now allowed to Migrate, Copy, and Virtual Full to read and write
2909 to the same Pool. The Storage daemon ensures that you do not read and
2910 write to the same Volume.
2911 \item The \texttt{Device Poll Interval} is now 5 minutes. (previously did not
2913 \item Virtually all the features of {\bf mtx-changer} have
2914 now been parametrized, which allows you to configure
2915 mtx-changer without changing it. There is a new configuration file {\bf mtx-changer.conf}
2916 that contains variables that you can set to configure mtx-changer.
2917 This configuration file will not be overwritten during upgrades.
2918 We encourage you to submit any changes
2919 that are made to mtx-changer and to parametrize it all in
2920 mtx-changer.conf so that all configuration will be done by
2921 changing only mtx-changer.conf.
2922 \item The new \texttt{mtx-changer} script has two new options, \texttt{listall}
2923 and \texttt{transfer}. Please configure them as appropriate
2924 in mtx-changer.conf.
2925 \item To enhance security of the \texttt{BackupCatalog} job, we provide a new
2926 script (\texttt{make\_catalog\_backup.pl}) that does not expose your catalog
2927 password. If you want to use the new script, you will need to
2928 manually change the \texttt{BackupCatalog} Job definition.
2929 \item The \texttt{bconsole} \texttt{help} command now accepts
2930 an argument, which if provided produces information on that
2931 command (ex: \texttt{help run}).
2935 \subsubsection*{Truncate volume after purge}
2937 Note that the Truncate Volume after purge feature doesn't work as expected
2938 in 5.0.0 version. Please, don't use it before version 5.0.1.
2940 \subsubsection{Custom Catalog queries}
2942 If you wish to add specialized commands that list the contents of the catalog,
2943 you can do so by adding them to the \texttt{query.sql} file. This
2944 \texttt{query.sql} file is now empty by default. The file
2945 \texttt{examples/sample-query.sql} has an a number of sample commands
2946 you might find useful.
2948 \subsubsection{Deprecated parts}
2950 The following items have been \textbf{deprecated} for a long time, and are now
2951 removed from the code.
2954 \item Support for SQLite 2
2957 \subsection{Misc Changes}
2958 \label{sec:miscchanges}
2961 \item Updated Nagios check\_bacula
2962 \item Updated man files
2963 \item Added OSX package generation script in platforms/darwin
2964 \item Added Spanish and Ukrainian Bacula translations
2965 \item Enable/disable command shows only Jobs that can change
2966 \item Added \texttt{show disabled} command to show disabled Jobs
2967 \item Many ACL improvements
2968 \item Added Level to FD status Job output
2969 \item Begin Ingres DB driver (not yet working)
2970 \item Split RedHat spec files into bacula, bat, mtx, and docs
2971 \item Reorganized the manuals (fewer separate manuals)
2972 \item Added lock/unlock order protection in lock manager
2973 \item Allow 64 bit sizes for a number of variables
2974 \item Fixed several deadlocks or potential race conditions in the SD
2977 \chapter{Released Version 3.0.3 and 3.0.3a}
2979 There are no new features in version 3.0.3. This version simply fixes a
2980 number of bugs found in version 3.0.2 during the ongoing development
2983 \section{New Features in Released Version 3.0.2}
2985 This chapter presents the new features added to the
2986 Released Bacula Version 3.0.2.
2988 \subsection{Full Restore from a Given JobId}
2989 \index[general]{Restore menu}
2991 This feature allows selecting a single JobId and having Bacula
2992 automatically select all the other jobs that comprise a full backup up to
2993 and including the selected date (through JobId).
2995 Assume we start with the following jobs:
2997 +-------+--------------+---------------------+-------+----------+------------+
2998 | jobid | client | starttime | level | jobfiles | jobbytes |
2999 +-------+--------------+---------------------+-------+----------+------------
3000 | 6 | localhost-fd | 2009-07-15 11:45:49 | I | 2 | 0 |
3001 | 5 | localhost-fd | 2009-07-15 11:45:45 | I | 15 | 44143 |
3002 | 3 | localhost-fd | 2009-07-15 11:45:38 | I | 1 | 10 |
3003 | 1 | localhost-fd | 2009-07-15 11:45:30 | F | 1527 | 44143073 |
3004 +-------+--------------+---------------------+-------+----------+------------+
3007 Below is an example of this new feature (which is number 12 in the
3012 To select the JobIds, you have the following choices:
3013 1: List last 20 Jobs run
3014 2: List Jobs where a given File is saved
3016 12: Select full restore to a specified Job date
3019 Select item: (1-13): 12
3020 Enter JobId to get the state to restore: 5
3021 Selecting jobs to build the Full state at 2009-07-15 11:45:45
3022 You have selected the following JobIds: 1,3,5
3024 Building directory tree for JobId(s) 1,3,5 ... +++++++++++++++++++
3025 1,444 files inserted into the tree.
3028 This project was funded by Bacula Systems.
3030 \subsection{Source Address}
3031 \index[general]{Source Address}
3033 A feature has been added which allows the administrator to specify the address
3034 from which the Director and File daemons will establish connections. This
3035 may be used to simplify system configuration overhead when working in complex
3036 networks utilizing multi-homing and policy-routing.
3038 To accomplish this, two new configuration directives have been implemented:
3041 FDSourceAddress=10.0.1.20 # Always initiate connections from this address
3045 DirSourceAddress=10.0.1.10 # Always initiate connections from this address
3049 Simply adding specific host routes on the OS
3050 would have an undesirable side-effect: any
3051 application trying to contact the destination host would be forced to use the
3052 more specific route possibly diverting management traffic onto a backup VLAN.
3053 Instead of adding host routes for each client connected to a multi-homed backup
3054 server (for example where there are management and backup VLANs), one can
3055 use the new directives to specify a specific source address at the application
3058 Additionally, this allows the simplification and abstraction of firewall rules
3059 when dealing with a Hot-Standby director or storage daemon configuration. The
3060 Hot-standby pair may share a CARP address, which connections must be sourced
3061 from, while system services listen and act from the unique interface addresses.
3063 This project was funded by Collaborative Fusion, Inc.
3065 \subsection{Show volume availability when doing restore}
3067 When doing a restore the selection dialog ends by displaying this
3071 The job will require the following
3072 Volume(s) Storage(s) SD Device(s)
3073 ===========================================================================
3074 *000741L3 LTO-4 LTO3
3075 *000866L3 LTO-4 LTO3
3076 *000765L3 LTO-4 LTO3
3077 *000764L3 LTO-4 LTO3
3078 *000756L3 LTO-4 LTO3
3079 *001759L3 LTO-4 LTO3
3080 *001763L3 LTO-4 LTO3
3084 Volumes marked with ``*'' are online (in the autochanger).
3087 This should help speed up large restores by minimizing the time spent
3088 waiting for the operator to discover that he must change tapes in the library.
3090 This project was funded by Bacula Systems.
3092 \subsection{Accurate estimate command}
3094 The \texttt{estimate} command can now use the accurate code to detect changes
3095 and give a better estimation.
3097 You can set the accurate behavior on the command line by using
3098 \texttt{accurate=yes\vb{}no} or use the Job setting as default value.
3101 * estimate listing accurate=yes level=incremental job=BackupJob
3104 This project was funded by Bacula Systems.
3106 \section{New Features in 3.0.0}
3107 \label{NewFeaturesChapter}
3108 \index[general]{New Features}
3110 This chapter presents the new features added to the development 2.5.x
3111 versions to be released as Bacula version 3.0.0 sometime in April 2009.
3113 \subsection{Accurate Backup}
3114 \index[general]{Accurate Backup}
3116 As with most other backup programs, by default Bacula decides what files to
3117 backup for Incremental and Differential backup by comparing the change
3118 (st\_ctime) and modification (st\_mtime) times of the file to the time the last
3119 backup completed. If one of those two times is later than the last backup
3120 time, then the file will be backed up. This does not, however, permit tracking
3121 what files have been deleted and will miss any file with an old time that may
3122 have been restored to or moved onto the client filesystem.
3124 \subsubsection{Accurate = \lt{}yes\vb{}no\gt{}}
3125 If the {\bf Accurate = \lt{}yes\vb{}no\gt{}} directive is enabled (default no) in
3126 the Job resource, the job will be run as an Accurate Job. For a {\bf Full}
3127 backup, there is no difference, but for {\bf Differential} and {\bf
3128 Incremental} backups, the Director will send a list of all previous files
3129 backed up, and the File daemon will use that list to determine if any new files
3130 have been added or or moved and if any files have been deleted. This allows
3131 Bacula to make an accurate backup of your system to that point in time so that
3132 if you do a restore, it will restore your system exactly.
3135 about using Accurate backup is that it requires more resources (CPU and memory)
3136 on both the Director and the Client machines to create the list of previous
3137 files backed up, to send that list to the File daemon, for the File daemon to
3138 keep the list (possibly very big) in memory, and for the File daemon to do
3139 comparisons between every file in the FileSet and the list. In particular,
3140 if your client has lots of files (more than a few million), you will need
3141 lots of memory on the client machine.
3143 Accurate must not be enabled when backing up with a plugin that is not
3144 specially designed to work with Accurate. If you enable it, your restores
3145 will probably not work correctly.
3147 This project was funded by Bacula Systems.
3151 \subsection{Copy Jobs}
3152 \index[general]{Copy Jobs}
3154 A new {\bf Copy} job type 'C' has been implemented. It is similar to the
3155 existing Migration feature with the exception that the Job that is copied is
3156 left unchanged. This essentially creates two identical copies of the same
3157 backup. However, the copy is treated as a copy rather than a backup job, and
3158 hence is not directly available for restore. The {\bf restore} command lists
3159 copy jobs and allows selection of copies by using \texttt{jobid=}
3160 option. If the keyword {\bf copies} is present on the command line, Bacula will
3161 display the list of all copies for selected jobs.
3166 These JobIds have copies as follows:
3167 +-------+------------------------------------+-----------+------------------+
3168 | JobId | Job | CopyJobId | MediaType |
3169 +-------+------------------------------------+-----------+------------------+
3170 | 2 | CopyJobSave.2009-02-17_16.31.00.11 | 7 | DiskChangerMedia |
3171 +-------+------------------------------------+-----------+------------------+
3172 +-------+-------+----------+----------+---------------------+------------------+
3173 | JobId | Level | JobFiles | JobBytes | StartTime | VolumeName |
3174 +-------+-------+----------+----------+---------------------+------------------+
3175 | 19 | F | 6274 | 76565018 | 2009-02-17 16:30:45 | ChangerVolume002 |
3176 | 2 | I | 1 | 5 | 2009-02-17 16:30:51 | FileVolume001 |
3177 +-------+-------+----------+----------+---------------------+------------------+
3178 You have selected the following JobIds: 19,2
3180 Building directory tree for JobId(s) 19,2 ... ++++++++++++++++++++++++++++++++++++++++++++
3181 5,611 files inserted into the tree.
3186 The Copy Job runs without using the File daemon by copying the data from the
3187 old backup Volume to a different Volume in a different Pool. See the Migration
3188 documentation for additional details. For copy Jobs there is a new selection
3189 directive named {\bf PoolUncopiedJobs} which selects all Jobs that were
3190 not already copied to another Pool.
3192 As with Migration, the Client, Volume, Job, or SQL query, are
3193 other possible ways of selecting the Jobs to be copied. Selection
3194 types like SmallestVolume, OldestVolume, PoolOccupancy and PoolTime also
3195 work, but are probably more suited for Migration Jobs.
3197 If Bacula finds a Copy of a job record that is purged (deleted) from the catalog,
3198 it will promote the Copy to a \textsl{real} backup job and will make it available for
3199 automatic restore. If more than one Copy is available, it will promote the copy
3200 with the smallest JobId.
3202 A nice solution which can be built with the new Copy feature is often
3203 called disk-to-disk-to-tape backup (DTDTT). A sample config could
3204 look something like the one below:
3208 Name = FullBackupsVirtualPool
3210 Purge Oldest Volume = Yes
3212 NextPool = FullBackupsTapePool
3216 Name = FullBackupsTapePool
3220 Volume Retention = 365 days
3221 Storage = superloader
3225 # Fake fileset for copy jobs
3237 # Fake client for copy jobs
3247 # Default template for a CopyDiskToTape Job
3250 Name = CopyDiskToTape
3252 Messages = StandardCopy
3255 Selection Type = PoolUncopiedJobs
3256 Maximum Concurrent Jobs = 10
3258 Allow Duplicate Jobs = Yes
3259 Cancel Queued Duplicates = No
3260 Cancel Running Duplicates = No
3265 Name = DaySchedule7:00
3266 Run = Level=Full daily at 7:00
3270 Name = CopyDiskToTapeFullBackups
3272 Schedule = DaySchedule7:00
3273 Pool = FullBackupsVirtualPool
3274 JobDefs = CopyDiskToTape
3278 The example above had 2 pool which are copied using the PoolUncopiedJobs
3279 selection criteria. Normal Full backups go to the Virtual pool and are copied
3280 to the Tape pool the next morning.
3282 The command \texttt{list copies [jobid=x,y,z]} lists copies for a given
3287 +-------+------------------------------------+-----------+------------------+
3288 | JobId | Job | CopyJobId | MediaType |
3289 +-------+------------------------------------+-----------+------------------+
3290 | 9 | CopyJobSave.2008-12-20_22.26.49.05 | 11 | DiskChangerMedia |
3291 +-------+------------------------------------+-----------+------------------+
3294 \subsection{ACL Updates}
3295 \index[general]{ACL Updates}
3296 The whole ACL code had been overhauled and in this version each platforms has
3297 different streams for each type of acl available on such an platform. As ACLs
3298 between platforms tend to be not that portable (most implement POSIX acls but
3299 some use an other draft or a completely different format) we currently only
3300 allow certain platform specific ACL streams to be decoded and restored on the
3301 same platform that they were created on. The old code allowed to restore ACL
3302 cross platform but the comments already mention that not being to wise. For
3303 backward compatibility the new code will accept the two old ACL streams and
3304 handle those with the platform specific handler. But for all new backups it
3305 will save the ACLs using the new streams.
3307 Currently the following platforms support ACLs:
3311 \item {\bf Darwin/OSX}
3320 Currently we support the following ACL types (these ACL streams use a reserved
3321 part of the stream numbers):
3324 \item {\bf STREAM\_ACL\_AIX\_TEXT} 1000 AIX specific string representation from
3326 \item {\bf STREAM\_ACL\_DARWIN\_ACCESS\_ACL} 1001 Darwin (OSX) specific acl\_t
3327 string representation from acl\_to\_text (POSIX acl)
3328 \item {\bf STREAM\_ACL\_FREEBSD\_DEFAULT\_ACL} 1002 FreeBSD specific acl\_t
3329 string representation from acl\_to\_text (POSIX acl) for default acls.
3330 \item {\bf STREAM\_ACL\_FREEBSD\_ACCESS\_ACL} 1003 FreeBSD specific acl\_t
3331 string representation from acl\_to\_text (POSIX acl) for access acls.
3332 \item {\bf STREAM\_ACL\_HPUX\_ACL\_ENTRY} 1004 HPUX specific acl\_entry
3333 string representation from acltostr (POSIX acl)
3334 \item {\bf STREAM\_ACL\_IRIX\_DEFAULT\_ACL} 1005 IRIX specific acl\_t string
3335 representation from acl\_to\_text (POSIX acl) for default acls.
3336 \item {\bf STREAM\_ACL\_IRIX\_ACCESS\_ACL} 1006 IRIX specific acl\_t string
3337 representation from acl\_to\_text (POSIX acl) for access acls.
3338 \item {\bf STREAM\_ACL\_LINUX\_DEFAULT\_ACL} 1007 Linux specific acl\_t
3339 string representation from acl\_to\_text (POSIX acl) for default acls.
3340 \item {\bf STREAM\_ACL\_LINUX\_ACCESS\_ACL} 1008 Linux specific acl\_t string
3341 representation from acl\_to\_text (POSIX acl) for access acls.
3342 \item {\bf STREAM\_ACL\_TRU64\_DEFAULT\_ACL} 1009 Tru64 specific acl\_t
3343 string representation from acl\_to\_text (POSIX acl) for default acls.
3344 \item {\bf STREAM\_ACL\_TRU64\_DEFAULT\_DIR\_ACL} 1010 Tru64 specific acl\_t
3345 string representation from acl\_to\_text (POSIX acl) for default acls.
3346 \item {\bf STREAM\_ACL\_TRU64\_ACCESS\_ACL} 1011 Tru64 specific acl\_t string
3347 representation from acl\_to\_text (POSIX acl) for access acls.
3348 \item {\bf STREAM\_ACL\_SOLARIS\_ACLENT} 1012 Solaris specific aclent\_t
3349 string representation from acltotext or acl\_totext (POSIX acl)
3350 \item {\bf STREAM\_ACL\_SOLARIS\_ACE} 1013 Solaris specific ace\_t string
3351 representation from from acl\_totext (NFSv4 or ZFS acl)
3354 In future versions we might support conversion functions from one type of acl
3355 into an other for types that are either the same or easily convertible. For now
3356 the streams are separate and restoring them on a platform that doesn't
3357 recognize them will give you a warning.
3359 \subsection{Extended Attributes}
3360 \index[general]{Extended Attributes}
3361 Something that was on the project list for some time is now implemented for
3362 platforms that support a similar kind of interface. Its the support for backup
3363 and restore of so called extended attributes. As extended attributes are so
3364 platform specific these attributes are saved in separate streams for each
3365 platform. Restores of the extended attributes can only be performed on the
3366 same platform the backup was done. There is support for all types of extended
3367 attributes, but restoring from one type of filesystem onto an other type of
3368 filesystem on the same platform may lead to surprises. As extended attributes
3369 can contain any type of data they are stored as a series of so called
3370 value-pairs. This data must be seen as mostly binary and is stored as such.
3371 As security labels from selinux are also extended attributes this option also
3372 stores those labels and no specific code is enabled for handling selinux
3375 Currently the following platforms support extended attributes:
3377 \item {\bf Darwin/OSX}
3383 On Linux acls are also extended attributes, as such when you enable ACLs on a
3384 Linux platform it will NOT save the same data twice e.g. it will save the ACLs
3385 and not the same extended attribute.
3387 To enable the backup of extended attributes please add the following to your
3402 \subsection{Shared objects}
3403 \index[general]{Shared objects}
3404 A default build of Bacula will now create the libraries as shared objects
3405 (.so) rather than static libraries as was previously the case.
3406 The shared libraries are built using {\bf libtool} so it should be quite
3409 An important advantage of using shared objects is that on a machine with the
3410 Directory, File daemon, the Storage daemon, and a console, you will have only
3411 one copy of the code in memory rather than four copies. Also the total size of
3412 the binary release is smaller since the library code appears only once rather
3413 than once for every program that uses it; this results in significant reduction
3414 in the size of the binaries particularly for the utility tools.
3416 In order for the system loader to find the shared objects when loading the
3417 Bacula binaries, the Bacula shared objects must either be in a shared object
3418 directory known to the loader (typically /usr/lib) or they must be in the
3419 directory that may be specified on the {\bf ./configure} line using the {\bf
3420 {-}{-}libdir} option as:
3423 ./configure --libdir=/full-path/dir
3426 the default is /usr/lib. If {-}{-}libdir is specified, there should be
3427 no need to modify your loader configuration provided that
3428 the shared objects are installed in that directory (Bacula
3429 does this with the make install command). The shared objects
3430 that Bacula references are:
3439 These files are symbolically linked to the real shared object file,
3440 which has a version number to permit running multiple versions of
3441 the libraries if desired (not normally the case).
3443 If you have problems with libtool or you wish to use the old
3444 way of building static libraries, or you want to build a static
3445 version of Bacula you may disable
3446 libtool on the configure command line with:
3449 ./configure --disable-libtool
3453 \subsection{Building Static versions of Bacula}
3454 \index[general]{Static linking}
3455 In order to build static versions of Bacula, in addition
3456 to configuration options that were needed you now must
3457 also add --disable-libtool. Example
3460 ./configure --enable-static-client-only --disable-libtool
3464 \subsection{Virtual Backup (Vbackup)}
3465 \index[general]{Virtual Backup}
3466 \index[general]{Vbackup}
3468 Bacula's virtual backup feature is often called Synthetic Backup or
3469 Consolidation in other backup products. It permits you to consolidate the
3470 previous Full backup plus the most recent Differential backup and any
3471 subsequent Incremental backups into a new Full backup. This new Full
3472 backup will then be considered as the most recent Full for any future
3473 Incremental or Differential backups. The VirtualFull backup is
3474 accomplished without contacting the client by reading the previous backup
3475 data and writing it to a volume in a different pool.
3477 In some respects the Vbackup feature works similar to a Migration job, in
3478 that Bacula normally reads the data from the pool specified in the
3479 Job resource, and writes it to the {\bf Next Pool} specified in the
3480 Job resource. Note, this means that usually the output from the Virtual
3481 Backup is written into a different pool from where your prior backups
3482 are saved. Doing it this way guarantees that you will not get a deadlock
3483 situation attempting to read and write to the same volume in the Storage
3484 daemon. If you then want to do subsequent backups, you may need to
3485 move the Virtual Full Volume back to your normal backup pool.
3486 Alternatively, you can set your {\bf Next Pool} to point to the current
3487 pool. This will cause Bacula to read and write to Volumes in the
3488 current pool. In general, this will work, because Bacula will
3489 not allow reading and writing on the same Volume. In any case, once
3490 a VirtualFull has been created, and a restore is done involving the
3491 most current Full, it will read the Volume or Volumes by the VirtualFull
3492 regardless of in which Pool the Volume is found.
3494 The Vbackup is enabled on a Job by Job in the Job resource by specifying
3495 a level of {\bf VirtualFull}.
3497 A typical Job resource definition might look like the following:
3504 FileSet = "Full Set"
3511 # Default pool definition
3515 Recycle = yes # Automatically recycle Volumes
3516 AutoPrune = yes # Prune expired volumes
3517 Volume Retention = 365d # one year
3525 Recycle = yes # Automatically recycle Volumes
3526 AutoPrune = yes # Prune expired volumes
3527 Volume Retention = 365d # one year
3528 Storage = DiskChanger
3531 # Definition of file storage device
3536 Device = FileStorage
3538 Maximum Concurrent Jobs = 5
3541 # Definition of DDS Virtual tape disk storage device
3544 Address = localhost # N.B. Use a fully qualified name here
3546 Device = DiskChanger
3547 Media Type = DiskChangerMedia
3548 Maximum Concurrent Jobs = 4
3553 Then in bconsole or via a Run schedule, you would run the job as:
3556 run job=MyBackup level=Full
3557 run job=MyBackup level=Incremental
3558 run job=MyBackup level=Differential
3559 run job=MyBackup level=Incremental
3560 run job=MyBackup level=Incremental
3563 So providing there were changes between each of those jobs, you would end up
3564 with a Full backup, a Differential, which includes the first Incremental
3565 backup, then two Incremental backups. All the above jobs would be written to
3566 the {\bf Default} pool.
3568 To consolidate those backups into a new Full backup, you would run the
3572 run job=MyBackup level=VirtualFull
3575 And it would produce a new Full backup without using the client, and the output
3576 would be written to the {\bf Full} Pool which uses the Diskchanger Storage.
3578 If the Virtual Full is run, and there are no prior Jobs, the Virtual Full will
3581 Note, the Start and End time of the Virtual Full backup is set to the
3582 values for the last job included in the Virtual Full (in the above example,
3583 it is an Increment). This is so that if another incremental is done, which
3584 will be based on the Virtual Full, it will backup all files from the
3585 last Job included in the Virtual Full rather than from the time the Virtual
3586 Full was actually run.
3590 \subsection{Catalog Format}
3591 \index[general]{Catalog Format}
3592 Bacula 3.0 comes with some changes to the catalog format. The upgrade
3593 operation will convert the FileId field of the File table from 32 bits (max 4
3594 billion table entries) to 64 bits (very large number of items). The
3595 conversion process can take a bit of time and will likely DOUBLE THE SIZE of
3596 your catalog during the conversion. Also you won't be able to run jobs during
3597 this conversion period. For example, a 3 million file catalog will take 2
3598 minutes to upgrade on a normal machine. Please don't forget to make a valid
3599 backup of your database before executing the upgrade script. See the
3600 ReleaseNotes for additional details.
3602 \subsection{64 bit Windows Client}
3603 \index[general]{Win64 Client}
3604 Unfortunately, Microsoft's implementation of Volume Shadown Copy (VSS) on
3605 their 64 bit OS versions is not compatible with a 32 bit Bacula Client.
3606 As a consequence, we are also releasing a 64 bit version of the Bacula
3607 Windows Client (win64bacula-3.0.0.exe) that does work with VSS.
3608 These binaries should only be installed on 64 bit Windows operating systems.
3609 What is important is not your hardware but whether or not you have
3610 a 64 bit version of the Windows OS.
3612 Compared to the Win32 Bacula Client, the 64 bit release contains a few differences:
3614 \item Before installing the Win64 Bacula Client, you must totally
3615 deinstall any prior 2.4.x Client installation using the
3616 Bacula deinstallation (see the menu item). You may want
3617 to save your .conf files first.
3618 \item Only the Client (File daemon) is ported to Win64, the Director
3619 and the Storage daemon are not in the 64 bit Windows installer.
3620 \item bwx-console is not yet ported.
3621 \item bconsole is ported but it has not been tested.
3622 \item The documentation is not included in the installer.
3623 \item Due to Vista security restrictions imposed on a default installation
3624 of Vista, before upgrading the Client, you must manually stop
3625 any prior version of Bacula from running, otherwise the install
3627 \item Due to Vista security restrictions imposed on a default installation
3628 of Vista, attempting to edit the conf files via the menu items
3629 will fail. You must directly edit the files with appropriate
3630 permissions. Generally double clicking on the appropriate .conf
3631 file will work providing you have sufficient permissions.
3632 \item All Bacula files are now installed in
3633 {\bf C:/Program Files/Bacula} except the main menu items,
3634 which are installed as before. This vastly simplifies the installation.
3635 \item If you are running on a foreign language version of Windows, most
3636 likely {\bf C:/Program Files} does not exist, so you should use the
3637 Custom installation and enter an appropriate location to install
3639 \item The 3.0.0 Win32 Client continues to install files in the locations used
3640 by prior versions. For the next version we will convert it to use
3641 the same installation conventions as the Win64 version.
3644 This project was funded by Bacula Systems.
3647 \subsection{Duplicate Job Control}
3648 \index[general]{Duplicate Jobs}
3649 The new version of Bacula provides four new directives that
3650 give additional control over what Bacula does if duplicate jobs
3651 are started. A duplicate job in the sense we use it here means
3652 a second or subsequent job with the same name starts. This
3653 happens most frequently when the first job runs longer than expected because no
3654 tapes are available.
3656 The four directives each take as an argument a {\bf yes} or {\bf no} value and
3657 are specified in the Job resource.
3661 \subsubsection{Allow Duplicate Jobs = \lt{}yes\vb{}no\gt{}}
3662 \index[general]{Allow Duplicate Jobs}
3663 If this directive is set to {\bf yes}, duplicate jobs will be run. If
3664 the directive is set to {\bf no} (default) then only one job of a given name
3665 may run at one time, and the action that Bacula takes to ensure only
3666 one job runs is determined by the other directives (see below).
3668 If {\bf Allow Duplicate Jobs} is set to {\bf no} and two jobs
3669 are present and none of the three directives given below permit
3670 Canceling a job, then the current job (the second one started)
3673 \subsubsection{Allow Higher Duplicates = \lt{}yes\vb{}no\gt{}}
3674 \index[general]{Allow Higher Duplicates}
3675 This directive was in version 5.0.0, but does not work as
3676 expected. If used, it should always be set to no. In later versions
3677 of Bacula the directive is disabled (disregarded).
3679 \subsubsection{Cancel Running Duplicates = \lt{}yes\vb{}no\gt{}}
3680 \index[general]{Cancel Running Duplicates}
3681 If {\bf Allow Duplicate Jobs} is set to {\bf no} and
3682 if this directive is set to {\bf yes} any job that is already running
3683 will be canceled. The default is {\bf no}.
3685 \subsubsection{Cancel Queued Duplicates = \lt{}yes\vb{}no\gt{}}
3686 \index[general]{Cancel Queued Duplicates}
3687 If {\bf Allow Duplicate Jobs} is set to {\bf no} and
3688 if this directive is set to {\bf yes} any job that is
3689 already queued to run but not yet running will be canceled.
3690 The default is {\bf no}.
3693 \subsection{TLS Authentication}
3694 \index[general]{TLS Authentication}
3695 In Bacula version 2.5.x and later, in addition to the normal Bacula
3696 CRAM-MD5 authentication that is used to authenticate each Bacula
3697 connection, you can specify that you want TLS Authentication as well,
3698 which will provide more secure authentication.
3700 This new feature uses Bacula's existing TLS code (normally used for
3701 communications encryption) to do authentication. To use it, you must
3702 specify all the TLS directives normally used to enable communications
3703 encryption (TLS Enable, TLS Verify Peer, TLS Certificate, ...) and
3706 \subsubsection{TLS Authenticate = yes}
3708 TLS Authenticate = yes
3711 in the main daemon configuration resource (Director for the Director,
3712 Client for the File daemon, and Storage for the Storage daemon).
3714 When {\bf TLS Authenticate} is enabled, after doing the CRAM-MD5
3715 authentication, Bacula will also do TLS authentication, then TLS
3716 encryption will be turned off, and the rest of the communication between
3717 the two Bacula daemons will be done without encryption.
3719 If you want to encrypt communications data, use the normal TLS directives
3720 but do not turn on {\bf TLS Authenticate}.
3722 \subsection{bextract non-portable Win32 data}
3723 \index[general]{bextract handles Win32 non-portable data}
3724 {\bf bextract} has been enhanced to be able to restore
3725 non-portable Win32 data to any OS. Previous versions were
3726 unable to restore non-portable Win32 data to machines that
3727 did not have the Win32 BackupRead and BackupWrite API calls.
3729 \subsection{State File updated at Job Termination}
3730 \index[general]{State File}
3731 In previous versions of Bacula, the state file, which provides a
3732 summary of previous jobs run in the {\bf status} command output was
3733 updated only when Bacula terminated, thus if the daemon crashed, the
3734 state file might not contain all the run data. This version of
3735 the Bacula daemons updates the state file on each job termination.
3737 \subsection{MaxFullInterval = \lt{}time-interval\gt{}}
3738 \index[general]{MaxFullInterval}
3739 The new Job resource directive {\bf Max Full Interval = \lt{}time-interval\gt{}}
3740 can be used to specify the maximum time interval between {\bf Full} backup
3741 jobs. When a job starts, if the time since the last Full backup is
3742 greater than the specified interval, and the job would normally be an
3743 {\bf Incremental} or {\bf Differential}, it will be automatically
3744 upgraded to a {\bf Full} backup.
3746 \subsection{MaxDiffInterval = \lt{}time-interval\gt{}}
3747 \index[general]{MaxDiffInterval}
3748 The new Job resource directive {\bf Max Diff Interval = \lt{}time-interval\gt{}}
3749 can be used to specify the maximum time interval between {\bf Differential} backup
3750 jobs. When a job starts, if the time since the last Differential backup is
3751 greater than the specified interval, and the job would normally be an
3752 {\bf Incremental}, it will be automatically
3753 upgraded to a {\bf Differential} backup.
3755 \subsection{Honor No Dump Flag = \lt{}yes\vb{}no\gt{}}
3756 \index[general]{MaxDiffInterval}
3757 On FreeBSD systems, each file has a {\bf no dump flag} that can be set
3758 by the user, and when it is set it is an indication to backup programs
3759 to not backup that particular file. This version of Bacula contains a
3760 new Options directive within a FileSet resource, which instructs Bacula to
3761 obey this flag. The new directive is:
3764 Honor No Dump Flag = yes\vb{}no
3767 The default value is {\bf no}.
3770 \subsection{Exclude Dir Containing = \lt{}filename-string\gt{}}
3771 \index[general]{IgnoreDir}
3772 The {\bf ExcludeDirContaining = \lt{}filename\gt{}} is a new directive that
3773 can be added to the Include section of the FileSet resource. If the specified
3774 filename ({\bf filename-string}) is found on the Client in any directory to be
3775 backed up, the whole directory will be ignored (not backed up). For example:
3778 # List of files to be backed up
3786 Exclude Dir Containing = .excludeme
3791 But in /home, there may be hundreds of directories of users and some
3792 people want to indicate that they don't want to have certain
3793 directories backed up. For example, with the above FileSet, if
3794 the user or sysadmin creates a file named {\bf .excludeme} in
3795 specific directories, such as
3798 /home/user/www/cache/.excludeme
3799 /home/user/temp/.excludeme
3802 then Bacula will not backup the two directories named:
3805 /home/user/www/cache
3809 NOTE: subdirectories will not be backed up. That is, the directive
3810 applies to the two directories in question and any children (be they
3811 files, directories, etc).
3814 \subsection{Bacula Plugins}
3815 \index[general]{Plugin}
3816 Support for shared object plugins has been implemented in the Linux, Unix
3817 and Win32 File daemons. The API will be documented separately in
3818 the Developer's Guide or in a new document. For the moment, there is
3819 a single plugin named {\bf bpipe} that allows an external program to
3820 get control to backup and restore a file.
3822 Plugins are also planned (partially implemented) in the Director and the
3825 \subsubsection{Plugin Directory}
3826 \index[general]{Plugin Directory}
3827 Each daemon (DIR, FD, SD) has a new {\bf Plugin Directory} directive that may
3828 be added to the daemon definition resource. The directory takes a quoted
3829 string argument, which is the name of the directory in which the daemon can
3830 find the Bacula plugins. If this directive is not specified, Bacula will not
3831 load any plugins. Since each plugin has a distinctive name, all the daemons
3832 can share the same plugin directory.
3834 \subsubsection{Plugin Options}
3835 \index[general]{Plugin Options}
3836 The {\bf Plugin Options} directive takes a quoted string
3837 argument (after the equal sign) and may be specified in the
3838 Job resource. The options specified will be passed to all plugins
3839 when they are run. This each plugin must know what it is looking
3840 for. The value defined in the Job resource can be modified
3841 by the user when he runs a Job via the {\bf bconsole} command line
3844 Note: this directive may be specified, and there is code to modify
3845 the string in the run command, but the plugin options are not yet passed to
3846 the plugin (i.e. not fully implemented).
3848 \subsubsection{Plugin Options ACL}
3849 \index[general]{Plugin Options ACL}
3850 The {\bf Plugin Options ACL} directive may be specified in the
3851 Director's Console resource. It functions as all the other ACL commands
3852 do by permitting users running restricted consoles to specify a
3853 {\bf Plugin Options} that overrides the one specified in the Job
3854 definition. Without this directive restricted consoles may not modify
3857 \subsubsection{Plugin = \lt{}plugin-command-string\gt{}}
3858 \index[general]{Plugin}
3859 The {\bf Plugin} directive is specified in the Include section of
3860 a FileSet resource where you put your {\bf File = xxx} directives.
3871 Plugin = "bpipe:..."
3876 In the above example, when the File daemon is processing the directives
3877 in the Include section, it will first backup all the files in {\bf /home}
3878 then it will load the plugin named {\bf bpipe} (actually bpipe-dir.so) from
3879 the Plugin Directory. The syntax and semantics of the Plugin directive
3880 require the first part of the string up to the colon (:) to be the name
3881 of the plugin. Everything after the first colon is ignored by the File daemon but
3882 is passed to the plugin. Thus the plugin writer may define the meaning of the
3883 rest of the string as he wishes.
3885 Please see the next section for information about the {\bf bpipe} Bacula
3888 \subsection{The bpipe Plugin}
3889 \index[general]{The bpipe Plugin}
3890 The {\bf bpipe} plugin is provided in the directory src/plugins/fd/bpipe-fd.c of
3891 the Bacula source distribution. When the plugin is compiled and linking into
3892 the resulting dynamic shared object (DSO), it will have the name {\bf bpipe-fd.so}.
3893 Please note that this is a very simple plugin that was written for
3894 demonstration and test purposes. It is and can be used in production, but
3895 that was never really intended.
3897 The purpose of the plugin is to provide an interface to any system program for
3898 backup and restore. As specified above the {\bf bpipe} plugin is specified in
3899 the Include section of your Job's FileSet resource. The full syntax of the
3900 plugin directive as interpreted by the {\bf bpipe} plugin (each plugin is free
3901 to specify the sytax as it wishes) is:
3904 Plugin = "<field1>:<field2>:<field3>:<field4>"
3909 \item {\bf field1} is the name of the plugin with the trailing {\bf -fd.so}
3910 stripped off, so in this case, we would put {\bf bpipe} in this field.
3912 \item {\bf field2} specifies the namespace, which for {\bf bpipe} is the
3913 pseudo path and filename under which the backup will be saved. This pseudo
3914 path and filename will be seen by the user in the restore file tree.
3915 For example, if the value is {\bf /MYSQL/regress.sql}, the data
3916 backed up by the plugin will be put under that "pseudo" path and filename.
3917 You must be careful to choose a naming convention that is unique to avoid
3918 a conflict with a path and filename that actually exists on your system.
3920 \item {\bf field3} for the {\bf bpipe} plugin
3921 specifies the "reader" program that is called by the plugin during
3922 backup to read the data. {\bf bpipe} will call this program by doing a
3925 \item {\bf field4} for the {\bf bpipe} plugin
3926 specifies the "writer" program that is called by the plugin during
3927 restore to write the data back to the filesystem.
3930 Please note that for two items above describing the "reader" and "writer"
3931 fields, these programs are "executed" by Bacula, which
3932 means there is no shell interpretation of any command line arguments
3933 you might use. If you want to use shell characters (redirection of input
3934 or output, ...), then we recommend that you put your command or commands
3935 in a shell script and execute the script. In addition if you backup a
3936 file with the reader program, when running the writer program during
3937 the restore, Bacula will not automatically create the path to the file.
3938 Either the path must exist, or you must explicitly do so with your command
3939 or in a shell script.
3941 Putting it all together, the full plugin directive line might look
3945 Plugin = "bpipe:/MYSQL/regress.sql:mysqldump -f
3946 --opt --databases bacula:mysql"
3949 The directive has been split into two lines, but within the {\bf bacula-dir.conf} file
3950 would be written on a single line.
3952 This causes the File daemon to call the {\bf bpipe} plugin, which will write
3953 its data into the "pseudo" file {\bf /MYSQL/regress.sql} by calling the
3954 program {\bf mysqldump -f --opt --database bacula} to read the data during
3955 backup. The mysqldump command outputs all the data for the database named
3956 {\bf bacula}, which will be read by the plugin and stored in the backup.
3957 During restore, the data that was backed up will be sent to the program
3958 specified in the last field, which in this case is {\bf mysql}. When
3959 {\bf mysql} is called, it will read the data sent to it by the plugn
3960 then write it back to the same database from which it came ({\bf bacula}
3963 The {\bf bpipe} plugin is a generic pipe program, that simply transmits
3964 the data from a specified program to Bacula for backup, and then from Bacula to
3965 a specified program for restore.
3967 By using different command lines to {\bf bpipe},
3968 you can backup any kind of data (ASCII or binary) depending
3969 on the program called.
3971 \subsection{Microsoft Exchange Server 2003/2007 Plugin}
3972 \index[general]{Microsoft Exchange Server 2003/2007 Plugin}
3973 \subsubsection{Background}
3974 The Exchange plugin was made possible by a funded development project
3975 between Equiinet Ltd -- www.equiinet.com (many thanks) and Bacula Systems.
3976 The code for the plugin was written by James Harper, and the Bacula core
3977 code by Kern Sibbald. All the code for this funded development has become
3978 part of the Bacula project. Thanks to everyone who made it happen.
3980 \subsubsection{Concepts}
3981 Although it is possible to backup Exchange using Bacula VSS the Exchange
3982 plugin adds a good deal of functionality, because while Bacula VSS
3983 completes a full backup (snapshot) of Exchange, it does
3984 not support Incremental or Differential backups, restoring is more
3985 complicated, and a single database restore is not possible.
3987 Microsoft Exchange organises its storage into Storage Groups with
3988 Databases inside them. A default installation of Exchange will have a
3989 single Storage Group called 'First Storage Group', with two Databases
3990 inside it, "Mailbox Store (SERVER NAME)" and
3991 "Public Folder Store (SERVER NAME)",
3992 which hold user email and public folders respectively.
3994 In the default configuration, Exchange logs everything that happens to
3995 log files, such that if you have a backup, and all the log files since,
3996 you can restore to the present time. Each Storage Group has its own set
3997 of log files and operates independently of any other Storage Groups. At
3998 the Storage Group level, the logging can be turned off by enabling a
3999 function called "Enable circular logging". At this time the Exchange
4000 plugin will not function if this option is enabled.
4002 The plugin allows backing up of entire storage groups, and the restoring
4003 of entire storage groups or individual databases. Backing up and
4004 restoring at the individual mailbox or email item is not supported but
4005 can be simulated by use of the "Recovery" Storage Group (see below).
4007 \subsubsection{Installing}
4008 The Exchange plugin requires a DLL that is shipped with Microsoft
4009 Exchanger Server called {\bf esebcli2.dll}. Assuming Exchange is installed
4010 correctly the Exchange plugin should find this automatically and run
4011 without any additional installation.
4013 If the DLL can not be found automatically it will need to be copied into
4014 the Bacula installation
4015 directory (eg C:\verb+\+Program Files\verb+\+Bacula\verb+\+bin). The Exchange API DLL is
4016 named esebcli2.dll and is found in C:\verb+\+Program Files\verb+\+Exchsrvr\verb+\+bin on a
4017 default Exchange installation.
4019 \subsubsection{Backing Up}
4020 To back up an Exchange server the Fileset definition must contain at
4021 least {\bf Plugin = "exchange:/@EXCHANGE/Microsoft Information Store"} for
4022 the backup to work correctly. The 'exchange:' bit tells Bacula to look
4023 for the exchange plugin, the '@EXCHANGE' bit makes sure all the backed
4024 up files are prefixed with something that isn't going to share a name
4025 with something outside the plugin, and the 'Microsoft Information Store'
4026 bit is required also. It is also possible to add the name of a storage
4027 group to the "Plugin =" line, eg \\
4028 {\bf Plugin = "exchange:/@EXCHANGE/Microsoft Information Store/First Storage Group"} \\
4029 if you want only a single storage group backed up.
4031 Additionally, you can suffix the 'Plugin =' directive with
4032 ":notrunconfull" which will tell the plugin not to truncate the Exchange
4033 database at the end of a full backup.
4035 An Incremental or Differential backup will backup only the database logs
4036 for each Storage Group by inspecting the "modified date" on each
4037 physical log file. Because of the way the Exchange API works, the last
4038 logfile backed up on each backup will always be backed up by the next
4039 Incremental or Differential backup too. This adds 5MB to each
4040 Incremental or Differential backup size but otherwise does not cause any
4043 By default, a normal VSS fileset containing all the drive letters will
4044 also back up the Exchange databases using VSS. This will interfere with
4045 the plugin and Exchange's shared ideas of when the last full backup was
4046 done, and may also truncate log files incorrectly. It is important,
4047 therefore, that the Exchange database files be excluded from the backup,
4048 although the folders the files are in should be included, or they will
4049 have to be recreated manually if a bare metal restore is done.
4054 File = C:/Program Files/Exchsrvr/mdbdata
4055 Plugin = "exchange:..."
4058 File = C:/Program Files/Exchsrvr/mdbdata/E00.chk
4059 File = C:/Program Files/Exchsrvr/mdbdata/E00.log
4060 File = C:/Program Files/Exchsrvr/mdbdata/E000000F.log
4061 File = C:/Program Files/Exchsrvr/mdbdata/E0000010.log
4062 File = C:/Program Files/Exchsrvr/mdbdata/E0000011.log
4063 File = C:/Program Files/Exchsrvr/mdbdata/E00tmp.log
4064 File = C:/Program Files/Exchsrvr/mdbdata/priv1.edb
4069 The advantage of excluding the above files is that you can significantly
4070 reduce the size of your backup since all the important Exchange files
4071 will be properly saved by the Plugin.
4074 \subsubsection{Restoring}
4075 The restore operation is much the same as a normal Bacula restore, with
4076 the following provisos:
4079 \item The {\bf Where} restore option must not be specified
4080 \item Each Database directory must be marked as a whole. You cannot just
4081 select (say) the .edb file and not the others.
4082 \item If a Storage Group is restored, the directory of the Storage Group
4084 \item It is possible to restore only a subset of the available log files,
4085 but they {\bf must} be contiguous. Exchange will fail to restore correctly
4086 if a log file is missing from the sequence of log files
4087 \item Each database to be restored must be dismounted and marked as "Can be
4088 overwritten by restore"
4089 \item If an entire Storage Group is to be restored (eg all databases and
4090 logs in the Storage Group), then it is best to manually delete the
4091 database files from the server (eg C:\verb+\+Program Files\verb+\+Exchsrvr\verb+\+mdbdata\verb+\+*)
4092 as Exchange can get confused by stray log files lying around.
4095 \subsubsection{Restoring to the Recovery Storage Group}
4096 The concept of the Recovery Storage Group is well documented by
4098 \elink{http://support.microsoft.com/kb/824126}{http://support.microsoft.com/kb/824126},
4099 but to briefly summarize...
4101 Microsoft Exchange allows the creation of an additional Storage Group
4102 called the Recovery Storage Group, which is used to restore an older
4103 copy of a database (e.g. before a mailbox was deleted) into without
4104 messing with the current live data. This is required as the Standard and
4105 Small Business Server versions of Exchange can not ordinarily have more
4106 than one Storage Group.
4108 To create the Recovery Storage Group, drill down to the Server in Exchange
4109 System Manager, right click, and select
4110 {\bf "New -> Recovery Storage Group..."}. Accept or change the file
4111 locations and click OK. On the Recovery Storage Group, right click and
4112 select {\bf "Add Database to Recover..."} and select the database you will
4115 Restore only the single database nominated as the database in the
4116 Recovery Storage Group. Exchange will redirect the restore to the
4117 Recovery Storage Group automatically.
4118 Then run the restore.
4120 \subsubsection{Restoring on Microsoft Server 2007}
4121 Apparently the {\bf Exmerge} program no longer exists in Microsoft Server
4122 2007, and hence you use a new procedure for recovering a single mail box.
4123 This procedure is documented by Microsoft at:
4124 \elink{http://technet.microsoft.com/en-us/library/aa997694.aspx}{http://technet.microsoft.com/en-us/library/aa997694.aspx},
4125 and involves using the {\bf Restore-Mailbox} and {\bf
4126 Get-Mailbox Statistics} shell commands.
4128 \subsubsection{Caveats}
4129 This plugin is still being developed, so you should consider it
4130 currently in BETA test, and thus use in a production environment
4131 should be done only after very careful testing.
4133 When doing a full backup, the Exchange database logs are truncated by
4134 Exchange as soon as the plugin has completed the backup. If the data
4135 never makes it to the backup medium (eg because of spooling) then the
4136 logs will still be truncated, but they will also not have been backed
4137 up. A solution to this is being worked on. You will have to schedule a
4138 new Full backup to ensure that your next backups will be usable.
4140 The "Enable Circular Logging" option cannot be enabled or the plugin
4143 Exchange insists that a successful Full backup must have taken place if
4144 an Incremental or Differential backup is desired, and the plugin will
4145 fail if this is not the case. If a restore is done, Exchange will
4146 require that a Full backup be done before an Incremental or Differential
4149 The plugin will most likely not work well if another backup application
4150 (eg NTBACKUP) is backing up the Exchange database, especially if the
4151 other backup application is truncating the log files.
4153 The Exchange plugin has not been tested with the {\bf Accurate} option, so
4154 we recommend either carefully testing or that you avoid this option for
4157 The Exchange plugin is not called during processing the bconsole {\bf
4158 estimate} command, and so anything that would be backed up by the plugin
4159 will not be added to the estimate total that is displayed.
4162 \subsection{libdbi Framework}
4163 \index[general]{libdbi Framework}
4164 As a general guideline, Bacula has support for a few catalog database drivers
4165 (MySQL, PostgreSQL, SQLite)
4166 coded natively by the Bacula team. With the libdbi implementation, which is a
4167 Bacula driver that uses libdbi to access the catalog, we have an open field to
4168 use many different kinds database engines following the needs of users.
4170 The according to libdbi (http://libdbi.sourceforge.net/) project: libdbi
4171 implements a database-independent abstraction layer in C, similar to the
4172 DBI/DBD layer in Perl. Writing one generic set of code, programmers can
4173 leverage the power of multiple databases and multiple simultaneous database
4174 connections by using this framework.
4176 Currently the libdbi driver in Bacula project only supports the same drivers
4177 natively coded in Bacula. However the libdbi project has support for many
4178 others database engines. You can view the list at
4179 http://libdbi-drivers.sourceforge.net/. In the future all those drivers can be
4180 supported by Bacula, however, they must be tested properly by the Bacula team.
4182 Some of benefits of using libdbi are:
4184 \item The possibility to use proprietary databases engines in which your
4185 proprietary licenses prevent the Bacula team from developing the driver.
4186 \item The possibility to use the drivers written for the libdbi project.
4187 \item The possibility to use other database engines without recompiling Bacula
4188 to use them. Just change one line in bacula-dir.conf
4189 \item Abstract Database access, this is, unique point to code and profiling
4190 catalog database access.
4193 The following drivers have been tested:
4195 \item PostgreSQL, with and without batch insert
4196 \item Mysql, with and without batch insert
4201 In the future, we will test and approve to use others databases engines
4202 (proprietary or not) like DB2, Oracle, Microsoft SQL.
4204 To compile Bacula to support libdbi we need to configure the code with the
4205 --with-dbi and --with-dbi-driver=[database] ./configure options, where
4206 [database] is the database engine to be used with Bacula (of course we can
4207 change the driver in file bacula-dir.conf, see below). We must configure the
4208 access port of the database engine with the option --with-db-port, because the
4209 libdbi framework doesn't know the default access port of each database.
4211 The next phase is checking (or configuring) the bacula-dir.conf, example:
4215 dbdriver = dbi:mysql; dbaddress = 127.0.0.1; dbport = 3306
4216 dbname = regress; user = regress; password = ""
4220 The parameter {\bf dbdriver} indicates that we will use the driver dbi with a
4221 mysql database. Currently the drivers supported by Bacula are: postgresql,
4222 mysql, sqlite, sqlite3; these are the names that may be added to string "dbi:".
4224 The following limitations apply when Bacula is set to use the libdbi framework:
4225 - Not tested on the Win32 platform
4226 - A little performance is lost if comparing with native database driver.
4227 The reason is bound with the database driver provided by libdbi and the
4228 simple fact that one more layer of code was added.
4230 It is important to remember, when compiling Bacula with libdbi, the
4231 following packages are needed:
4233 \item libdbi version 1.0.0, http://libdbi.sourceforge.net/
4234 \item libdbi-drivers 1.0.0, http://libdbi-drivers.sourceforge.net/
4237 You can download them and compile them on your system or install the packages
4238 from your OS distribution.
4240 \subsection{Console Command Additions and Enhancements}
4241 \index[general]{Console Additions}
4243 \subsubsection{Display Autochanger Content}
4244 \index[general]{StatusSlots}
4246 The {\bf status slots storage=\lt{}storage-name\gt{}} command displays
4247 autochanger content.
4251 Slot | Volume Name | Status | Media Type | Pool |
4252 ------+---------------+----------+-------------------+------------|
4253 1 | 00001 | Append | DiskChangerMedia | Default |
4254 2 | 00002 | Append | DiskChangerMedia | Default |
4255 3*| 00003 | Append | DiskChangerMedia | Scratch |
4260 If you an asterisk ({\bf *}) appears after the slot number, you must run an
4261 {\bf update slots} command to synchronize autochanger content with your
4264 \subsubsection{list joblog job=xxx or jobid=nnn}
4265 \index[general]{list joblog}
4266 A new list command has been added that allows you to list the contents
4267 of the Job Log stored in the catalog for either a Job Name (fully qualified)
4268 or for a particular JobId. The {\bf llist} command will include a line with
4269 the time and date of the entry.
4271 Note for the catalog to have Job Log entries, you must have a directive
4278 In your Director's {\bf Messages} resource.
4280 \subsubsection{Use separator for multiple commands}
4281 \index[general]{Command Separator}
4282 When using bconsole with readline, you can set the command separator with
4283 \textbf{@separator} command to one
4284 of those characters to write commands who require multiple input in one line.
4286 !$%&'()*+,-/:;<>?[]^`{|}~
4289 \subsubsection{Deleting Volumes}
4290 The delete volume bconsole command has been modified to
4291 require an asterisk (*) in front of a MediaId otherwise the
4292 value you enter is a taken to be a Volume name. This is so that
4293 users may delete numeric Volume names. The previous Bacula versions
4294 assumed that all input that started with a number was a MediaId.
4296 This new behavior is indicated in the prompt if you read it
4299 \subsection{Bare Metal Recovery}
4300 The old bare metal recovery project is essentially dead. One
4301 of the main features of it was that it would build a recovery
4302 CD based on the kernel on your system. The problem was that
4303 every distribution has a different boot procedure and different
4304 scripts, and worse yet, the boot procedures and scripts change
4305 from one distribution to another. This meant that maintaining
4306 (keeping up with the changes) the rescue CD was too much work.
4308 To replace it, a new bare metal recovery USB boot stick has been developed
4309 by Bacula Systems. This technology involves remastering a Ubuntu LiveCD to
4310 boot from a USB key.
4314 \item Recovery can be done from within graphical environment.
4315 \item Recovery can be done in a shell.
4316 \item Ubuntu boots on a large number of Linux systems.
4317 \item The process of updating the system and adding new
4318 packages is not too difficult.
4319 \item The USB key can easily be upgraded to newer Ubuntu versions.
4320 \item The USB key has writable partitions for modifications to
4321 the OS and for modification to your home directory.
4322 \item You can add new files/directories to the USB key very easily.
4323 \item You can save the environment from multiple machines on
4325 \item Bacula Systems is funding its ongoing development.
4328 The disadvantages are:
4330 \item The USB key is usable but currently under development.
4331 \item Not everyone may be familiar with Ubuntu (no worse
4333 \item Some older OSes cannot be booted from USB. This can
4334 be resolved by first booting a Ubuntu LiveCD then plugging
4336 \item Currently the documentation is sketchy and not yet added
4337 to the main manual. See below ...
4340 The documentation and the code can be found in the {\bf rescue} package
4341 in the directory {\bf linux/usb}.
4343 \subsection{Miscellaneous}
4344 \index[general]{Misc New Features}
4346 \subsubsection{Allow Mixed Priority = \lt{}yes\vb{}no\gt{}}
4347 \index[general]{Allow Mixed Priority}
4348 This directive is only implemented in version 2.5 and later. When
4349 set to {\bf yes} (default {\bf no}), this job may run even if lower
4350 priority jobs are already running. This means a high priority job
4351 will not have to wait for other jobs to finish before starting.
4352 The scheduler will only mix priorities when all running jobs have
4355 Note that only higher priority jobs will start early. Suppose the
4356 director will allow two concurrent jobs, and that two jobs with
4357 priority 10 are running, with two more in the queue. If a job with
4358 priority 5 is added to the queue, it will be run as soon as one of
4359 the running jobs finishes. However, new priority 10 jobs will not
4360 be run until the priority 5 job has finished.
4362 \subsubsection{Bootstrap File Directive -- FileRegex}
4363 \index[general]{Bootstrap File Directive}
4364 {\bf FileRegex} is a new command that can be added to the bootstrap
4365 (.bsr) file. The value is a regular expression. When specified, only
4366 matching filenames will be restored.
4368 During a restore, if all File records are pruned from the catalog
4369 for a Job, normally Bacula can restore only all files saved. That
4370 is there is no way using the catalog to select individual files.
4371 With this new feature, Bacula will ask if you want to specify a Regex
4372 expression for extracting only a part of the full backup.
4375 Building directory tree for JobId(s) 1,3 ...
4376 There were no files inserted into the tree, so file selection
4377 is not possible.Most likely your retention policy pruned the files
4379 Do you want to restore all the files? (yes\vb{}no): no
4381 Regexp matching files to restore? (empty to abort): /tmp/regress/(bin|tests)/
4382 Bootstrap records written to /tmp/regress/working/zog4-dir.restore.1.bsr
4385 \subsubsection{Bootstrap File Optimization Changes}
4386 In order to permit proper seeking on disk files, we have extended the bootstrap
4387 file format to include a {\bf VolStartAddr} and {\bf VolEndAddr} records. Each
4388 takes a 64 bit unsigned integer range (i.e. nnn-mmm) which defines the start
4389 address range and end address range respectively. These two directives replace
4390 the {\bf VolStartFile}, {\bf VolEndFile}, {\bf VolStartBlock} and {\bf
4391 VolEndBlock} directives. Bootstrap files containing the old directives will
4392 still work, but will not properly take advantage of proper disk seeking, and
4393 may read completely to the end of a disk volume during a restore. With the new
4394 format (automatically generated by the new Director), restores will seek
4395 properly and stop reading the volume when all the files have been restored.
4397 \subsubsection{Solaris ZFS/NFSv4 ACLs}
4398 This is an upgrade of the previous Solaris ACL backup code
4399 to the new library format, which will backup both the old
4400 POSIX(UFS) ACLs as well as the ZFS ACLs.
4402 The new code can also restore POSIX(UFS) ACLs to a ZFS filesystem
4403 (it will translate the POSIX(UFS)) ACL into a ZFS/NFSv4 one) it can also
4404 be used to transfer from UFS to ZFS filesystems.
4407 \subsubsection{Virtual Tape Emulation}
4408 \index[general]{Virtual Tape Emulation}
4409 We now have a Virtual Tape emulator that allows us to run though 99.9\% of
4410 the tape code but actually reading and writing to a disk file. Used with the
4411 \textbf{disk-changer} script, you can now emulate an autochanger with 10 drives
4412 and 700 slots. This feature is most useful in testing. It is enabled
4413 by using {\bf Device Type = vtape} in the Storage daemon's Device
4414 directive. This feature is only implemented on Linux machines and should not be
4415 used for production.
4417 \subsubsection{Bat Enhancements}
4418 \index[general]{Bat Enhancements}
4419 Bat (the Bacula Administration Tool) GUI program has been significantly
4420 enhanced and stabilized. In particular, there are new table based status
4421 commands; it can now be easily localized using Qt4 Linguist.
4423 The Bat communications protocol has been significantly enhanced to improve
4424 GUI handling. Note, you {\bf must} use a the bat that is distributed with
4425 the Director you are using otherwise the communications protocol will not
4428 \subsubsection{RunScript Enhancements}
4429 \index[general]{RunScript Enhancements}
4430 The {\bf RunScript} resource has been enhanced to permit multiple
4431 commands per RunScript. Simply specify multiple {\bf Command} directives
4438 Command = "/bin/echo test"
4439 Command = "/bin/echo an other test"
4440 Command = "/bin/echo 3 commands in the same runscript"
4447 A new Client RunScript {\bf RunsWhen} keyword of {\bf AfterVSS} has been
4448 implemented, which runs the command after the Volume Shadow Copy has been made.
4450 Console commands can be specified within a RunScript by using:
4451 {\bf Console = \lt{}command\gt{}}, however, this command has not been
4452 carefully tested and debugged and is known to easily crash the Director.
4453 We would appreciate feedback. Due to the recursive nature of this command, we
4454 may remove it before the final release.
4456 \subsubsection{Status Enhancements}
4457 \index[general]{Status Enhancements}
4458 The bconsole {\bf status dir} output has been enhanced to indicate
4459 Storage daemon job spooling and despooling activity.
4461 \subsubsection{Connect Timeout}
4462 \index[general]{Connect Timeout}
4463 The default connect timeout to the File
4464 daemon has been set to 3 minutes. Previously it was 30 minutes.
4466 \subsubsection{ftruncate for NFS Volumes}
4467 \index[general]{ftruncate for NFS Volumes}
4468 If you write to a Volume mounted by NFS (say on a local file server),
4469 in previous Bacula versions, when the Volume was recycled, it was not
4470 properly truncated because NFS does not implement ftruncate (file
4471 truncate). This is now corrected in the new version because we have
4472 written code (actually a kind user) that deletes and recreates the Volume,
4473 thus accomplishing the same thing as a truncate.
4475 \subsubsection{Support for Ubuntu}
4476 The new version of Bacula now recognizes the Ubuntu (and Kubuntu)
4477 version of Linux, and thus now provides correct autostart routines.
4478 Since Ubuntu officially supports Bacula, you can also obtain any
4479 recent release of Bacula from the Ubuntu repositories.
4481 \subsubsection{Recycle Pool = \lt{}pool-name\gt{}}
4482 \index[general]{Recycle Pool}
4483 The new \textbf{RecyclePool} directive defines to which pool the Volume will
4484 be placed (moved) when it is recycled. Without this directive, a Volume will
4485 remain in the same pool when it is recycled. With this directive, it can be
4486 moved automatically to any existing pool during a recycle. This directive is
4487 probably most useful when defined in the Scratch pool, so that volumes will
4488 be recycled back into the Scratch pool.
4490 \subsubsection{FD Version}
4491 \index[general]{FD Version}
4492 The File daemon to Director protocol now includes a version
4493 number, which although there is no visible change for users,
4494 will help us in future versions automatically determine
4495 if a File daemon is not compatible.
4497 \subsubsection{Max Run Sched Time = \lt{}time-period-in-seconds\gt{}}
4498 \index[general]{Max Run Sched Time}
4499 The time specifies the maximum allowed time that a job may run, counted from
4500 when the job was scheduled. This can be useful to prevent jobs from running
4501 during working hours. We can see it like \texttt{Max Start Delay + Max Run
4504 \subsubsection{Max Wait Time = \lt{}time-period-in-seconds\gt{}}
4505 \index[general]{Max Wait Time}
4506 Previous \textbf{MaxWaitTime} directives aren't working as expected, instead
4507 of checking the maximum allowed time that a job may block for a resource,
4508 those directives worked like \textbf{MaxRunTime}. Some users are reporting to
4509 use \textbf{Incr/Diff/Full Max Wait Time} to control the maximum run time of
4510 their job depending on the level. Now, they have to use
4511 \textbf{Incr/Diff/Full Max Run Time}. \textbf{Incr/Diff/Full Max Wait Time}
4512 directives are now deprecated.
4514 \subsubsection{Incremental|Differential Max Wait Time = \lt{}time-period-in-seconds\gt{}}
4515 \index[general]{Incremental Max Wait Time}
4516 \index[general]{Differential Max Wait Time}
4518 These directives have been deprecated in favor of
4519 \texttt{Incremental|Differential Max Run Time}.
4521 \subsubsection{Max Run Time directives}
4522 \index[general]{Max Run Time directives}
4523 Using \textbf{Full/Diff/Incr Max Run Time}, it's now possible to specify the
4524 maximum allowed time that a job can run depending on the level.
4526 \addcontentsline{lof}{figure}{Job time control directives}
4528 \includegraphics[width=\linewidth]{different_time}
4531 \subsubsection{Statistics Enhancements}
4532 \index[general]{Statistics Enhancements}
4533 If you (or probably your boss) want to have statistics on your backups to
4534 provide some \textit{Service Level Agreement} indicators, you could use a few
4535 SQL queries on the Job table to report how many:
4539 \item jobs have been successful
4540 \item files have been backed up
4544 However, these statistics are accurate only if your job retention is greater
4545 than your statistics period. Ie, if jobs are purged from the catalog, you won't
4546 be able to use them.
4548 Now, you can use the \textbf{update stats [days=num]} console command to fill
4549 the JobHistory table with new Job records. If you want to be sure to take in
4550 account only \textbf{good jobs}, ie if one of your important job has failed but
4551 you have fixed the problem and restarted it on time, you probably want to
4552 delete the first \textit{bad} job record and keep only the successful one. For
4553 that simply let your staff do the job, and update JobHistory table after two or
4554 three days depending on your organization using the \textbf{[days=num]} option.
4556 These statistics records aren't used for restoring, but mainly for
4557 capacity planning, billings, etc.
4559 The Bweb interface provides a statistics module that can use this feature. You
4560 can also use tools like Talend or extract information by yourself.
4562 The \textbf{Statistics Retention = \lt{}time\gt{}} director directive defines
4563 the length of time that Bacula will keep statistics job records in the Catalog
4564 database after the Job End time. (In \texttt{JobHistory} table) When this time
4565 period expires, and if user runs \texttt{prune stats} command, Bacula will
4566 prune (remove) Job records that are older than the specified period.
4568 You can use the following Job resource in your nightly \textbf{BackupCatalog}
4569 job to maintain statistics.
4572 Name = BackupCatalog
4575 Console = "update stats days=3"
4576 Console = "prune stats yes"
4583 \subsubsection{ScratchPool = \lt{}pool-resource-name\gt{}}
4584 \index[general]{ScratchPool}
4585 This directive permits to specify a specific \textsl{Scratch} pool for the
4586 current pool. This is useful when using multiple storage sharing the same
4587 mediatype or when you want to dedicate volumes to a particular set of pool.
4589 \subsubsection{Enhanced Attribute Despooling}
4590 \index[general]{Attribute Despooling}
4591 If the storage daemon and the Director are on the same machine, the spool file
4592 that contains attributes is read directly by the Director instead of being
4593 transmitted across the network. That should reduce load and speedup insertion.
4595 \subsubsection{SpoolSize = \lt{}size-specification-in-bytes\gt{}}
4596 \index[general]{SpoolSize}
4597 A new Job directive permits to specify the spool size per job. This is used
4598 in advanced job tunning. {\bf SpoolSize={\it bytes}}
4600 \subsubsection{MaximumConsoleConnections = \lt{}number\gt{}}
4601 \index[general]{MaximumConsoleConnections}
4602 A new director directive permits to specify the maximum number of Console
4603 Connections that could run concurrently. The default is set to 20, but you may
4604 set it to a larger number.
4606 \subsubsection{VerId = \lt{}string\gt{}}
4607 \index[general]{VerId}
4608 A new director directive permits to specify a personnal identifier that will be
4609 displayed in the \texttt{version} command.
4611 \subsubsection{dbcheck enhancements}
4612 \index[general]{dbcheck enhancements}
4613 If you are using Mysql, dbcheck will now ask you if you want to create
4614 temporary indexes to speed up orphaned Path and Filename elimination.
4616 A new \texttt{-B} option allows you to print catalog information in a simple
4617 text based format. This is useful to backup it in a secure way.
4632 You can now specify the database connection port in the command line.
4634 \subsubsection{{-}{-}docdir configure option}
4635 \index[general]{{-}{-}docdir configure option}
4636 You can use {-}{-}docdir= on the ./configure command to
4637 specify the directory where you want Bacula to install the
4638 LICENSE, ReleaseNotes, ChangeLog, ... files. The default is
4639 {\bf /usr/share/doc/bacula}.
4641 \subsubsection{{-}{-}htmldir configure option}
4642 \index[general]{{-}{-}htmldir configure option}
4643 You can use {-}{-}htmldir= on the ./configure command to
4644 specify the directory where you want Bacula to install the bat html help
4645 files. The default is {\bf /usr/share/doc/bacula/html}
4647 \subsubsection{{-}{-}with-plugindir configure option}
4648 \index[general]{{-}{-}plugindir configure option}
4649 You can use {-}{-}plugindir= on the ./configure command to
4650 specify the directory where you want Bacula to install
4651 the plugins (currently only bpipe-fd). The default is