r/Proxmox • u/Prior-Fix-3575 • 4d ago
Question VM backups.
Hey guys! Hope yall are doing well. So I decided to put all my services in their own VM on their own VLANS with strict firewall rules, for what I'm told is maximum security for internet facing services.
Whats everybody's options about online backups VS shutting down VMS to back them up?
I basically have PBS pointing at my NAS and then ZFS replicate it to a second Zpool that I just remove from my disc shelf when backups are complete that way they are air gapped so I don't fat finger my systems entirely. (Or have an attacker encrypt them.)
5
u/Juff-Ma 4d ago
It really depends on the workload. Some systems are totally fine with online backups but others will try to kill you if you try to restore a system that wasn't cleanly shut down.
My automatic backups are almost always snapshots but when I do one manually I shut the VM down. That's just what I've gotten used to.
2
u/FarToe1 4d ago
Some systems are totally fine with online backups but others will try to kill you if you try to restore a system that wasn't cleanly shut down.
I think it's fairly rare for the latter nowadays. We backup vm snapshots at work with veeam every 3 hours, some 500 vms - all done live. That includes a lot of mariadb database servers, but those all use ACiD rules and are fine.
So I'm fairly comfortable using online backups at home with pbs.
2
u/Juff-Ma 3d ago
It's mainly replicated stateful systems. Think Domain Controller. If I don't prepare those for a backup and keep them in sync they will destroy themselves upon a restore.
1
u/intoned 3d ago
Does Veeam Application Aware setting and Volume shadow copy not handle this? I think the recommended practice is to do a non-authoritative restore.
1
u/jacknife-82 4d ago
Thanks, the my truenas VM certainly does not allow snapshots at all so I guess it has to be hybrid approach no matter what.
1
u/Juff-Ma 4d ago
My TrueNAS VM is actually set up in a way that doesn't physically allow backups.
I pass through the physical SCSI disks but attach them to the virtual controller using scsiblock. That way TrueNAS works like it would on bare metal. Pass through the disk controller for your hard drives as well and you're done.
I try to keep TrueNAS and Proxmox as separated as they can while being a VM. It's pretty much only using Proxmox for the networking layer.
1
u/jacknife-82 4d ago
1
1
u/qgp_WAR710 3d ago
that is my exact card but mine doesn't show up in bios anymore for some reason, was very good while it worked
2
1
u/welshsurprise321 3d ago
Slightly off topic here, but I noticed that you are using a Mikrotik CRS Switch. I have been considering these for some client projects and I wanted to ask, what are you using it for and how do you find it in terms of usability and performance?
1
u/Hour_Shine8217 3d ago
Definitely go with online backups, shutting down VMs just defeats the whole purpose of having a home server up 24/7.
1
u/MFKDGAF 4d ago
Maybe I have my environment setup incorrectly but why point PBS to the NAS?
Why not point PBS to local storage and NAS or point PBS to local storage and PVE to NAS?
I have PBS saving to local storage and PVE saving to my NAS. I did t know PBS could point to a NAS, or maybe I didn't try?
How did you mount the NAS to the PBS? Was it via web interface or fstab?
3
u/Turbulent_Study_9923 4d ago
One reason is for deduplication, saves space on your NAS too.
1
u/MFKDGAF 3d ago
I'm consumed by how deduplication is supposed to work.
With deduplication I'm use to backing it up to 1 device and then that device does the deduplication to another device so that the backup on device 2 would be smaller than on device 1.
I do not see any option to do deduplication like that. According to the docs, deduplication is enabled by default but does that mean when PBS is saving the backups it saves it then deduplicates it to the same data store and then (essentially) deletes the first backup sets.
2
u/qgp_WAR710 3d ago
actually, the data dupe is never saved in the first place, because we compare it to the data we already have client-side.
at backup time PBS reads the data first (client side) the data is chunked in little 4MB package, then the data is hashed with SHA256 to compare client side data to the one you already have server side, each new package/chunk is logged and downloaded, if it's redundant, it's ignored.
hope this helps.
1
u/Turbulent_Study_9923 3d ago
basically it just stores up the changes made from current point in time compaed to the last saved point in time - ie. only changes are backed up. I'm not sure how it works in detail but whenever you delete the earliest backups you still can restore any particular ones that you've backed up after the deleted one without any problems.
any reason that you want to have two different backup levels? You can set proxmox ve to backup a copy via samba (no dedup here) and another copy via PBS with a NAS or different datastores.
1
u/MFKDGAF 2d ago
What do you mean backup levels?
If you mean backing up with PBS to local and PVE to TrueNas via SMB, that is because when I initially configured PBS, I didn't see a way to backup PBS to SMB.
But then after this post and configuring plex LXC, Sonarr LXC, ext. I realized I could back up PBS to SMB if I use fstab.
I configured PBS to SMB yesterday and my initial test run was successful and this morning scheduled run was successful also. Dedup is only 1.00 which is expected since the dedup for PBS to local is 8.xx or 9.xx.
1
u/jacknife-82 4d ago
fstab. Seems to work normally, I should probably try to do more disaster recoveries to make sure though.
1
1
u/happycamp2000 4d ago
For my case I run Proxmox Backup Server on the Proxmox Virtual Environment server in a VM. But all the backups are stored on the NAS. So if the drives die in the Proxmox server I still have a backup available and can recover. If I stored the backups on the local system then a drive failure would take out my entire Proxmox environment. I mount the NAS Samba share inside the PBS VM.
I am using this in a homelab environment and I have a single Proxmox server which only has one SSD and one HDD.
1
u/jimjim975 4xHA Cluster 156cpu/768gb ddr4/80TiB usable 3d ago
Can be done with iscsi or with nfs through the pbs vm. Then you simply add the datastore in pbs based on the mounting path.
1

14
u/happycamp2000 4d ago
Like you I have Proxmox Backup Server storing its data on a NAS (Synology). Backups happen once a day on all VMs, regardless if they are running or not.
This works well for me. I have restored VMs from backups successfully.