Bunch more big changes here too

This commit is contained in:
Joe S 2020-06-08 21:57:59 -04:00
parent 2bd54e59db
commit bcc8d29ebf
12 changed files with 183 additions and 35 deletions

View File

@ -38,7 +38,7 @@ Autochanger { # New resource
Maximum Concurrent Jobs = 20
}
Storage {
Storage { # Can have multiple of these per autochanger
Name = Drive-0-LTO-3
Address = 10.85.3.39
SDPort = 9103
@ -101,3 +101,22 @@ messages { # Send mail to me and matthew
mail = younglad204@gmail.com,kenwood364@gmail.com = all, !skipped
console = all, !skipped, !saved
}
messages { # Send mail to me and Travis
name = TravissMail
mail = travisbuttons14@gmail.com,kenwood364@gmail.com = all, !skipped
console = all, !skipped, !saved
}
messages { # Send mail to me and Zach
name = ZachsMail
mail = zmcmenemy@gmail.com,kenwood364@gmail.com = all, !skipped
console = all, !skipped, !saved
}
messages { # Send mail to me and Caleb
name = CalebsMail
mail = younglad204@gmail.com,kenwood364@gmail.com = all, !skipped
console = all, !skipped, !saved
}

View File

@ -13,3 +13,61 @@ Job { # Archive Obelisk
Full Backup Pool = Archive-Pool
Incremental Backup Pool = Archive-Pool
}
Job { # Archive Magnesium
Name = "Archive-Magnesium"
Client = Zinc-Client
Type = "Backup"
FileSet = "Magnesium Archive"
Storage = Iron-Autochanger
Messages = JoesMail
Pool = Archive-Pool # required parameter for all Jobs, despite what appears in the next few lines
Full Backup Pool = Archive-Pool
Incremental Backup Pool = Archive-Pool
}
# Users go here
Job { # Archive Travis
Name = "Archive-Travis"
Client = Zinc-Client
Type = "Backup"
FileSet = "Travis Backup"
Storage = Iron-Autochanger
Messages = TravissMail
Pool = Archive-Pool # required parameter for all Jobs, despite what appears in the next few lines
Full Backup Pool = Archive-Pool
Incremental Backup Pool = Archive-Pool
}
Job { # Archive Zach
Name = "Archive-Zach"
Client = Zinc-Client
Type = "Backup"
FileSet = "Zach Backup"
Storage = Iron-Autochanger
Messages = ZachsMail
Pool = Archive-Pool # required parameter for all Jobs, despite what appears in the next few lines
Full Backup Pool = Archive-Pool
Incremental Backup Pool = Archive-Pool
}
Job { # Archive Caleb
Name = "Archive-Caleb"
Client = Zinc-Client
Type = "Backup"
FileSet = "Caleb Backup"
Storage = Iron-Autochanger
Messages = CalebsMail
Pool = Archive-Pool # required parameter for all Jobs, despite what appears in the next few lines
Full Backup Pool = Archive-Pool
Incremental Backup Pool = Archive-Pool
}

View File

@ -7,8 +7,8 @@ Client {
Password = "iamnotacrook"
Address = 10.85.3.31
Catalog = MyCatalog
File Retention = 6 months
Job Retention = 2 years
File Retention = 4 months
Job Retention = 30 years
AutoPrune = yes # Prune expired Jobs/Files
}

View File

@ -9,3 +9,14 @@ FileSet {
File = "/mnt/Obelisk/"
}
}
# Archive for Magnesium
FileSet {
Name = "Magnesium Archive"
Include {
Options {
signature = MD5
}
File = "/mnt/Magnesium/"
}
}

View File

@ -22,3 +22,14 @@ FileSet {
File = "/var/lib/postgresql/12/main"
}
}
# Backup proxmox backups
FileSet {
Name = "ProxmoxBackups"
Include {
Options {
signature = MD5
}
File = "/mnt/Proxmox/"
}
}

View File

@ -6,7 +6,34 @@ FileSet {
signature = MD5
compression=GZIP
}
File = "/mnt/Caleb/"
File = "/mnt/Users/Caleb/"
#File = "/mnt/NextCloud/data/Caleb/"
}
}
# Travis's backup on zinc
FileSet {
Name = "Travis Backup"
Include {
Options {
signature = MD5
compression=GZIP
}
File = "/mnt/Users/Travis/"
#File = "/mnt/NextCloud/data/Travis/"
}
}
# Zach's backup on zinc
FileSet {
Name = "Zach Backup"
Include {
Options {
signature = MD5
compression=GZIP
}
File = "/mnt/Users/Zach/"
#File = "/mnt/NextCloud/data/Zach/"
}
}
@ -18,8 +45,8 @@ FileSet {
signature = MD5
compression=GZIP
}
File = "/mnt/Mark/"
#File = "/mnt/NextCloud/data/mark/"
File = "/mnt/Users/mark/"
File = "/mnt/NextCloud/data/mark/"
}
}
@ -31,7 +58,7 @@ FileSet {
signature = MD5
compression=GZIP
}
File = "/mnt/Joe/"
File = "/mnt/Users/Joe/"
File = "/mnt/NextCloud/data/joe/"
}
}
@ -44,7 +71,7 @@ FileSet {
signature = MD5
compression=GZIP
}
File = "/mnt/Matthew/"
File = "/mnt/Users/Matthew/"
#File = "/mnt/NextCloud/data/matthew/"
}
}
@ -57,7 +84,7 @@ FileSet {
signature = MD5
compression=GZIP
}
File = "/mnt/Michael/"
File = "/mnt/Users/Michael/"
#File = "/mnt/NextCloud/data/michael/"
}
}

