-   Linux - Newbie (
-   -   Rsync specify SSH port (

suj 10-17-2011 12:58 AM

Rsync specify SSH port
Can some one help me in understanding rsync. I need to transfer a file from one server to another server, anyway the ssh port on the destination server is different. So how can I specify it in rsync command ?

Thanks in advance :)

colucix 10-17-2011 02:00 AM


rsync -e "ssh -p <PORT_NUMBER>" etc etc

meenakshi.khurana 10-17-2011 02:29 AM

rsync -v -e "ssh -p 5757" root@ /opt/ --dry-run


-v - verbose
-e - to secify any remote shell you like
--dry-run - will list files that will get copied without actually being copy. This can be used if you’re not yet ready to copy any files or want to verify what all data will get copied using the command.

Once you verified the data, you can actually copy the data by removing --dry-run option from above command.

All times are GMT -5. The time now is 07:05 AM.