Basic syntax of rsync command
$ rsync options source destination
$ rsync -avzh /root/rpmpkgs /tmp/backups/
$ rsync -avz rpmpkgs/ root@192.168.0.101:/home/
Copy a File from a Remote Server to a Local Server with SSH
$ rsync -avzhe ssh root@192.168.0.100:/root/install.log /tmp/
Copy a File from a Local Server to a Remote Server with SSH
$ rsync -avzhe ssh backup.tar root@192.168.0.100:/backups/
Copy a File from a Remote Server to a Local Server with pem file SSH
$ rsync -avzh -e “ssh -i amazon_server.pem” root@192.168.0.100:/var/www/html /var/www/vhosts/example.com/