# # Default Bacula Director Configuration file # # The only thing that MUST be changed is to add one or more # file or directory names in the Include directive of the # FileSet resource. # # For Bacula release 7.0.6 (21 November 2014) -- debian 8.2 # # You might also want to change the default email address # from root to your address. See the "mail" and "operator" # directives in the Messages resource. # # primary documentation: # http://www.bacula.org/5.2.x-manuals/en/main/main/Customizing_Configuration_F.html#SECTION001320000000000000000 # A semicolon (;) is a logical end of line, and anything after the semicolon is # considered as the next statement. If a statement appears on a line by itself, # a semicolon is not necessary to terminate it, # # Case (upper/lower) and spaces are totally ignored in the resource directive # keywords (the part before the equal sign). Director { # define myself Name = bonnet-dir DIRport = 9101 # where we listen for UA connections QueryFile = "/usr/local/bacula/bin/query.sql" WorkingDirectory = "/usr/local/bacula/bin/working" PidDirectory = "/usr/local/bacula/bin/working" Maximum Concurrent Jobs = 20 Password = "suppressed" # Console password Messages = Daemon } JobDefs { Name = "DefaultJob" Type = Backup Level = Incremental Storage = FreeNASMini Messages = Standard SpoolAttributes = yes Priority = 10 Write Bootstrap = "/usr/local/bacula/bin/working/%c.bsr" } # # Define the main nightly save backup job Job { Name = "BackupClient1" Client = bonnet-fd FileSet = "Full Set" # overridden in Schedule Pool = BonnetMonthly Schedule = "DesktopCycle" JobDefs = "DefaultJob" } #http://www.bacula.org/7.0.x-manuals/en/main/Brief_Tutorial.html#SECTION001380000000000000000 #Adding a Second Client #To make this a real production installation, you will possibly want #to use different Pool, or a different schedule. It is up to you to #customize. In any case, you should change the password in both the #Director's file and the Client's file for additional security. Job { Name = "BackupLaptop" Client = hildesheim-fd FileSet = "Laptop Set" # overridden in Schedule Pool = LaptopMonthly Schedule = "LaptopCycle" JobDefs = "DefaultJob" } # Backup the catalog database (after the nightly save) Job { Name = "BackupCatalog" Client = bonnet-fd JobDefs = "DefaultJob" Level = Full Pool = BonnetMonthly FileSet="Catalog" Schedule = "WeeklyCycleAfterBackup" # This creates an ASCII copy of the catalog # Arguments to make_catalog_backup.pl are: # make_catalog_backup.pl RunBeforeJob = "/usr/local/bacula/bin/make_catalog_backup.pl MyCatalog" # This deletes the copy of the catalog RunAfterJob = "/usr/local/bacula/bin/delete_catalog_backup" Write Bootstrap = "/usr/local/bacula/bin/working/%n.bsr" Priority = 11 # run after main backup RunScript { RunsWhen = After RunsOnFailure = no # Command = "ssh -i /usr/local/bacula/.ssh/Bacula_key bootstrapbackup@beastie '/mnt/minivol/alison/bin/backup_bootstraps.sh'" Command = "cp /usr/local/bacula/bin/working/bonnet-fd.bsr /tmp" Command = "cp /usr/local/bacula/bin/working/hildesheim-fd.bsr /tmp" Command = "cp /usr/local/bacula/bin/working/BackupCatalog.bsr /tmp" Command = "scp -p -i /usr/local/bacula/.ssh/Bacula_key /tmp/bonnet-fd.bsr bootstrapbackup@beastie:/mnt/minivol/bootstrapbackup" Command = "scp -p -i /usr/local/bacula/.ssh/Bacula_key /tmp/hildesheim-fd.bsr bootstrapbackup@beastie:/mnt/minivol/bootstrapbackup" Command = "scp -p -i /usr/local/bacula/.ssh/Bacula_key /tmp/BackupCatalog.bsr bootstrapbackup@beastie:/mnt/minivol/bootstrapbackup" Command = "rm /tmp/bonnet-fd.bsr" Command = "rm /tmp/hildesheim-fd.bsr" Command = "rm /tmp/BackupCatalog.bsr" } } # # Standard Restore template, to be changed by Console program # Only one such job is needed for all Jobs/Clients/Storage ... # # Does not need a Storage Daemon on the host which runs the Console. # Only one SD is needed, on the NAS. # # If Where is not specified or is set to backslash (/), the files will be # restored to their original location. By default, we have set Where in the # example configuration files to be /tmp/bacula-restores. This is to prevent # accidental overwriting of your files. Job { Name = "RestoreFiles" Type = Restore Client = bonnet-fd Storage = FreeNASMini # The FileSet and Pool resources for Restore jobs are not used, but required to be present. FileSet = "Full Set" Pool = BonnetMonthly Messages = Standard Where = /vol/bacula-restores Priority = 6 } Job { Name = "RestoreLaptopFiles" Type = Restore Client = hildesheim-fd Storage = FreeNASMini # The FileSet and Pool resources for Restore jobs are not used, but required to be present. FileSet = "Full Set" Pool = LaptopMonthly Messages = Standard Where = /vol/bacula-restores Priority = 6 } # List of files to be backed up FileSet { Name = "Full Set" Include { Options { signature = MD5 compression = GZIP } # # Put your list of files here, preceded by 'File =', one per line # or include an external list with: # # File = \" -s \"Bacula: %t %e of %c %l\" %r" operatorcommand = "/usr/local/bacula/bin/bsmtp -h localhost -f \"\(Bacula\) \<%r\>\" -s \"Bacula: Intervention needed for %j\" %r" mail = root = all, !skipped operator = root = mount console = all, !skipped, !saved # # WARNING! the following will create a file that you must cycle from # time to time as it will grow indefinitely. However, it will # also keep all your messages if they scroll off the console. # append = "/var/log/bacula/bacula.log" = all, !skipped catalog = all } # # Message delivery for daemon messages (no job). Messages { Name = Daemon mailcommand = "/usr/local/bacula/bin/bsmtp -h localhost -f \"\(Bacula\) \<%r\>\" -s \"Bacula daemon message\" %r" mail = root = all, !skipped console = all, !skipped, !saved append = "/var/log/bacula/bacula.log" = all, !skipped } Pool { Name = BonnetMonthly Pool Type = Backup Recycle = yes # Bacula can automatically recycle Volumes AutoPrune = yes # Prune expired volumes Volume Retention = 365 days # one year Maximum Volume Bytes = 10G # Limit Volume size to something reasonable Maximum Volumes = 12 # Limit number of Volumes in Pool Label Format = "BonnetMonthly-" # Auto label } Pool { Name = BonnetWeekly Pool Type = Backup Recycle = yes # Bacula can automatically recycle Volumes AutoPrune = yes # Prune expired volumes Volume Retention = 31 days # one month Maximum Volume Bytes = 10G # Limit Volume size to something reasonable Maximum Volumes = 5 # Limit number of Volumes in Pool Label Format = "BonnetWeekly-" # Auto label } Pool { Name = BonnetDaily Pool Type = Backup Recycle = yes # Bacula can automatically recycle Volumes AutoPrune = yes # Prune expired volumes Volume Retention = 7 days # one month Maximum Volume Bytes = 10G # Limit Volume size to something reasonable Maximum Volumes = 14 # Limit number of Volumes in Pool Label Format = "BonnetDaily-" # Auto label } Pool { Name = LaptopMonthly Pool Type = Backup Recycle = yes # Bacula can automatically recycle Volumes AutoPrune = yes # Prune expired volumes Volume Retention = 365 days # one year Maximum Volume Bytes = 10G # Limit Volume size to something reasonable Maximum Volumes = 12 # Limit number of Volumes in Pool Label Format = "LaptopMonthly-" # Auto label } Pool { Name = LaptopWeekly Pool Type = Backup Recycle = yes # Bacula can automatically recycle Volumes AutoPrune = yes # Prune expired volumes Volume Retention = 31 days # one year Maximum Volume Bytes = 10G # Limit Volume size to something reasonable Maximum Volumes = 5 # Limit number of Volumes in Pool Label Format = "LaptopWeekly-" # Auto label } Pool { Name = LaptopDaily Pool Type = Backup Recycle = yes # Bacula can automatically recycle Volumes AutoPrune = yes # Prune expired volumes Volume Retention = 7 days # one year Maximum Volume Bytes = 10G # Limit Volume size to something reasonable Maximum Volumes = 14 # Limit number of Volumes in Pool Label Format = "LaptopDaily-" # Auto label } # NOT NEEDED. Use the one pool for both backup and restore jobs. # For backup, it's the sink; for restore, the source. # File Pool definition #Pool { # Name = RestoreVol # Pool Type = Backup # Recycle = yes # Bacula can automatically recycle Volumes # AutoPrune = yes # Prune expired volumes # Volume Retention = 365 days # one year # Maximum Volume Bytes = 50G # Limit Volume size to something reasonable # Maximum Volumes = 1 # Limit number of Volumes in Pool # Label Format = "Restore-" # Auto label #} # # Restricted console used by tray-monitor to get the status of the director # Console { Name = bonnet-mon # matches Director in bacula-fd.conf on bonnet, plus bacula-dir.conf in bacula jail at # /mnt/minivol/jails/bacula-sd_1/usr/local/etc/bacula/bacula-sd.conf Password = "suppressed" CommandACL = status, .status }