]> git.sur5r.net Git - bacula/bacula/blob - bacula/src/dird/bacula-dir.conf.in
Kern had a better idea:
[bacula/bacula] / bacula / src / dird / bacula-dir.conf.in
1 #
2 # Default Bacula Director Configuration file
3 #
4 #  The only thing that MUST be changed is to add one or more
5 #   file or directory names in the Include directive of the
6 #   FileSet resource.
7 #
8 #  For Bacula release @VERSION@ (@DATE@) -- @DISTNAME@ @DISTVER@
9 #
10 #  You might also want to change the default email address
11 #   from root to your address.  See the "mail" and "operator"
12 #   directives in the Messages resource.
13 #
14
15 Director {                            # define myself
16   Name = @hostname@-dir
17   DIRport = @dir_port@                # where we listen for UA connections
18   QueryFile = "@scriptdir@/query.sql"
19   WorkingDirectory = "@working_dir@"
20   PidDirectory = "@piddir@"
21   Maximum Concurrent Jobs = 1
22   Password = "@dir_password@"         # Console password
23   Messages = Standard
24 }
25
26 JobDefs {
27   Name = "DefaultJob"
28   Type = Backup
29   Level = Incremental
30   Client = @hostname@-fd 
31   FileSet = "Full Set"
32   Schedule = "WeeklyCycle"
33   Storage = File
34   Messages = Standard
35   Pool = Default
36   Priority = 10
37 }
38
39
40 #
41 # Define the main nightly save backup job
42 #   By default, this job will back up to disk in /tmp
43 Job {
44   Name = "Client1"
45   JobDefs = "DefaultJob"
46   Write Bootstrap = "@working_dir@/Client1.bsr"
47 }
48
49 # Backup the catalog database (after the nightly save)
50 Job {
51   Name = "BackupCatalog"
52   JobDefs = "DefaultJob"
53   Level = Full
54   FileSet="Catalog"
55   Schedule = "WeeklyCycleAfterBackup"
56   # This creates an ASCII copy of the catalog
57   RunBeforeJob = "@scriptdir@/make_catalog_backup bacula bacula"
58   # This deletes the copy of the catalog
59   RunAfterJob  = "@scriptdir@/delete_catalog_backup"
60   Write Bootstrap = "@working_dir@/BackupCatalog.bsr"
61   Priority = 11                   # run after main backup
62 }
63
64 # Standard Restore template, to be changed by Console program
65 Job {
66   Name = "RestoreFiles"
67   Type = Restore
68   Client=@hostname@-fd                 
69   FileSet="Full Set"                  
70   Storage = File                      
71   Pool = Default
72   Messages = Standard
73   Where = /tmp/bacula-restores
74 }
75
76
77 # List of files to be backed up
78 FileSet {
79   Name = "Full Set"
80   Include {
81     Options {
82       signature = MD5
83     }
84 #    
85 #  Put your list of files here, preceded by 'File =', one per line
86 #    or include an external list with:
87 #
88 #    File = <file-name
89 #
90 #  Note: / backs up everything on the root partition.
91 #    if you have other partitons such as /usr or /home
92 #    you will probably want to add them too.
93 #
94 #  By default this is defined to point to the Bacula build
95 #    directory to give a reasonable FileSet to backup to
96 #    disk storage during initial testing.
97 #
98     File = @BUILD_DIR@
99   }
100
101 #
102 # If you backup the root directory, the following two excluded
103 #   files can be useful
104 #
105   Exclude {
106     File = /proc
107     File = /tmp
108     File = /.journal
109     File = /.fsck
110   }
111 }
112
113 #
114 # When to do the backups, full backup on first sunday of the month,
115 #  differential (i.e. incremental since full) every other sunday,
116 #  and incremental backups other days
117 Schedule {
118   Name = "WeeklyCycle"
119   Run = Full 1st sun at 1:05
120   Run = Differential 2nd-5th sun at 1:05
121   Run = Incremental mon-sat at 1:05
122 }
123
124 # This schedule does the catalog. It starts after the WeeklyCycle
125 Schedule {
126   Name = "WeeklyCycleAfterBackup"
127   Run = Full sun-sat at 1:10
128 }
129
130 # This is the backup of the catalog
131 FileSet {
132   Name = "Catalog"
133   Include {
134     Options {
135       signature = MD5
136     }
137     File = @working_dir@/bacula.sql
138   }
139 }
140
141 # Client (File Services) to backup
142 Client {
143   Name = @hostname@-fd
144   Address = @hostname@
145   FDPort = @fd_port@
146   Catalog = MyCatalog
147   Password = "@fd_password@"          # password for FileDaemon
148   File Retention = 30 days            # 30 days
149   Job Retention = 6 months            # six months
150   AutoPrune = yes                     # Prune expired Jobs/Files
151 }
152
153 # Definiton of file storage device
154 Storage {
155   Name = File
156 # Do not use "localhost" here    
157   Address = @hostname@                # N.B. Use a fully qualified name here
158   SDPort = @sd_port@
159   Password = "@sd_password@"
160   Device = FileStorage
161   Media Type = File
162 }
163
164
165 # Definition of DDS tape storage device
166 #Storage {
167 #  Name = DDS-4    
168 #  Do not use "localhost" here
169 #  Address = @hostname@                # N.B. Use a fully qualified name here
170 #  SDPort = @sd_port@
171 #  Password = "@sd_password@"          # password for Storage daemon
172 #  Device = DDS-4                      # must be same as Device in Storage daemon
173 #  Media Type = DDS-4                  # must be same as MediaType in Storage daemon
174 #}
175
176 # Definition of 8mm tape storage device
177 #Storage {
178 #  Name = "8mmDrive"
179 #  Do not use "localhost" here
180 #  Address = @hostname@                # N.B. Use a fully qualified name here
181 #  SDPort = @sd_port@
182 #  Password = "@sd_password@"
183 #  Device = "Exabyte 8mm"
184 #  MediaType = "8mm"
185 #}
186
187
188 # Generic catalog service
189 Catalog {
190   Name = MyCatalog
191   dbname = bacula; user = bacula; password = ""
192 }
193
194 # Reasonable message delivery -- send most everything to email address
195 #  and to the console
196 Messages {
197   Name = Standard
198 #
199 # NOTE! If you send to two email or more email addresses, you will need
200 #  to replace the %r in the from field (-f part) with a single valid
201 #  email address in both the mailcommand and the operatorcommand.
202 #
203   mailcommand = "@sbindir@/bsmtp -h @smtp_host@ -f \"\(Bacula\) %r\" -s \"Bacula: %t %e of %c %l\" %r"
204   operatorcommand = "@sbindir@/bsmtp -h @smtp_host@ -f \"\(Bacula\) %r\" -s \"Bacula: Intervention needed for %j\" %r"
205   mail = @job_email@ = all, !skipped            
206   operator = @job_email@ = mount
207   console = all, !skipped, !saved
208 #
209 # WARNING! the following will create a file that you must cycle from
210 #          time to time as it will grow indefinitely. However, it will
211 #          also keep all your messages if they scroll off the console.
212 #
213   append = "@working_dir@/log" = all, !skipped
214 }
215     
216 # Default pool definition
217 Pool {
218   Name = Default
219   Pool Type = Backup
220   Recycle = yes                       # Bacula can automatically recycle Volumes
221   AutoPrune = yes                     # Prune expired volumes
222   Volume Retention = 365 days         # one year
223   Accept Any Volume = yes             # write on any volume in the pool
224 }
225
226 #
227 # Restricted console used by tray-monitor to get the status of the director
228 #
229 Console {
230   Name = @hostname@-mon
231   Password = "@mon_dir_password@"
232   CommandACL = status, .status
233 }