1# 2# Default Bareos 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# You might also want to change the default email address 9# from root to your address. See the "mail" and "operator" 10# directives in the Messages resource. 11# 12 13Director { # define myself 14 Name = @hostname@-dir 15 DIRPort = @dirport@ # where we listen for UA connections 16 QueryFile = "@scriptdir@/query.sql" 17 WorkingDirectory = "@working_dir@" 18 PidDirectory = "@piddir@" 19 Maximum Concurrent Jobs = 10 20 Password = "pNvX1WiXnwv2C/F7E52LGvw6rKjbbPvu2kyuPa9pVaL3" # Console password 21 Messages = Daemon 22} 23 24# 25# Define the main nightly save backup job 26# By default, this job will back up to disk in @tmpdir@ 27Job { 28 Name = "NightlySave" 29 Type = Backup 30 Client=@hostname@-fd 31 FileSet="Full Set" 32 Storage = File 33 Messages = Standard 34 Pool = Default 35 Write Bootstrap = "@working_dir@/NightlySave.bsr" 36 Maximum Concurrent Jobs = 10 37} 38 39Job { 40 Name = @hostname1@ 41 Type = Backup 42 Client = @hostname1@-fd 43 FileSet = "@hostname1@-FileSet" 44 Storage = File 45 Messages = Standard 46 Pool = Default 47 Write Bootstrap = "@working_dir@/NightlySave.bsr" 48 Maximum Concurrent Jobs = 10 49} 50 51Job { 52 Name = @hostname2@ 53 Type = Backup 54 Client = @hostname2@-fd 55 FileSet = "@hostname2@-FileSet" 56 Storage = File 57 Messages = Standard 58 Pool = Default 59 Write Bootstrap = "@working_dir@/NightlySave.bsr" 60 Maximum Concurrent Jobs = 10 61} 62 63Job { 64 Name = @hostname3@ 65 Type = Backup 66 Client = @hostname3@-fd 67 FileSet = "@hostname3@-FileSet" 68 Storage = File 69 Messages = Standard 70 Pool = Default 71 Write Bootstrap = "@working_dir@/NightlySave.bsr" 72 Maximum Concurrent Jobs = 10 73} 74 75 76 77Job { 78 Name = "MonsterSave" 79 Type = Backup 80 Client=@hostname@-fd 81 FileSet="Full Set" 82 Storage = File1 83 Messages = Standard 84 Pool = Default 85 Write Bootstrap = "@working_dir@/NightlySave.bsr" 86} 87 88 89Job { 90 Name = "VerifyVolume" 91 Type = Verify 92 Level = VolumeToCatalog 93 Client=@hostname@-fd 94 FileSet="Full Set" 95 Storage = File 96 Messages = Standard 97 Pool = Default 98 Write Bootstrap = "@working_dir@/NightlySave.bsr" 99} 100 101 102Job { 103 Name = "SparseTest" 104 Type = Backup 105 Client=@hostname@-fd 106 FileSet="SparseSet" 107 Storage = File 108 Messages = Standard 109 Pool = Default 110 Write Bootstrap = "@working_dir@/NightlySave.bsr" 111} 112 113Job { 114 Name = "CompressedTest" 115 Type = Backup 116 Client=@hostname@-fd 117 FileSet="CompressedSet" 118 Storage = File 119 Messages = Standard 120 Pool = Default 121 Maximum Concurrent Jobs = 10 122 Write Bootstrap = "@working_dir@/NightlySave.bsr" 123# Max Run Time = 15 seconds 124} 125 126Job { 127 Name = "SparseCompressedTest" 128 Type = Backup 129 Client=@hostname@-fd 130 FileSet="SparseCompressedSet" 131 Storage = File 132 Messages = Standard 133 Pool = Default 134 Write Bootstrap = "@working_dir@/NightlySave.bsr" 135} 136 137 138# Backup the catalog database (after the nightly save) 139Job { 140 Name = "BackupCatalog" 141 Type = Backup 142 Client=@hostname@-fd 143 FileSet="Catalog" 144# Schedule = "WeeklyCycleAfterBackup" 145 Storage = File 146 Messages = Standard 147 Pool = Default 148 # This creates an ASCII copy of the catalog 149 RunBeforeJob = "@sbindir@/make_catalog_backup -u regress" 150 # This deletes the copy of the catalog 151 RunAfterJob = "@sbindir@/delete_catalog_backup" 152 Write Bootstrap = "@working_dir@/BackupCatalog.bsr" 153} 154 155# Standard Restore template, to be changed by Console program 156Job { 157 Name = "RestoreFiles" 158 Type = Restore 159 Client=@hostname@-fd 160 FileSet="Full Set" 161 Storage = File 162 Messages = Standard 163 Pool = Default 164 Where = @tmpdir@/bareos-restores 165} 166 167 168# List of files to be backed up 169FileSet { 170 Name = "Full Set" 171 Include { Options { signature=MD5 } 172 File = @hostname_files@ 173 } 174} 175 176FileSet { 177 Name = "@hostname1@-FileSet" 178 Include { Options { signature=MD5 } 179 File = @hostname1_files@ 180 } 181} 182 183FileSet { 184 Name = "@hostname2@-FileSet" 185 Include { Options { signature=MD5 } 186 File = @hostname2_files@ 187 } 188} 189 190FileSet { 191 Name = "@hostname3@-FileSet" 192 Include { Options { signature=MD5 } 193 File = @hostname3_files@ 194 } 195} 196 197FileSet { 198 Name = "SparseSet" 199 Include { Options { signature=MD5; sparse=yes } 200 File=<@tmpdir@/file-list 201 } 202} 203 204FileSet { 205 Name = "CompressedSet" 206 Include { 207 Options { signature=MD5; compression=GZIP } 208 File =<@tmpdir@/file-list 209 } 210} 211 212FileSet { 213 Name = "SparseCompressedSet" 214 Include { 215 Options { 216 signature=MD5; compression=GZIP 217 } 218 File= <@tmpdir@/file-list 219 } 220} 221 222 223 224# 225# When to do the backups, full backup on first sunday of the month, 226# differential (i.e. incremental since full) every other sunday, 227# and incremental backups other days 228Schedule { 229 Name = "WeeklyCycle" 230 Run = Level=Full 1st sun at 1:05 231 Run = Level=Differential 2nd-5th sun at 1:05 232 Run = Level=Incremental mon-sat at 1:05 233} 234 235# This schedule does the catalog. It starts after the WeeklyCycle 236Schedule { 237 Name = "WeeklyCycleAfterBackup" 238 Run = Level=Full sun-sat at 1:10 239} 240 241# This is the backup of the catalog 242FileSet { 243 Name = "Catalog" 244 Include { Options { signature=MD5 } 245 File=/home/kern/bareos/regress/bin/working/bareos.sql 246 } 247} 248 249# Client (File Services) to backup 250Client { 251 Name = @hostname@-fd 252 Address = @hostname@ 253 FDPort = @fdport@ 254 Catalog = MyCatalog 255 Password = "xevrjURYoCHhn26RaJoWbeWXEY/a3VqGKp/37tgWiuHc" # password for FileDaemon 256 File Retention = 30d # 30 days 257 Job Retention = 180d # six months 258 AutoPrune = yes # Prune expired Jobs/Files 259 Maximum Concurrent Jobs = 10 260} 261 262Client { 263 Name = @hostname1@-fd 264 Address = @hostname1@ 265 FDPort = 9102 266 Catalog = MyCatalog 267 Password = "@hostname1_password@" # password for FileDaemon 268 File Retention = 30d # 30 days 269 Job Retention = 180d # six months 270 AutoPrune = yes # Prune expired Jobs/Files 271 Maximum Concurrent Jobs = 10 272} 273 274Client { 275 Name = @hostname2@-fd 276 Address = @hostname2@ 277 FDPort = 9102 278 Catalog = MyCatalog 279 Password = "@hostname2_password@" # password for FileDaemon 280 File Retention = 30d # 30 days 281 Job Retention = 180d # six months 282 AutoPrune = yes # Prune expired Jobs/Files 283 Maximum Concurrent Jobs = 10 284} 285 286Client { 287 Name = @hostname3@-fd 288 Address = @hostname3@ 289 FDPort = 9102 290 Catalog = MyCatalog 291 Password = "@hostname3_password@" # password for FileDaemon 292 File Retention = 30d # 30 days 293 Job Retention = 180d # six months 294 AutoPrune = yes # Prune expired Jobs/Files 295 Maximum Concurrent Jobs = 10 296} 297 298 299# Definiton of file storage device 300Storage { 301 Name = File 302 Address = @hostname@ # N.B. Use a fully qualified name here 303 SDPort = @sdport@ 304 Password = "ccV3lVTsQRsdIUGyab0N4sMDavui2hOBkmpBU0aQKOr9" 305 Device = FileStorage 306 Media Type = File 307 Maximum Concurrent Jobs = 10 308} 309 310Storage { 311 Name = File1 312 Address = @hostname@ # N.B. Use a fully qualified name here 313 SDPort = @sdport@ 314 Password = "ccV3lVTsQRsdIUGyab0N4sMDavui2hOBkmpBU0aQKOr9" 315 Device = FileStorage1 316 Media Type = File1 317 Maximum Concurrent Jobs = 10 318} 319 320 321# Generic catalog service 322Catalog { 323 Name = MyCatalog 324 @libdbi@ 325 dbdriver = "@db_type@" 326 dbname = @db_name@; user = @db_user@; password = "@db_password@" 327} 328 329# Reasonable message delivery -- send most everything to email address 330# and to the console 331Messages { 332 Name = Standard 333 mailcommand = "@sbindir@/bsmtp -h localhost -f \"\(Bareos regression\) %r\" -s \"Regression: %t %e of %c %l\" %r" 334 operatorcommand = "@sbindir@/bsmtp -h localhost -f \"\(Bareos regression\) %r\" -s \"Regression: Intervention needed for %j\" %r" 335# MailOnError = @job_email@ = all 336# operator = @job_email@ = mount 337 console = all, !skipped, !terminate, !restored, !audit 338# 339# WARNING! the following will create a file that you must cycle from 340# time to time as it will grow indefinitely. However, it will 341# also keep all your messages if the scroll off the console. 342# 343 append = "@working_dir@/log" = all, !skipped, !audit 344 catalog = all, !skipped, !audit 345} 346 347Messages { 348 Name = NoEmail 349 mailcommand = "@sbindir@/bsmtp -h localhost -f \"\(Bareos regression\) %r\" -s \"Regression: %t %e of %c %l\" %r" 350 console = all, !skipped, !terminate, !audit 351# 352# WARNING! the following will create a file that you must cycle from 353# time to time as it will grow indefinitely. However, it will 354# also keep all your messages if the scroll off the console. 355# 356 append = "@working_dir@/log" = all, !skipped, !audit 357 catalog = all, !skipped, !audit 358} 359 360# 361# Message delivery for daemon messages (no job). 362Messages { 363 Name = Daemon 364 mailcommand = "@sbindir@/bsmtp -h @smtp_host@ -f \"\(Bareos regression\) %r\" -s \"Regression daemon message\" %r" 365 mail = @job_email@ = all, !skipped, !audit 366 console = all, !skipped, !saved, !audit 367 append = "@working_dir@/log" = all, !skipped, !audit 368} 369 370# Default pool definition 371Pool { 372 Name = Default 373 Pool Type = Backup 374 Recycle = yes # Bareos can automatically recycle Volumes 375 AutoPrune = yes # Prune expired volumes 376 Volume Retention = 365d # one year 377} 378