Skip to main content

rsync - Easily Transfer and Synchronize Files Between Computers

rsync is a great utility that can be use for transferring files to and from a remote computer. It can be use to sync files between the computers as well.

rsync can be installed from the package manager on a Debian system:

sudo apt install rsync -y

Screenshot 2022-10-04 230859.png

The basic syntax for rsync is as follows:

rysnc -optional-flags soruce-file-location destination-file-location

rsync have many possible flags to use. Below are a list of the flags according to the official manual:

FlagsShorthand
Description
--verbose
-v
increase verbosity
--quiet

--no-motd

--checksum

--archive

--no-OPTION

--recursive

--relative

--no-implied-dirs

--backup

--backup-dir=DIR

--suffix=SUFFIX

--update

--inplace

--append

--append-verify

--dirs

--links

--copy-links

--copy-unsafe-links

--safe-links

--copy-dirlinks

--keep-dirlinks

--hard-links

--perms

--executability

--chmod=CHMOD

--acls

--xattrs

--owner

--group

--devices

--specials




--times

--omit-dir-times

--super

--fake-super

--dry-run

--whole-file

--one-file-system

--block-size=SIZE

--rsh=COMMAND

--rsync-path=PROGRAM

--existing

--ignore-existing

--remove-source-files

--del

--delete

--delete-before

--delete-during

--delete-delay

--delete-after

--delete-excluded

--ignore-errors

--force

--max-delete=NUM

--max-size=SIZE

--min-size=SIZE

--partial

--partial-dir=DIR

--delay-updates

--prune-empty-dirs

--numeric-ids

--timeout=SECONDS

--contimeout=SECONDS

--ignore-times

--size-only

--modify-window=NUM

--temp-dir=DIR

--fuzzy

--compare-dest=DIR

--copy-dest=DIR

--link-dest=DIR

--compress

--compress-level=NUM

--skip-compress=LIST

--cvs-exclude

--filter=RULE







--exclude=PATTERN

--exclude-from=FILE

--include=PATTERN

--include-from=FILE

--files-from=FILE

--from0

--protect-args

--address=ADDRESS

--port=PORT

--sockopts=OPTIONS

--blocking-io

--stats

--8-bit-output

--human-readable

--progress





--itemize-changes



--out-format=FORMAT



--log-file=FILE



--log-file-format=FMT


--password-file=FILE

--list-only

--bwlimit=KBPS

--write-batch=FILE

--only-write-batch=FILE

--read-batch=FILE

--protocol=NUM

--iconv=CONVERT_SPEC

--checksum-seed=NUM

--ipv4

--ipv6

--version

--help