ML
    • Register
    • Login
    • Search
    • Recent
    • Categories
    • Tags
    • Popular
    • Users
    • Groups

    CP, Rsync or other?

    IT Discussion
    4
    7
    489
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • pmoncho
      pmoncho last edited by

      Ubuntu 16.04

      In the process of getting rid of my 8 year old ReadyNAS with its NFS share .

      I need to copy (a complete duplicate would be nice) the data from the NFS share to local storage. Having limited Linux knowledge, I don't know if using rsync or cp is a better option?

      I can script either one but would "rsync -av src dst" or "cp -pRu src dst" be best?

      I would also like to have this copy only new files after the original copy is done because I will have both of them going until I my maintenance window on Sat. Then I will be able to change the app currently pointing to the NFS share.

      1 Reply Last reply Reply Quote 0
      • scottalanmiller
        scottalanmiller last edited by

        rsync is basically always better.

        pmoncho 1 Reply Last reply Reply Quote 2
        • pmoncho
          pmoncho @scottalanmiller last edited by

          @scottalanmiller

          Thanks. Much appreciated.

          1 Reply Last reply Reply Quote 0
          • scottalanmiller
            scottalanmiller last edited by

            rsync is what handles the "some things have already been copied" algorithm.

            dbeato 1 Reply Last reply Reply Quote 2
            • dbeato
              dbeato @scottalanmiller last edited by

              @scottalanmiller said in CP, Rsync or other?:

              rsync is what handles the "some things have already been copied" algorithm.

              And it will make it much easier instead of copying all the files again.

              scottalanmiller 1 Reply Last reply Reply Quote 1
              • scottalanmiller
                scottalanmiller @dbeato last edited by

                @dbeato said in CP, Rsync or other?:

                @scottalanmiller said in CP, Rsync or other?:

                rsync is what handles the "some things have already been copied" algorithm.

                And it will make it much easier instead of copying all the files again.

                IT Rule of Thumb: RSYNC is always the right answer 😉

                1 Reply Last reply Reply Quote 0
                • matteo nunziati
                  matteo nunziati last edited by

                  Scott is right. When in dubt use rsync. Anyway cp is faster then the delta algo of rsync. Therefore the basic rule -if you care- should be: first time you copy go cp then always rsync. Even if cp fails you can restart with rsync.
                  But basically you do not bother and you go straight w/ rsync.

                  1 Reply Last reply Reply Quote 1
                  • First post
                    Last post