Powerful local or remote copy preserving metadata and ACLs when supported.
Section: Copy and Synchronize
Mirror a directory with rsync
bash
bash
rsync -aHAX --info=progress2 /src/ /dst/Explanation
Powerful local or remote copy preserving metadata and ACLs when supported.
Learn the surrounding workflow
Compare similar commands or jump into common fixes when this command is part of a bigger troubleshooting path.
Related commands
Same sheet · prioritizing Copy and Synchronize
Copy a directory tree preserving metadata
Preserve mode, ownership, timestamps, and symlinks.
Mirror and delete removed files
Make the destination match the source exactly.
Sync a directory over SSH
Efficiently transfer deltas to a remote server.
List archive contents
Inspect what an archive contains before extracting.