rsync -r -u --log-file=[path for your new log file] --stats [path for your source directory] [path for your target directory]
I'll explain the arguments:
- -r tells it to recurse through the subdirectories of your specified source directory, meaning that it will synchronize files found directly in the source directory, but also files found within subdirectories inside your source directory.
- -u tells it that if a file is in both the source and target directory, it should only update the target directory file if it is an older version than the one in the source.
- --log-file=[path for your new log file] is the command you should use if you want the results of your file sync to be saved in a log file named however you like. For example: --log-file='/home/user/Desktop/Backup Log.txt'
- --stats tells it to output some useful file sync statistics for you such as how many files were scanned through, transferred, size of the transfer, etc.
- [path for your source directory] should be replaced with your source directory such as '/media/USB Stick'
- [path for your target directory] should be replaced with your target directory such as '/media/Backup Drive'
Creating launchers is simple!
- Right-click (or if you're a lefty, left-click) on your desktop and select Create Launcher
- The selection next to Type: should be left as Application
- Beside Name: you can put whatever you like to indicate that it's a Launcher for your backup command
- Now next to Command: put in your full rsync command with all the arguments discussed (or not) above
- Feel free to click on the icon box at the top left to select a more interesting icon for your backup launcher (i.e. select an icon, and press OK)
- Press OK when you're done and now you have a Launcher that you can double click whenever you need to back your stuff up!
Happy file-synchronizing! This program does a blazing fast job :)
No comments:
Post a Comment