rsync to multiple remote servers

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
6
down vote

favorite
1












I have a file I want to sent to multiple separate servers.
Is it possible to name multiple destinations?



rsync foo.png server1:foo.png server2:foo.png


This gives me a "Unexpected remote arg:server1:foo.png










share|improve this question

























    up vote
    6
    down vote

    favorite
    1












    I have a file I want to sent to multiple separate servers.
    Is it possible to name multiple destinations?



    rsync foo.png server1:foo.png server2:foo.png


    This gives me a "Unexpected remote arg:server1:foo.png










    share|improve this question























      up vote
      6
      down vote

      favorite
      1









      up vote
      6
      down vote

      favorite
      1






      1





      I have a file I want to sent to multiple separate servers.
      Is it possible to name multiple destinations?



      rsync foo.png server1:foo.png server2:foo.png


      This gives me a "Unexpected remote arg:server1:foo.png










      share|improve this question













      I have a file I want to sent to multiple separate servers.
      Is it possible to name multiple destinations?



      rsync foo.png server1:foo.png server2:foo.png


      This gives me a "Unexpected remote arg:server1:foo.png







      rsync






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Dec 23 '14 at 3:24









      Miati

      1,0972919




      1,0972919




















          3 Answers
          3






          active

          oldest

          votes

















          up vote
          6
          down vote



          accepted










          No, there is no way in rsync to specify multiple destinations. You'll need to invoke the command multiple times. If you have many targets, you might want to consider using a network filesystem instead--it might be a better fit for your problem.






          share|improve this answer



























            up vote
            7
            down vote













            Turns out there is a program that permits this, just not the original rsync program.
            It's called pssh (parallel ssh I suppose)



            One of the features:




            "-- Parallel rsync (parallel-rsync, upstream calls it prsync), efficiently copies files to multiple hosts in parallel"

            - http://www.ubuntugeek.com/execute-commands-simultaneously-on-multiple-servers-using-psshcluster-sshmultixterm.html







            share|improve this answer



























              up vote
              0
              down vote













              Albeit you're invoking the command multiple times through file input, this can be done by specifying the desired destinations in one desired file:



              while read in; do rsync -av /Path/of/Source/Synced.file "$in":/Path/of/Destination/Synced.file; done < destinations.txt


              enter image description here



              Please excuse my test as I only had two systems available at the time, but I'm most certain this will work for multiple systems as desired. It's not the most elegant method I suppose, but it's definitely one way of automating. And please, feel free to correct me if this doesn't work as I don't have the resources available to test beyond two systems at this time of post.






              share|improve this answer








              New contributor




              Brandon L is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
              Check out our Code of Conduct.

















                Your Answer








                StackExchange.ready(function()
                var channelOptions =
                tags: "".split(" "),
                id: "106"
                ;
                initTagRenderer("".split(" "), "".split(" "), channelOptions);

                StackExchange.using("externalEditor", function()
                // Have to fire editor after snippets, if snippets enabled
                if (StackExchange.settings.snippets.snippetsEnabled)
                StackExchange.using("snippets", function()
                createEditor();
                );

                else
                createEditor();

                );

                function createEditor()
                StackExchange.prepareEditor(
                heartbeatType: 'answer',
                convertImagesToLinks: false,
                noModals: true,
                showLowRepImageUploadWarning: true,
                reputationToPostImages: null,
                bindNavPrevention: true,
                postfix: "",
                imageUploader:
                brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
                contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
                allowUrls: true
                ,
                onDemand: true,
                discardSelector: ".discard-answer"
                ,immediatelyShowMarkdownHelp:true
                );



                );













                 

                draft saved


                draft discarded


















                StackExchange.ready(
                function ()
                StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f175549%2frsync-to-multiple-remote-servers%23new-answer', 'question_page');

                );

                Post as a guest















                Required, but never shown

























                3 Answers
                3






                active

                oldest

                votes








                3 Answers
                3






                active

                oldest

                votes









                active

                oldest

                votes






                active

                oldest

                votes








                up vote
                6
                down vote



                accepted










                No, there is no way in rsync to specify multiple destinations. You'll need to invoke the command multiple times. If you have many targets, you might want to consider using a network filesystem instead--it might be a better fit for your problem.






                share|improve this answer
























                  up vote
                  6
                  down vote



                  accepted










                  No, there is no way in rsync to specify multiple destinations. You'll need to invoke the command multiple times. If you have many targets, you might want to consider using a network filesystem instead--it might be a better fit for your problem.






                  share|improve this answer






















                    up vote
                    6
                    down vote



                    accepted







                    up vote
                    6
                    down vote



                    accepted






                    No, there is no way in rsync to specify multiple destinations. You'll need to invoke the command multiple times. If you have many targets, you might want to consider using a network filesystem instead--it might be a better fit for your problem.






                    share|improve this answer












                    No, there is no way in rsync to specify multiple destinations. You'll need to invoke the command multiple times. If you have many targets, you might want to consider using a network filesystem instead--it might be a better fit for your problem.







                    share|improve this answer












                    share|improve this answer



                    share|improve this answer










                    answered Dec 23 '14 at 3:37









                    John Zwinck

                    1753




                    1753






















                        up vote
                        7
                        down vote













                        Turns out there is a program that permits this, just not the original rsync program.
                        It's called pssh (parallel ssh I suppose)



                        One of the features:




                        "-- Parallel rsync (parallel-rsync, upstream calls it prsync), efficiently copies files to multiple hosts in parallel"

                        - http://www.ubuntugeek.com/execute-commands-simultaneously-on-multiple-servers-using-psshcluster-sshmultixterm.html







                        share|improve this answer
























                          up vote
                          7
                          down vote













                          Turns out there is a program that permits this, just not the original rsync program.
                          It's called pssh (parallel ssh I suppose)



                          One of the features:




                          "-- Parallel rsync (parallel-rsync, upstream calls it prsync), efficiently copies files to multiple hosts in parallel"

                          - http://www.ubuntugeek.com/execute-commands-simultaneously-on-multiple-servers-using-psshcluster-sshmultixterm.html







                          share|improve this answer






















                            up vote
                            7
                            down vote










                            up vote
                            7
                            down vote









                            Turns out there is a program that permits this, just not the original rsync program.
                            It's called pssh (parallel ssh I suppose)



                            One of the features:




                            "-- Parallel rsync (parallel-rsync, upstream calls it prsync), efficiently copies files to multiple hosts in parallel"

                            - http://www.ubuntugeek.com/execute-commands-simultaneously-on-multiple-servers-using-psshcluster-sshmultixterm.html







                            share|improve this answer












                            Turns out there is a program that permits this, just not the original rsync program.
                            It's called pssh (parallel ssh I suppose)



                            One of the features:




                            "-- Parallel rsync (parallel-rsync, upstream calls it prsync), efficiently copies files to multiple hosts in parallel"

                            - http://www.ubuntugeek.com/execute-commands-simultaneously-on-multiple-servers-using-psshcluster-sshmultixterm.html








                            share|improve this answer












                            share|improve this answer



                            share|improve this answer










                            answered Jan 12 '15 at 19:47









                            Miati

                            1,0972919




                            1,0972919




















                                up vote
                                0
                                down vote













                                Albeit you're invoking the command multiple times through file input, this can be done by specifying the desired destinations in one desired file:



                                while read in; do rsync -av /Path/of/Source/Synced.file "$in":/Path/of/Destination/Synced.file; done < destinations.txt


                                enter image description here



                                Please excuse my test as I only had two systems available at the time, but I'm most certain this will work for multiple systems as desired. It's not the most elegant method I suppose, but it's definitely one way of automating. And please, feel free to correct me if this doesn't work as I don't have the resources available to test beyond two systems at this time of post.






                                share|improve this answer








                                New contributor




                                Brandon L is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                                Check out our Code of Conduct.





















                                  up vote
                                  0
                                  down vote













                                  Albeit you're invoking the command multiple times through file input, this can be done by specifying the desired destinations in one desired file:



                                  while read in; do rsync -av /Path/of/Source/Synced.file "$in":/Path/of/Destination/Synced.file; done < destinations.txt


                                  enter image description here



                                  Please excuse my test as I only had two systems available at the time, but I'm most certain this will work for multiple systems as desired. It's not the most elegant method I suppose, but it's definitely one way of automating. And please, feel free to correct me if this doesn't work as I don't have the resources available to test beyond two systems at this time of post.






                                  share|improve this answer








                                  New contributor




                                  Brandon L is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                                  Check out our Code of Conduct.



















                                    up vote
                                    0
                                    down vote










                                    up vote
                                    0
                                    down vote









                                    Albeit you're invoking the command multiple times through file input, this can be done by specifying the desired destinations in one desired file:



                                    while read in; do rsync -av /Path/of/Source/Synced.file "$in":/Path/of/Destination/Synced.file; done < destinations.txt


                                    enter image description here



                                    Please excuse my test as I only had two systems available at the time, but I'm most certain this will work for multiple systems as desired. It's not the most elegant method I suppose, but it's definitely one way of automating. And please, feel free to correct me if this doesn't work as I don't have the resources available to test beyond two systems at this time of post.






                                    share|improve this answer








                                    New contributor




                                    Brandon L is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                                    Check out our Code of Conduct.









                                    Albeit you're invoking the command multiple times through file input, this can be done by specifying the desired destinations in one desired file:



                                    while read in; do rsync -av /Path/of/Source/Synced.file "$in":/Path/of/Destination/Synced.file; done < destinations.txt


                                    enter image description here



                                    Please excuse my test as I only had two systems available at the time, but I'm most certain this will work for multiple systems as desired. It's not the most elegant method I suppose, but it's definitely one way of automating. And please, feel free to correct me if this doesn't work as I don't have the resources available to test beyond two systems at this time of post.







                                    share|improve this answer








                                    New contributor




                                    Brandon L is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                                    Check out our Code of Conduct.









                                    share|improve this answer



                                    share|improve this answer






                                    New contributor




                                    Brandon L is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                                    Check out our Code of Conduct.









                                    answered Nov 20 at 8:01









                                    Brandon L

                                    1




                                    1




                                    New contributor




                                    Brandon L is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                                    Check out our Code of Conduct.





                                    New contributor





                                    Brandon L is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                                    Check out our Code of Conduct.






                                    Brandon L is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                                    Check out our Code of Conduct.



























                                         

                                        draft saved


                                        draft discarded















































                                         


                                        draft saved


                                        draft discarded














                                        StackExchange.ready(
                                        function ()
                                        StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f175549%2frsync-to-multiple-remote-servers%23new-answer', 'question_page');

                                        );

                                        Post as a guest















                                        Required, but never shown





















































                                        Required, but never shown














                                        Required, but never shown












                                        Required, but never shown







                                        Required, but never shown

































                                        Required, but never shown














                                        Required, but never shown












                                        Required, but never shown







                                        Required, but never shown






                                        Popular posts from this blog

                                        How to check contact read email or not when send email to Individual?

                                        Bahrain

                                        Postfix configuration issue with fips on centos 7; mailgun relay