First Time Using Rsync

Alex Ferrara alex at
Fri Jul 23 14:29:27 MDT 2010

On 23/07/2010, at 10:42 PM, Carlos Mennens <carlos.mennens at> wrote:

> I did a search on the web and there are so many different methods /
> variations of using this powerful tool. My question for you guys is
> very simple and I would like to hear from people on the list who use
> this daily what the best command would be to transfer all data from
> one server (srv_old) to my newly build server (srv_new)?
> I have one directory "/home" which contains everyone's mailbox & email
> which I want to rsync from 'srv_old' to 'srv_new'. I am just looking
> for the fastest and most secure method of doing something like this:
> rsync -avz ssh /home/ root at srv_new:/home
> Thanks for any help!
> -- 
> Please use reply-all for most replies to avoid omitting the mailing list.
> To unsubscribe or change options:
> Before posting, read:

The short answer is

rsync -avz /home/ root at srv_new:/home/

a - Archive. Very important to preserve permissions, and it also recurses the directory
v - Verbose. Heavy output to stdout which is probably what you want if you are watching it
z - Gzip compression on the fly

You will be asked for a password and srv_new needs to allow root logins for this to work.

If you are scripting this for backup purposes either set up public key authentication or an rsync server on the destination to avoid the prompted password.


More information about the rsync mailing list