Bryce Stenberg wrote:


# do the backup to removable drive

rdiff-backup -b -v2 --print-statistics --exclude-sockets --exclude /mnt/hrnzlx02/rootsnapshot/tmp --exclude /mnt/hrnzlx02/rootsnapshot/media --exclude /mnt/hrnzlx02/rootsnapshot/proc --exclude /mnt/hrnzlx02/rootsnapshot/mnt /mnt/hrnzlx02/rootsnapshot /media/usbdrive/backup

/
/
Hi Bryce, thanks for sharing your script, it has given me ideas for when I do rebuilds. I'm doing various rsync backups, some of which have exclude statements, if there is just one I would use --exclude, if several I do --exclude-from="/path/to/file.txt" containing the folders to be excluded on separate lines in the format:
**/.Trash*
**/vms
being easier to maintain if there are a number. Note this is a little different to doing so in a tar-based backup exclude-from which does not have ** at the start of each line. You may or may not consider this to be an improvement. Can't emphasize enough the need to fully test your restore process since it is likely you overlook something first time round, or at least will make some refinement following some testing. And ongoing testing every now and then is wise also. Not necessarily to restore a machine, but to at least get your data out of the restore files into a test folder so you can satisfy yourself you can access your files. I also log this so I have a record, particularly of any issues identified and how they are resolved. I also make use of truecrypt to encrypt a pair of removable 1TB drives, since I rotate them, one being on site, the other at a different secret location. Scripts obviously require the drive to be mounted, mine run from cron now that I'm satisfied all is good. I just check and log.

Multiple birds dead, single stone: my drives contain 2 partitions with separate encryption passwords, allowing the off-site drive to receive a home network backup, and every couple of days or so take one to work and bring the other home. Definitely don't want the data on either partition being accessed following theft of a drive, nor particularly anyone at work seeing my personal data. Satisfies a fundamental requirement for off-site backups, though whether or not your company policy would allow use of the 2 partitions as I do is another matter.

Cheers,
Roger

Reply via email to