It depends what you’re trying to do.
dd is good for cloning disks. This operates at the block level, low level.
If you are making a backup,
rsync is sufficient. It operates at the file system level, above block device level.
If the disks are already mounted (eg have another directory not in the /dev directory), using the
rsync command is the recommended way. If you have gigabytes to transfer, rsync is handy because if the process is interrupted, it can restart at the point it was up to.
If there’s hundreds of thousands of files the file list may be too long and it errors. I’ve overcome this by batching the rsync job into subdirectories at a time.
rsync —-avz —-show-progress /path/of/source /path/of/target
Rsync can be used across a network or web securely with ssh and ssh keys and scheduled using the system cron. It’s a handy tool to know.
rsync -e “ssh -i $HOME/.ssh/id_rsa” —-avz —-show-progress /path/of/source user@host:/path/of/target