Backup to 2 disks

badi95

New Member
Sep 26, 2022
3
0
1
I have a strange backup situation I need help with.
We have 2 4TB HDDs that we use for backup. I currently have them mounted each individually to maximize backup space, and minimize risk of loss of data if one fails. I've setup my vm backups to alternate between the two disks based on the day being even or odd, odd days to disk1 even days to disk2.
The issue I'm running into is with retaining old backups. I keep 4 months of backups but I just need 1 backup per month, I don't need the month on both disks. I haven't figured out a way to do this via retention policy.
I've considered mergerfs, but it doesn't have the granular control of which backups end up on which disk, which might loss of a whole vms backups if one disk goes down. I'm thinking I'll have to just write a script to prune by month on a monthly basis, but if there are alternative options I'd love to explore them.
 
Create two additional backup jobs for monthly backups and tell one backup job to do the backups of every odd month to disk1 and even month to disk2?
 
Create two additional backup jobs for monthly backups and tell one backup job to do the backups of every odd month to disk1 and even month to disk2?
This is a great idea! Thank you.
Here's what I have now:
1712673493250.png
To implement this I'd just separate the monthly and yearly into separate jobs and just worry about retention for each duration in each task?

Would this be the correct syntax for every odd month?
1712673893619.png
 
Might be needed to have dedicated Directory storages pointing to other folders on those disks so different backup retentions won't prune backups you don't want.

Not sure about the Schedule. I'm still always confused about the systemd schedule syntax. But did you see the prune simulator?: https://pbs.proxmox.com/docs/prune-simulator/
 
I didn't even think about the pruning causing problems, but you're right different prune policies could wipe out other backups.

I might just end up writing a script to do it and run it once a month. Do you know if I can just delete the backup files via `rm` or do I need to use a specific proxmox tool?
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!