Advertisement
Guest User

baculadircisco

a guest
Oct 6th, 2016
90
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 9.82 KB | None | 0 0
  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 5.2.13 (19 February 2013) -- redhat (Core)
  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 = servidorbacula-dir
  17. DIRport = 9101 # where we listen for UA connections
  18. QueryFile = "/etc/bacula/query.sql"
  19. WorkingDirectory = "/var/spool/bacula"
  20. PidDirectory = "/var/run"
  21. Maximum Concurrent Jobs = 1
  22. Password = "Passw0rd" # Console password
  23. Messages = Daemon
  24. }
  25.  
  26. JobDefs {
  27. Name = "DefaultJob"
  28. Type = Backup
  29. Level = Incremental
  30. Client = clientebacula-fd
  31. FileSet = "Full Set"
  32. Schedule = "WeeklyCycle"
  33. Storage = File
  34. Messages = Standard
  35. Pool = File
  36. Priority = 10
  37. Write Bootstrap = "/var/spool/bacula/%c.bsr"
  38. }
  39.  
  40.  
  41. #
  42. # Define the main nightly save backup job
  43. # By default, this job will back up to disk in /tmp
  44. Job {
  45. Name = "BackupClient1"
  46. Enabled = no
  47. Client = clientebacula-fd
  48. FileSet = "FileSetSrvDB"
  49. Schedule = "ScheduleSrvBD"
  50. Full Backup Pool = FullSrvDB
  51. Incremental Backup Pool = IncrSrvDB
  52. Differential Backup Pool = DiffSrvDB
  53. Storage = File
  54. Type = Backup
  55. Level Incremental
  56. Pool = FullSrvDB
  57. Priority = 10
  58. Messages = Standard
  59. }
  60.  
  61. #Job {
  62. # Name = "BackupClient2"
  63. # Client = bacula2-d
  64. # JobDefs = "DefaultJob"
  65. #}
  66.  
  67. # Backup the catalog database (after the nightly save)
  68. Job {
  69. Name = "BackupCatalog"
  70. JobDefs = "DefaultJob"
  71. Level = Full
  72. FileSet="Catalog"
  73. Schedule = "WeeklyCycleAfterBackup"
  74. # This creates an ASCII copy of the catalog
  75. # Arguments to make_catalog_backup.pl are:
  76. # make_catalog_backup.pl <catalog-name>
  77. RunBeforeJob = "/usr/libexec/bacula/make_catalog_backup.pl MyCatalog"
  78. # This deletes the copy of the catalog
  79. RunAfterJob = "/usr/libexec/bacula/delete_catalog_backup"
  80. Write Bootstrap = "/var/spool/bacula/%n.bsr"
  81. Priority = 11 # run after main backup
  82. }
  83.  
  84. #
  85. # Standard Restore template, to be changed by Console program
  86. # Only one such job is needed for all Jobs/Clients/Storage ...
  87. #
  88. Job {
  89. Name = "RestoreFiles"
  90. Type = Restore
  91. Client=clientebacula-fd
  92. FileSet="Full Set"
  93. Storage = File
  94. Pool = Default
  95. Messages = Standard
  96. Where = /tmp/bacula-restores
  97. }
  98.  
  99.  
  100. # List of files to be backed up
  101. FileSet {
  102. Name = "Full Set"
  103. Include {
  104. Options {
  105. signature = MD5
  106. }
  107.  
  108. FileSet {
  109. Name = "FileSetSrvDB"
  110. Include {
  111. Options {
  112. signature = MDS
  113. }
  114. File = /home/bacula/dumps
  115. }
  116.  
  117. Exclude {
  118. File = /proc
  119. File = /tmp
  120. File = /.journal
  121. File = /.fsck
  122. }
  123. }
  124. #
  125. # Put your list of files here, preceded by 'File =', one per line
  126. # or include an external list with:
  127. #
  128. # File = <file-name
  129. #
  130. # Note: / backs up everything on the root partition.
  131. # if you have other partitions such as /usr or /home
  132. # you will probably want to add them too.
  133. #
  134. # By default this is defined to point to the Bacula binary
  135. # directory to give a reasonable FileSet to backup to
  136. # disk storage during initial testing.
  137. #
  138. File = /usr/sbin
  139. }
  140.  
  141. #
  142. # If you backup the root directory, the following two excluded
  143. # files can be useful
  144. #
  145. Exclude {
  146. File = /var/spool/bacula
  147. File = /tmp
  148. File = /proc
  149. File = /tmp
  150. File = /.journal
  151. File = /.fsck
  152. }
  153. }
  154.  
  155. #
  156. # When to do the backups, full backup on first sunday of the month,
  157. # differential (i.e. incremental since full) every other sunday,
  158. # and incremental backups other days
  159. Schedule {
  160. Name = "WeeklyCycle"
  161. Run = Full 1st sun at 23:05
  162. Run = Differential 2nd-5th sun at 23:05
  163. Run = Incremental mon-sat at 23:05
  164. }
  165.  
  166. # This schedule does the catalog. It starts after the WeeklyCycle
  167. Schedule {
  168. Name = "WeeklyCycleAfterBackup"
  169. Run = Full sun-sat at 23:10
  170. }
  171.  
  172. Schedule {
  173. Name = "ScheduleSrvDB"
  174. Run = Incremental sun at 03:00
  175. Run = Full 1s sat at 03:00
  176. }
  177.  
  178. # This is the backup of the catalog
  179. FileSet {
  180. Name = "Catalog"
  181. Include {
  182. Options {
  183. signature = MD5
  184. }
  185. File = "/var/spool/bacula/bacula.sql"
  186. }
  187. }
  188.  
  189. # Client (File Services) to backup
  190. Client {
  191. Name = clientebacula-fd
  192. Address = localhost
  193. FDPort = 9102
  194. Catalog = MyCatalog
  195. Password = "Passw0rd" # password for FileDaemon
  196. File Retention = 30 days # 30 days
  197. Job Retention = 6 months # six months
  198. AutoPrune = yes # Prune expired Jobs/Files
  199. }
  200.  
  201.  
  202.  
  203. #
  204. # Second Client (File Services) to backup
  205. # You should change Name, Address, and Password before using
  206. #
  207. #Client {
  208. # Name = bacula2-fd
  209. # Address = localhost2
  210. # FDPort = 9102
  211. # Catalog = MyCatalog
  212. # Password = "@@FD_PASSWORD@@2" # password for FileDaemon 2
  213. # File Retention = 30 days # 30 days
  214. # Job Retention = 6 months # six months
  215. # AutoPrune = yes # Prune expired Jobs/Files
  216. #}
  217.  
  218.  
  219. # Definition of file storage device
  220. Storage {
  221. Name = File
  222. # Do not use "localhost" here
  223. Address = localhost # N.B. Use a fully qualified name here
  224. SDPort = 9103
  225. Password = "Passw0rd"
  226. Device = FileStorage
  227. Media Type = File
  228. }
  229.  
  230.  
  231.  
  232. # Definition of DDS tape storage device
  233. #Storage {
  234. # Name = DDS-4
  235. # Do not use "localhost" here
  236. # Address = localhost # N.B. Use a fully qualified name here
  237. # SDPort = 9103
  238. # Password = "@@SD_PASSWORD@@" # password for Storage daemon
  239. # Device = DDS-4 # must be same as Device in Storage daemon
  240. # Media Type = DDS-4 # must be same as MediaType in Storage daemon
  241. # Autochanger = yes # enable for autochanger device
  242. #}
  243.  
  244. # Definition of 8mm tape storage device
  245. #Storage {
  246. # Name = "8mmDrive"
  247. # Do not use "localhost" here
  248. # Address = localhost # N.B. Use a fully qualified name here
  249. # SDPort = 9103
  250. # Password = "@@SD_PASSWORD@@"
  251. # Device = "Exabyte 8mm"
  252. # MediaType = "8mm"
  253. #}
  254.  
  255. # Definition of DVD storage device
  256. #Storage {
  257. # Name = "DVD"
  258. # Do not use "localhost" here
  259. # Address = localhost # N.B. Use a fully qualified name here
  260. # SDPort = 9103
  261. # Password = "@@SD_PASSWORD@@"
  262. # Device = "DVD Writer"
  263. # MediaType = "DVD"
  264. #}
  265.  
  266.  
  267. # Generic catalog service
  268. Catalog {
  269. Name = MyCatalog
  270. # Uncomment the following line if you want the dbi driver
  271. # dbdriver = "dbi:postgresql"; dbaddress = 127.0.0.1; dbport =
  272. dbname = "bacula"; dbuser = "root"; dbpassword = "Passw0rd"
  273. }
  274.  
  275. # Reasonable message delivery -- send most everything to email address
  276. # and to the console
  277. Messages {
  278. Name = Standard
  279. #
  280. # NOTE! If you send to two email or more email addresses, you will need
  281. # to replace the %r in the from field (-f part) with a single valid
  282. # email address in both the mailcommand and the operatorcommand.
  283. # What this does is, it sets the email address that emails would display
  284. # in the FROM field, which is by default the same email as they're being
  285. # sent to. However, if you send email to more than one address, then
  286. # you'll have to set the FROM address manually, to a single address.
  287. # for example, a 'no-reply@mydomain.com', is better since that tends to
  288. # tell (most) people that its coming from an automated source.
  289.  
  290. #
  291. mailcommand = "/usr/sbin/bsmtp -h localhost -f \"\(Bacula\) \<%r\>\" -s \"Bacula: %t %e of %c %l\" %r"
  292. operatorcommand = "/usr/sbin/bsmtp -h localhost -f \"\(Bacula\) \<%r\>\" -s \"Bacula: Intervention needed for %j\" %r"
  293. mail = root@localhost = all, !skipped
  294. operator = root@localhost = mount
  295. console = all, !skipped, !saved
  296. #
  297. # WARNING! the following will create a file that you must cycle from
  298. # time to time as it will grow indefinitely. However, it will
  299. # also keep all your messages if they scroll off the console.
  300. #
  301. append = "/var/log/bacula/bacula.log" = all, !skipped
  302. catalog = all
  303. }
  304.  
  305.  
  306. #
  307. # Message delivery for daemon messages (no job).
  308. Messages {
  309. Name = Daemon
  310. mailcommand = "/usr/sbin/bsmtp -h localhost -f \"\(Bacula\) \<%r\>\" -s \"Bacula daemon message\" %r"
  311. mail = root@localhost = all, !skipped
  312. console = all, !skipped, !saved
  313. append = "/var/log/bacula/bacula.log" = all, !skipped
  314. }
  315.  
  316. # Default pool definition
  317. Pool {
  318. Name = Default
  319. Pool Type = Backup
  320. Recycle = yes # Bacula can automatically recycle Volumes
  321. AutoPrune = yes # Prune expired volumes
  322. Volume Retention = 365 days # one year
  323. }
  324.  
  325. # File Pool definition
  326. Pool {
  327. Name = File
  328. Pool Type = Backup
  329. Recycle = yes # Bacula can automatically recycle Volumes
  330. AutoPrune = yes # Prune expired volumes
  331. Volume Retention = 365 days # one year
  332. Maximum Volume Bytes = 50G # Limit Volume size to something reasonable
  333. Maximum Volumes = 100 # Limit number of Volumes in Pool
  334. }
  335.  
  336.  
  337. # Scratch pool definition
  338. Pool {
  339. Name = Scratch
  340. Pool Type = Backup
  341. }
  342.  
  343. Pool {
  344. Name = FullSrvDB
  345. Label Format = "FullSrvDB"
  346. Pool Type = Backup
  347. Recycle = yes
  348. AutoPrune = yes
  349. Volume Retention = 6 months
  350. Maximum Volume Jobs = 1
  351. }
  352.  
  353. Pool {
  354. Name = IncrSrvDB
  355. Label Format = "IncrSrvDB"
  356. Pool Type = Backup
  357. Recycle = yes
  358. AutoPrune = yes
  359. Volume Retention = 10 days
  360. Maximum Volume Jobs = 1
  361. }
  362. #
  363. # Restricted console used by tray-monitor to get the status of the director
  364. #
  365. Console {
  366. Name = servidorbacula-mon
  367. Password = "Passw0rd" #"@@MON_DIR_PASSWORD@@"
  368. CommandACL = status, .status
  369. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement