rsync
rsync -auhv --delete --force --size-only --progress -n {SRC} {DST}
-a: Archive (same as -rlptgoD, no -A,-X,-U,-N,-H)-r: Recursive-l: Copy symlinks as symlinks-p: Preserve permissions-t: Preserve modification times-g: Preserve group-o: Preserve owner (super-user only)-D: Preserve device files (super-user only) and preserve special files-u: Skip files that are newer on the receiver-h: Output numbers in a human-readable format-v: Increase verbosity--delete: Delete extraneous files from dest dirs--force: Force deletion of dirs even if not empty--progress: Show progress during transfer-n: Dry-run (list only, nothing is changed)-e 'ssh -p 22': Use ssh on port 22
Omit the -n dry-run flag if everything seem in order.
The source {SRC} and destination {DST}must end with a / if they are directories, otherwise the source folder is created within the target.