In this example, the rsync command is used to migrate data any file system type to a target system.
The following rsync syntax can be used to create full and incremental copies:
rsync -avSM --delete source destination
Where:
a – Creates a copy in archival mode (maintains recursive directory structure and symbolic links).
v – Increases verbosity.
S– Handles sparse files efficiently
M– Sends OPTION to the remote side only.
--delete– Deletes extraneous files from the receiving side (files that aren't on the sending side).
source– The source directory to copy.
destination– The target destination directory.
Example:
root@Source# rsync -avSH --delete /export/projects target_name:/export