3 ms·
Daily rsync alone isn't enough. Any data which gets corrupted on the main drive will, within 24 hours, also be corrupted on the 'backup'. If you're confident e
by rahimnathwani 7y ago
Daily rsync alone isn't enough. Any data which gets corrupted on the main drive will, within 24 hours, also be corrupted on the 'backup'.
If you're confident enough that your computer won't get stolen, burn, or zapped by a power surge, then you can keep the same hardware setup you have, but:
1. Use borg backup (or restic) instead of rsync (so that you can restore to any day in the past, not only to yesterday)
2. Disconnect the 'backup' drive when it's not being used (so that it's protected from malware or fat fingers).
Even better would be:
3. Have a separate computer host the borg backups, and have it run 'borg serve' in append-only mode (so that, no matter what you do the main computer, you cannot destroy or corrupt past backups).
Even better:
4. Have this separate computer in a different physical location (so that you're protected from fire, theft and the like).
- matthewaveryusa 7y agoborg looks awesome. It comes up all the time when I research efficient data storage replication (buzzhash) so now I'm really going to try it out, thanks for the tips! :)
- rahimnathwani 7y ago:) Here is the documentation for borg serve with append-only: https://borgbackup.readthedocs.io/en/stable/usage/serve.html https://borgbackup.readthedocs.io/en/stable/usage/serve.html
- eikenberry 7y agoI didn't think corrupted data would change the size of the file or the mtime? If it doesn't then rsync wouldn't overwrite the second drive as it would see it as an existing, good copy. Unless you had rsync using checksum comparisons of course.
- rahimnathwani 7y agoYou're probably right for corruption caused by hardware failure or filesystem bugs. I was thinking about corruption in the wider sense, e.g. caused by application bugs.
- pnutjam 7y agoNot the parent, but I use a similar setup. I avoid this be keeping my 2nd drive formatted as btrfs, primary is xfs. After I rsync to the btrfs drive, I take a snapshot. I only rsync every week, my data doesn't change often and if it does, I can trigger a manual rsync using the same script in my /etc/cron.weekly/ edit: I do use borg to backup to my cloud storage server, since it's encrypted. Time4vps has super cheap storage servers, 1TB for about $20 a quarter. (my affiliate if anyone is interested; https://billing.time4vps.eu/?affid=1881 https://billing.time4vps.eu/?affid=1881)
- zurn 7y agorsync supports versioning, eg https://netfuture.ch/2013/08/simple-versioned-timemachine-like-backup-using-rsync/ https://netfuture.ch/2013/08/simple-versioned-timemachine-li...