Advertisement
Guest User

Untitled

a guest
May 25th, 2017
537
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 7.50 KB | None | 0 0
  1. bacula-client01:/etc/bacula# netstat -npl | grep bac
  2. tcp 0 0 0.0.0.0:9102 0.0.0.0:* LISTEN 2181/bacula-fdDirector { # define myself
  3. Name = bacula-server01-dir
  4. DIRport = 9101 # where we listen for UA connections
  5. QueryFile = "/etc/bacula/scripts/query.sql"
  6. WorkingDirectory = "/var/lib/bacula"
  7. PidDirectory = "/var/run/bacula"
  8. Maximum Concurrent Jobs = 1
  9. Password = "jhIoXJvQkNGGoPjrJqvdhNB8YGBmK4PFa" # Console password
  10. Messages = Daemon
  11. DirAddress = 0.0.0.0
  12. }
  13.  
  14.  
  15.  
  16. JobDefs {
  17. Name = "DefaultJob"
  18. Type = Backup
  19. Level = Incremental
  20. Client = bacula-server01-fd
  21. FileSet = "Full Set"
  22. Schedule = "WeeklyCycle"
  23. Storage = File
  24. Messages = Standard
  25. Pool = File
  26. Priority = 10
  27. Write Bootstrap = "/var/lib/bacula/%c.bsr"
  28. }
  29.  
  30. #
  31. # Define the main nightly save backup job
  32. # By default, this job will back up to disk in /nonexistant/path/to/file/archive/dir
  33. Job {
  34. Name = "BackupClient1"
  35. JobDefs = "DefaultJob"
  36. }
  37.  
  38. # Backup the catalog database (after the nightly save)
  39. Job {
  40. Name = "BackupCatalog"
  41. JobDefs = "DefaultJob"
  42. Level = Full
  43. FileSet="Catalog"
  44. Schedule = "WeeklyCycleAfterBackup"
  45. # This creates an ASCII copy of the catalog
  46. # Arguments to make_catalog_backup.pl are:
  47. # make_catalog_backup.pl <catalog-name>
  48. RunBeforeJob = "/etc/bacula/scripts/make_catalog_backup.pl MyCatalog"
  49. # This deletes the copy of the catalog
  50. RunAfterJob = "/etc/bacula/scripts/delete_catalog_backup"
  51. Write Bootstrap = "/var/lib/bacula/%n.bsr"
  52. Priority = 11 # run after main backup
  53. }
  54.  
  55. #
  56. # Standard Restore template, to be changed by Console program
  57. # Only one such job is needed for all Jobs/Clients/Storage ...
  58. #
  59. Job {
  60. Name = "RestoreFiles"
  61. Type = Restore
  62. Client=bacula-server01-fd
  63. FileSet="Full Set"
  64. Storage = File
  65. Pool = Default
  66. Messages = Standard
  67. Where = /export/backup
  68. }
  69.  
  70.  
  71. # List of files to be backed up
  72. FileSet {
  73. Name = "Full Set"
  74. Include {
  75. Options {
  76. signature = MD5
  77. }
  78. File = /
  79. File = /boot
  80. }
  81.  
  82. Exclude {
  83. File = /var/lib/bacula
  84. File = /export/backup
  85. File = /proc
  86. File = /tmp
  87. File = /.journal
  88. File = /.fsck
  89. File = /dev
  90. File = /sys
  91. }
  92. }
  93.  
  94. #
  95. # When to do the backups, full backup on first sunday of the month,
  96. # differential (i.e. incremental since full) every other sunday,
  97. # and incremental backups other days
  98. Schedule {
  99. Name = "WeeklyCycle"
  100. Run = Full 1st sun at 23:05
  101. Run = Differential 2nd-5th sun at 23:05
  102. Run = Incremental mon-sat at 23:05
  103. }
  104.  
  105. # This schedule does the catalog. It starts after the WeeklyCycle
  106. Schedule {
  107. Name = "WeeklyCycleAfterBackup"
  108. Run = Full sun-sat at 23:10
  109. }
  110.  
  111. # This is the backup of the catalog
  112. FileSet {
  113. Name = "Catalog"
  114. Include {
  115. Options {
  116. signature = MD5
  117. }
  118. File = "/var/lib/bacula/bacula.sql"
  119. }
  120. }
  121.  
  122. # Client (File Services) to backup
  123. Client {
  124. Name = bacula-server01-fd
  125. Address = localhost
  126. FDPort = 9102
  127. Catalog = MyCatalog
  128. Password = "0yRdlJ6Bdt1KAivoiY7DMiWTwvVYuZl2U" # password for FileDaemon
  129. File Retention = 30 days # 30 days
  130. Job Retention = 6 months # six months
  131. AutoPrune = yes # Prune expired Jobs/Files
  132. }
  133.  
  134. Client {
  135. Name = bacula-client01-fd
  136. Address = 192.168.0.100
  137. FDPort = 9102
  138. Catalog = MyCatalog
  139. Password = "0yRdlJ6Bdt1KAivoiY7DMiWTwvVYuZl2U" # password for FileDaemon
  140. File Retention = 30 days # 30 days
  141. Job Retention = 6 months # six months
  142. AutoPrune = yes # Prune expired Jobs/Files
  143. }
  144.  
  145.  
  146. #
  147. # Second Client (File Services) to backup
  148. # You should change Name, Address, and Password before using
  149. #
  150. #Client {
  151. # Name = bacula-server012-fd
  152. # Address = localhost2
  153. # FDPort = 9102
  154. # Catalog = MyCatalog
  155. # Password = "0yRdlJ6Bdt1KAivoiY7DMiWTwvVYuZl2U2" # password for FileDaemon 2
  156. # File Retention = 30 days # 30 days
  157. # Job Retention = 6 months # six months
  158. # AutoPrune = yes # Prune expired Jobs/Files
  159. #}
  160.  
  161.  
  162. # Definition of file storage device
  163. Storage {
  164. Name = File
  165. # Do not use "localhost" here
  166. Address = bacula-server01.urdix.com # N.B. Use a fully qualified name here
  167. SDPort = 9103
  168. Password = "k4TE0sb8dI50Jt6nRIYcEd8iVw6wTznga"
  169. Device = FileStorage
  170. Media Type = File
  171. }
  172.  
  173.  
  174.  
  175.  
  176.  
  177. # Generic catalog service
  178. Catalog {
  179. Name = MyCatalog
  180. # Uncomment the following line if you want the dbi driver
  181. # dbdriver = "dbi:sqlite3"; dbaddress = 127.0.0.1; dbport =
  182. dbname = bacula; DB Address = ""; dbuser = "bacula"; dbpassword = "_beN1801"
  183. }
  184.  
  185. # Reasonable message delivery -- send most everything to email address
  186. # and to the console
  187. Messages {
  188. Name = Standard
  189. #
  190. # NOTE! If you send to two email or more email addresses, you will need
  191. # to replace the %r in the from field (-f part) with a single valid
  192. # email address in both the mailcommand and the operatorcommand.
  193. # What this does is, it sets the email address that emails would display
  194. # in the FROM field, which is by default the same email as they're being
  195. # sent to. However, if you send email to more than one address, then
  196. # you'll have to set the FROM address manually, to a single address.
  197. # for example, a 'no-reply@mydomain.com', is better since that tends to
  198. # tell (most) people that its coming from an automated source.
  199.  
  200. #
  201. mailcommand = "/usr/lib/bacula/bsmtp -h localhost -f \"\(Bacula\) \<%r\>\" -s \"Bacula: %t %e of %c %l\" %r"
  202. operatorcommand = "/usr/lib/bacula/bsmtp -h localhost -f \"\(Bacula\) \<%r\>\" -s \"Bacula: Intervention needed for %j\" %r"
  203. mail = root@localhost = all, !skipped
  204. operator = root@localhost = mount
  205. console = all, !skipped, !saved
  206. #
  207. # WARNING! the following will create a file that you must cycle from
  208. # time to time as it will grow indefinitely. However, it will
  209. # also keep all your messages if they scroll off the console.
  210. #
  211. append = "/var/lib/bacula/log" = all, !skipped
  212. catalog = all
  213. }
  214.  
  215.  
  216. #
  217. # Message delivery for daemon messages (no job).
  218. Messages {
  219. Name = Daemon
  220. mailcommand = "/usr/lib/bacula/bsmtp -h localhost -f \"\(Bacula\) \<%r\>\" -s \"Bacula daemon message\" %r"
  221. mail = root@localhost = all, !skipped
  222. console = all, !skipped, !saved
  223. append = "/var/lib/bacula/log" = all, !skipped
  224. }
  225.  
  226. # Default pool definition
  227. Pool {
  228. Name = Default
  229. Pool Type = Backup
  230. Recycle = yes # Bacula can automatically recycle Volumes
  231. AutoPrune = yes # Prune expired volumes
  232. Volume Retention = 365 days # one year
  233. }
  234.  
  235. # File Pool definition
  236. Pool {
  237. Name = File
  238. Pool Type = Backup
  239. Recycle = yes # Bacula can automatically recycle Volumes
  240. AutoPrune = yes # Prune expired volumes
  241. Volume Retention = 365 days # one year
  242. Maximum Volume Bytes = 50G # Limit Volume size to something reasonable
  243. Maximum Volumes = 100 # Limit number of Volumes in Pool
  244. }
  245.  
  246.  
  247. # Scratch pool definition
  248. Pool {
  249. Name = Scratch
  250. Pool Type = Backup
  251. }
  252.  
  253. #
  254. # Restricted console used by tray-monitor to get the status of the director
  255. #
  256. Console {
  257. Name = bacula-server01-mon
  258. Password = "zAMF6f9Xc1WbDrDtoNwUjvEa7EW1kr8pP"
  259. CommandACL = status, .status
  260. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement