Download THE DATA CENTER

Transcript
Label Format = Bkup-Full
}
Pool {
Name = Diffs
Pool Type = Backup
Recycle = yes
AutoPrune = yes
Volume Retention = 23 hours
Maximum Volumes = 1
Label Format = Bkup-Diff
}
Pool {
Name = Monthly
Pool Type = Backup
Recycle = yes
AutoPrune = yes
Volume Retention = 364 days
Maximum Volumes = 12
Label Format = Bkup-Monthly
}
Running a backup is quite simple, as
you already have done most of the
work by editing the bacula-dir.conf file.
up and running. You can change these passwords later if
desired. Change any other password-related fields in the following files to the common password as well: bacula-sd.conf,
bacula-fd.conf, bconsole.conf, gnome-console.conf and
tray-monitor.conf. After changing the passwords, you also need
to change any references to your host in all the .conf files, so
each dæmon can communicate with each other. If all of the
dæmons run locally, you can use localhost. You also could use
an FQDN or IP address. The field you want to edit is listed under
each section as Address. So, for example, change the line:
Address = server.example.com
to:
Address = localhost
Although it may seem odd to start at the bottom and disYou also could search for the client.example.com and
cuss the Pool section, it is vital that it is configured correctly. A
storage.example.com entries to find some of the other entries
pool is simply a collection of volumes. Volumes are tapes or
that need to be changed. Once the passwords and Address
disks to which the backup files are written. A pool can contain
fields have been set, open the /etc/bacula/bacula-sd.conf file
any number of volumes, but it must have at least one volume.
in your editor, and comment the following line in the Device
Here, we have set up three pools: a weekly full, a differential
section of the Filestorage device:
and a monthly. This allows us to maintain backups for the
current week up until the previous day and a 12-month
Archive Device = /tmp
rotation for our monthly backups.
Then, going from the top section down, there is a Job
Then, add the line below in its place to associate the locally
Definitions (JobDefs) section, and two Jobs modeled around
mounted FreeNAS partition with the storage dæmon so you
our backup strategy. The JobDefs section defines
common properties that several jobs share, like a
template. In it, we have listed settings common to
both jobs. The Schedule section defines when a
given job runs and how often. The schedules listed
here run weekly backups every Sunday, daily differentials Monday through Friday and a monthly backup the first Saturday of every month. The Fileset section lists what folders and files to back up and with
what options. For this example, we have set Bacula
to back up the local users’ home folders, a common
scenario for backups. Recursion is enabled by default
on FileSets, so we need to specify only the parent
folder. The backup files also are set to compress
using gzip and to hash/encrypt themselves using
MD5. Doing both is good practice.
Before saving and closing the file, go through and
change any instance of @@Password@@ or like
entries to a common password. Rather than cover
how each Bacula dæmon authenticates with the
other, it’s easier simply to change all of them to the
same password for the time being and get the system
Figure 5. Start all three Bacula dæmons, and set them to runlevel 5.
w w w. l i n u x j o u r n a l . c o m april 2008 | 73