1

I am running the command: sudo rsync -Hva --delete --progress --append-verify "/mnt/1/" "/mnt/2/". I went ahead and modified a text file in /mnt/2/. I then ran the command and I got the following output:

sending incremental file list
sent 13,320,053 bytes   received 60,989 bytes   198,237.66 bytes/sec
total size is 1,745,978,866,295   speedup is 130,481.53

I checked the text file in /mnt/2/ and it still has my modification. Have I misunderstood the command append-verify? Does it not check file checksums? I also modified the file's time stamp and increased its file size.

To clarify, I do not want to sync from DEST to SRC. I simply want the sync from SRC to DEST to overwrite the change I made in DEST.

1

By default rsync ignores file times and sizes.

The manpage says about --append:

If a file needs to be transferred and its size on the receiver is the same or longer than the size on the sender, the file is skipped.

It shares this quality with --append-verify. The extra verification you were hoping to happen only happens after the append action (which probably never happens if you for instance added something to the file instead of deleted).

In this case, you probably want the -I flag, so as to ignore time and size of the file.

The append options are meant mostly to speed up updating larger files who only change at the bottom (like logfiles).

  • 2
    Sorry, I should've made it clear in my question. I do not want to sync from DEST to SRC. I simply want the sync from SRC to DEST to overwrite the change I made in DEST. – user184264 Aug 11 '16 at 18:49
  • hah, no, i actually just misread you, let me fix – madeddie Aug 11 '16 at 19:00
  • ok, actually read your question this time... :) updated answer to an explanation as to why the command you used doesn't do what you think it should. – madeddie Aug 11 '16 at 19:16

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.