2. What is bacula?
AGPL v3.0
Initial release : Jan 2000
Last release 9.4
C & C++
First release to SourceForge : April 14, 2002
Foreked from Bacula: Bareos
OS supports: Linux, Unix, Mac and Windows
5. DIR
Bacula DIR
FD
SD Disk/Tape
Catalog
Text Console
Web Console
Graphic Console
Software that controls the backup and restore operations that are performed by the File and Storage daemons
6. Catalog
DIR
FD
SD Disk/TapeText Console
Web Console
Graphic Console Catalog
Services that maintain a database of files that are backed up. The database is stored in an SQL database such as MySQL or PostgreSQL
10. Bacula SD (Storage daemon)
DIR
FD
Disk/Tape
Catalog
Text Console
Web Console
Graphic Console
SD
Software that performs reads and writes on the storage devices used for backups
23. Bacula plugins
LDAP and AD plugin
Docker plugin (Container configuration, volumes, images)
Bare Metal backup and recovery
Snapshot
CDP
Exchange Backup Software for Server 2016, 2013 and 2010
KVM
XEN
Proxmox
Redhat virtualization
VMware
HyperV
Azure
AWS
Google Oracle
MySQL
Postgres
MSSQL
24. Snapshot
A Snapshot is a view of a data set frozen at a point in time which allows
applications to continue writing their data.
Bacula offers snapshot support across
a wide range of operating systems and environments,
including of course Windows,
Unix and
Linux platforms.
The following snapshot-capable file systems and
logical volume managers are now supported with
Bacula Enterprise 8.2
ZFS
BTRFS
LVM
25. CDP
Continuous Data Protection (CDP) also called continuous backup or real-time backup,
refers to backup of Client data by automatically saving a copy of every change made
to that data,
essentially capturing every version of the data that the user saves.
●
Transaction record preservation, where corrupt files are replaced with earlier and clean versions
●
Efficient data recovery
●
Easy installation and programming, which does not affect stored data
26. CDP
The user application (cdp-client or tray-monitor) is responsible to monitor files and directories.
When a modification is detected, a copy of the new data is done into a spool directory.
At a regular interval, a Bacula backup job will contact the FileDaemon and will save
all the files archived by the cdp-client.
The local data can be restored at any time without a network connection to the Director.
33. Configuration
DIR
Director { # define myself
Name = bacula-dir
DIRport = 9101 # listen for UA connections
QueryFile = "/etc/bacula/query.sql"
WorkingDirectory = "/var/spool/bacula"
PidDirectory = "/var/run"
Maximum Concurrent Jobs = 1
Password = "@@DIR_PASSWORD@@" # Console passw
Messages = Daemon
DirAddress = 127.0.0.1
}
/etc/bacula/bacula-dir.conf
34. Configuration
DIR
JobDefs {
Name = "DefaultJob"
Type = Backup
Level = Incremental
Client = bacula-fd
FileSet = "Full Set"
Schedule = "WeeklyCycle"
Storage = File
Messages = Standard
Pool = File
Priority = 10
Write Bootstrap = "/var/bacula/bacula_full.bsr"
}
/etc/bacula/bacula-dir.conf
35. Configuration
DIR
Job {
Name = "BackupCatalog"
Type = Backup
JobDefs = "DefaultJob"
Level = Full
FileSet="Catalog"
Messages = Standard
Priority = 10
Storage = "Drive 2"
Schedule = "WeeklyCycleAfterBackup"
RunBeforeJob = "/scripts/my_script_Before.sh"
Write Bootstrap = "/var/bacula/bacula_full.bsr"
RunAfterJob = "/scripts/my_script_Before.sh"
Priority = 11 # run after main backup
/etc/bacula/bacula-dir.conf
36. Configuration
DIR
Job {
Name = "RestoreFiles"
Type = Restore
Client=bacula-fd
FileSet="Full Set"
Storage = File
Pool = Default
Messages = Standard
Where = /var/bacula/restore
}
/etc/bacula/bacula-dir.conf
38. Configuration
DIR
Schedule {
Name = "WeeklyCycle"
Run = Full 1st sun at 23:05
Run = Differential 2nd-5th sun at 23:05
Run = Incremental mon-sat at 23:05
}
Schedule {
Name = "WeeklyCycleAfterBackup"
Run = Full sun-sat at 23:10
}
/etc/bacula/bacula-dir.conf
39. Configuration
DIR
# Client (File Services) to backup
Client {
Name = bacula-fd
Address = localhost
FDPort = 9102
Catalog = MyCatalog
Password = "@@FD_PASSWORD@@" # password for FileDaemon
File Retention = 30 days
Job Retention = 6 months
AutoPrune = yes # Prune expired Jobs/Files
}
/etc/bacula/bacula-dir.conf
40. Configuration
DIR
/etc/bacula/bacula-dir.conf
# Definition of file storage device
Storage {
Name = File
# Do not use "localhost" here
Address = firstStorage.local # N.B. Use a fully qualified name
SDPort = 9103
Password = "@@SD_PASSWORD@@"
Device = FileStorage
Media Type = File
}
41. Configuration
DIR
/etc/bacula/bacula-dir.conf
# Definition of DDS tape storage device
Storage {
Name = DDS-4
# Do not use "localhost" here
# N.B. Use a fully qualified name here
Address = firstTape.local
SDPort = 9103
# password for Storage daemon
Password = "@@SD_PASSWORD@@"
# must be same as Device in Storage daemon
Device = DDS-4
# must be same as MediaType in Storage daemon
Media Type = DDS-4
# enable for autochanger device
Autochanger = yes
}
42. Configuration
DIR
/etc/bacula/bacula-dir.conf
# Definition of DVD storage device
Storage {
Name = "DVD"
# Do not use "localhost" here
# N.B. Use a fully qualified name here
Address = localhost
SDPort = 9103
Password = "@@SD_PASSWORD@@"
Device = "DVD Writer"
MediaType = "DVD"
}
43. Configuration
DIR
/etc/bacula/bacula-dir.conf
Catalog {
Name = MyCatalog
# Uncomment the following line if you want the dbi driver
dbdriver = "dbi:postgresql"; dbaddress = 127.0.0.1; dbport = 5432
dbname = "bacula"; dbuser = "bacula"; dbpassword = "Password"
}
44. Configuration
DIR
/etc/bacula/bacula-dir.conf
Messages {
Name = Standard
mailcommand = "/usr/sbin/bsmtp -h localhost
-f "(Bacula) <%r>"
-s "Bacula: %t %e of %c %l" %r"
operatorcommand = "/usr/sbin/bsmtp -h localhost
-f "(Bacula) <%r>"
-s "Bacula: Intervention needed for %j" %r"
mail = root@localhost = all, !skipped
operator = root@localhost = mount
console = all, !skipped, !saved
append = "/var/log/bacula/bacula.log" = all, !skipped
catalog = all
}
45. Configuration
SD
/etc/bacula/bacula-sd.conf
Device {
Name = FileStorage
Media Type = File
Archive Device = /backup
LabelMedia = yes; # lets Bacula label unlabeled media
Random Access = Yes;
AutomaticMount = yes; # when device opened, read it
RemovableMedia = no;
AlwaysOpen = no;
}