Bash – File Backup Script
This script uses rdiff-backup to backup files on a Linux host using rysnc. The script then sends an email that notifies of it’s completion. Make sure to install the rdiff-backup package on your distro before running it.
The script uses a nice value of -19 so that it does not interfere too much with other running processes since file copying is a fairly taxing IO process. Also passing the –exclude flag to rdiff-backup allows you to exclude certain directories from being backed up, such as LOST+FOUND.