Title: rsync-remote.rsync-home.sh.2015.03.22 \\ Created: 2018-04-29 22:39:45 +0000 \\ ====== rsync-remote.rsync-home.sh ====== #!/bin/bash # File: rsync-home.sh # Script to backup hydrogen's home to beryllium clear echo RSYNC SCRIPT TO BACKUP HYDROGEN/HOME DIRECTORY TO BERYLLIUM/RSYNC3 echo date echo echo Backing up /home/ echo cd /home ARCHIVE_NAME="`date "+archive-%Y-%m-%d"`" echo Any old files will be archived to the following directory: $ARCHIVE_NAME echo # NOTE: The -c option will use the checksum of both files to see if backup needed sudo /usr/bin/rsync -vaz \ -e "ssh -l root" \ --progress \ --backup \ --backup-dir $ARCHIVE_NAME \ --stats \ --delete \ --delete-excluded \ --password-file /home/ericswanson/rsync.secret \ '/home' ericswanson@192.168.0.4::hydrogen-home/ echo echo date exit 0