rsync to multiple destinations using same filelist?

Posted by Dylan B. on Server Fault See other posts from Server Fault or by Dylan B.
Published on 2010-04-29T18:00:24Z Indexed on 2010/04/29 18:07 UTC
Read the original article Hit count: 476

Filed under:
|
|

I'm wondering if it's possible for rsync to copy one directory to multiple remote destinations all in one go, or even in parallel. (not necessary, but would be useful.)

Normally, something like the following would work just fine:

$ rsync -Pav /junk user@host1:/backup
$ rsync -Pav /junk user@host2:/backup
$ rsync -Pav /junk user@host3:/backup

And if that's the only option, I'll use that. However, /junk is located on a slow drive with quite a few files, and rebuilding the filelist of some ~12,000 files each time is agonizingly slow (~5 minutes) compared to the actual transfer/updating. Is it possible to do something like this, to accomplish the same thing:

$ rsync -Pav /junk user@host1:/backup user@host2:/backup user@host3:/backup 

Thanks for looking!

© Server Fault or respective owner

Related posts about rsync

Related posts about parallel