View File

@ -71,4 +71,6 @@ Pool {
# When the volume is recycled, return it automatically to
# this pool
Recycle Pool = Scratch
Cleaning Prefix = "CLN"
}

View File

@ -1,17 +1,17 @@
Schedule {
Name = EveryTwoDays
Run = Level=Full jan 1st sun at 4:15
Run = Level=Differential feb 1st sun at 4:15
Run = Level=Differential mar 1st sun at 4:15
Run = Level=Full apr 1st sun at 4:15
Run = Level=Differential may 1st sun at 4:15
Run = Level=Differential jun 1st sun at 4:15
Run = Level=Full jul 1st sun at 4:15
Run = Level=Differential aug 1st sun at 4:15
Run = Level=Differential sep 1st sun at 4:15
Run = Level=Full oct 1st sun at 4:15
Run = Level=Differential nov 1st sun at 4:15
Run = Level=Differential dec 1st sun at 4:15
Run = Level=Full jan 1st sun at 2:15
Run = Level=Differential feb 1st sun at 2:15
Run = Level=Differential mar 1st sun at 2:15
Run = Level=Full apr 1st sun at 2:15
Run = Level=Differential may 1st sun at 2:15
Run = Level=Differential jun 1st sun at 2:15
Run = Level=Full jul 1st sun at 2:15
Run = Level=Differential aug 1st sun at 2:15
Run = Level=Differential sep 1st sun at 2:15
Run = Level=Full oct 1st sun at 2:15
Run = Level=Differential nov 1st sun at 2:15
Run = Level=Differential dec 1st sun at 2:15
#Run = Level=Incremental tue at 2:15
Run = Level=Incremental sat at 2:15
@ -19,18 +19,18 @@ Schedule {
Schedule {
Name = AdminTwoDays
Run = Level=Full jan 1st sun at 4:30
Run = Level=Differential feb 1st sun at 4:30
Run = Level=Differential mar 1st sun at 4:30
Run = Level=Full apr 1st sun at 4:30
Run = Level=Differential may 1st sun at 4:30
Run = Level=Differential jun 1st sun at 4:30
Run = Level=Full jul 1st sun at 4:30
Run = Level=Differential aug 1st sun at 4:30
Run = Level=Differential sep 1st sun at 4:30
Run = Level=Full oct 1st sun at 4:30
Run = Level=Differential nov 1st sun at 4:30
Run = Level=Differential dec 1st sun at 4:30
Run = Level=Full jan 1st sun at 2:30
Run = Level=Differential feb 1st sun at 2:30
Run = Level=Differential mar 1st sun at 2:30
Run = Level=Full apr 1st sun at 2:30
Run = Level=Differential may 1st sun at 2:30
Run = Level=Differential jun 1st sun at 2:30
Run = Level=Full jul 1st sun at 2:30
Run = Level=Differential aug 1st sun at 2:30
Run = Level=Differential sep 1st sun at 2:30
Run = Level=Full oct 1st sun at 2:30
Run = Level=Differential nov 1st sun at 2:30
Run = Level=Differential dec 1st sun at 2:30
#Run = Level=Incremental tue at 2:30
Run = Level=Incremental sat at 2:30

View File

@ -0,0 +1,20 @@
from discord_webhook import DiscordWebhook
import subprocess
webhookURL = "https://discordapp.com/api/webhooks/719690867811811348/8LExCQbqOPP0XAdNcbV8JHrVYupOSYmeLwkBJWCDCe72JoPyc4Yy_R2wzbkKSN33MPAn"
out = subprocess.Popen(['echo messages | bconsole'],
stdout=subprocess.PIPE,
stderr=subprocess.STDOUT,
shell=True)
stdout,stderr = out.communicate()
print(stdout)
print(stderr)
cleaned_stdout = b"```" + stdout.partition(b"\nmessages\n")[2] + b"```"
if (cleaned_stdout != b'```You have no messages.\n```'):
webhook = DiscordWebhook(url=webhookURL, content=cleaned_stdout)
response = webhook.execute()
else:
print("Done.")

Binary file not shown.

View File

@ -1,6 +1,6 @@
when you buy new tapes, install them in your library and run the
*label pool=Scratch storage=Iron-Autochanger slots=17,18,19,20,21,22,23,24,25,26 barcodes
*label pool=Scratch storage=Iron-Autochanger slots=3,11,27,28 barcodes
command to write the initial label onto the tape (so bacula knows it's allowed to use the tape) and then bacula and scratch pool will do everything else
libraries have slots, that command says "load the tape from slot 1 into the drive, and write a label to it matching its barcode. then repeat for slot 2. then repeat for slot 3"