admin/ July 9, 2016/ Linux/ 0 comments

How to rsync with non-standard ssh port ?

The below method  for non-standard port (22) rsync command.

By defauld rsync use port 22, because rsync works with ssh port. If ssh is running on non-standard port.

Use the below command.

rsync -avz -e "ssh -p $port" <source address> <destination address>

For Example

rsync -avz -e "ssh -p 2222" [email protected]:/home/     /home/backup/

Leave a Reply