Table of Contents
How to mirror drives with rsync
One of the most overlooked Linux commands is rsync. It solves many of the issues that the normal copy command is unable to do. For example, with a single rsync command you can mirror the entire contents of one hard drive to another without any third party software and if one wishes, only copy the differences between the two locations.
Mirror two hard drives
$ rsync -avzr --delete /source/ /destination/
Let us explain in detail what these parameters mean. For the sake of clarity, multiple options have been separated into their own line.
|rsync||the command itself|
|-z||compress file data during the transfer|
|-r||recurse into directories|
|–delete||delete extraneous files from the destination|
|/source/||where to copy files from|
|/destination/||where to copy files to|
For further information on the rsync command, type:
$ man rsync
comments powered by Disqus