Verifying backup drives

Verifying backup drives

I prefer managing my backups myself on a set of replicated USB drives, for all the reasons I’ve covered before. This approach works great for me, but it’s vulnerable to human error because I manually copy new backup content to the drives.

While doing a manual update to my backup drives recently, I screwed something up and overwrote some files on one of the drives. And rather than just scrub that copy and re-image from the server, I decided it would be nice to know the exact status of all of my backup copies.

So I wrote a backup-verifier tool in Python to analyze my backups (stored on my home server and on various USB drives) and summarize for me any discrepancies found. The basic concept is that I do a directory listing of each drive to a text file, then the tool analyzes these listings and summarizes any differences found.

I just finished using backup-verifier to get everything 100% consistent, and my 413,249 files (mostly photos) are all verified and accounted for across all four copies. And now I have much simpler and faster way to re-verify my backups from time to time, compared to what I used to do.

Planning to sleep extra well tonight.