The backups that failed every night for three and a half months
My Proxmox backups had been failing since August, and nothing told me. Here's what broke, how it got fixed, and what now makes sure it can't happen quietly again.
Every night at 9 PM my Proxmox host, darktower, backs up its virtual machines. Or it was supposed to. When I finally went looking, the last good backup was from August 10th. Every run since then had failed, about 110 nights in a row, and not one of them had told me.
How the backups are set up
The backups go to a Proxmox Backup Server (PBS), which runs as its own small VM on darktower. PBS doesn't keep the backups on its own disk: it stores them on a network share on my NAS, so they live on a different machine from the VMs they protect.
In August the NAS I was using crashed. I replaced it with a new TrueNAS box, mordor, and copied the backup data across. What I forgot was that PBS still pointed at the old NAS's address. At boot it tried to mount a share on a machine that no longer existed, timed out, and carried on without it. From then on every backup job ended with:
unable to open chunk store at "/mnt/pbs-backups/.chunks" - No such file or directoryThe fix, part one: point PBS at the new NAS
One line in /etc/fstab on the PBS VM changed from the dead NAS to mordor's share. I also added nofail and a mount timeout, so if mordor is ever down at boot, PBS still starts instead of hanging. The share mounted, the datastore showed up as active again, and all the old backups were still there.
The fix, part two: who owns the files
The first test backup still failed, this time with Permission denied. When the data was copied to the new NAS, every file ended up owned by root. PBS works as its own backup user, so it could read the old backups but couldn't add new ones or tidy up old chunks.
There were about 200,000 files to fix. Changing their owner over the network took just under two hours, run as a background job so it didn't matter if my connection dropped. After that, a test backup of the Pi-hole VM went through in four minutes.
Keeping it tidy
The backup storage had also been set to keep every backup forever. That's now 7 daily, 4 weekly and 6 monthly copies. The first run with the new rule cleaned up dozens of old copies by itself.
While I was at it, darktower now also copies its own Proxmox configuration (VM definitions, storage, network settings) to the NAS every Sunday. It keeps the newest copy, and only deletes the old one after checking the new one opens properly. If darktower itself ever dies, rebuilding it starts from that file.
The real problem: silence
The backups breaking was a mistake anyone could make during a NAS swap. Not hearing about it for three and a half months was the actual failure. Proxmox had been trying to email me. When I checked, its outgoing mail queue held a pile of "backup failed" messages with nowhere to go.
Now darktower and the backup server both send their mail through the same small mail relay my other apps use, which passes it on to my inbox. On top of that, Uptime Kuma checks every service and machine once a minute and emails me when anything goes down, and again when it comes back.
What I'd tell anyone running a home lab
- A backup you haven't checked lately is a hope, not a backup. Look at the dates now and then.
- When you replace a machine, search for its old address everywhere: fstab files, storage settings, proxy configs.
- Make sure alerts can actually reach you. Send yourself a test email from each box.