Here is my current backup strategy. Basically all devices backup to a NAS (which also hosts shared files). And periodically, backup the whole NAS to an offline PC:
The "backup of backup" setup has a few downsides:
- The work of digging out and connecting the old PC to the network periodically. Additional hardware / software maintenance.
- The software RAID 5 needs multiple HDDs, usually retired hardware previously used in the NAS. High risk of failure.
An alternative would be using external USB HDDs for the "backup of backup":
- Use external HDDs via USB/eSATA for the "backup of backup". Rotate between two external HDDs to minimize the chance of single point of failure
- Use veracrypt to encrypt the whole external HDD device
- Within the encrypted volume, use BTRFS and mount with compression. Can also use the snapshot function of BTRFS if necessary
- Sadly the NAS is running a very old version of Synology software and it doesn't support veracrypt or BTRFS. Will need to do this on a desktop PC.
While BTRFS do compression and snapshots, will need to pay attention on the disk usage. It is inefficient and difficult to re-balance if the free space is low (the main reason why I gave up on using BTRFS on boot partition even when it is the default for OpenSUSE). Should probably do a re-balance after every rsync.
- Only less than 1/10th of the files are actually compressed. Probably because the NAS manly stores photos, movies, and backup archives... in which already in compressed format.
Processed 117244 files, 1223867 regular extents (1223867 refs), 17472 inline.
Type Perc Disk Usage Uncompressed Referenced
TOTAL 95% 1.5T 1.6T 1.6T
none 100% 1.5T 1.5T 1.5T
zstd 22% 22G 103G 103G
- Encounter RAID read errors and veracrypt issues. May need to think about doing checksum after backup
To be continued...
Some useful commands, assuming sdd is the external HDD:
sudo veracrypt --filesystem=none --slot=1 /dev/sdd
sudo mkfs.btrfs -L backup /dev/mapper/veracrypt1
sudo mount -o compress=zstd:15 /dev/mapper/veracrypt1 /mnt/backup
sudo compsize /mnt/backup