3

In the rsync image of output below:

shell

I am unable to find the default checksum. Is it the first one, or the one in brackets?

What is the bit-depth of just xxhash?

Found this DOCUMENTATION states the first mentioned is being used, then what's the purpose of the bracketed one? Is it just a type indicator? What is the STR that the manual mentions here?

--checksum-choice=STR, --cc=STR
       This option overrides the checksum algorithms.  If one algorithm
       name is specified, it is used for both the transfer checksums
       and (assuming --checksum is specified) the pre-transfer
       checksums.  If two comma-separated names are supplied, the first
       name affects the transfer checksums, and the second name affects
       the pre-transfer checksums (-c).

       The checksum options that you may be able to use are:

       o      auto (the default automatic choice)

       o      xxh128

       o      xxh3

       o      xxh64 (aka xxhash)

       o      md5

       o      md4

       o      sha1

       o      none

Please mention the command for changing the checksum bit-depth. Is this correct?

--checksum-choice=XXH128 

1 Answer 1

5

When you read the list in the documentation, you'll see

  • xxh64 (aka xxhash)

"aka" is an abbreviation for "also known as"; what that means is that "xxhash" and "xxh64" mean the same thing, and that's why there's the "(xxhash)" after the "xxh64".

Also, the text you show explicitly states:

auto (the default automatic choice)

So, no. The parentheses don't mean "default". (When did parentheses ever mean "default"? Quite the opposite is usually the case!)

If you want to know what the "auto" means, which is the default as said in the text you posted, you will need to read the literally next paragraph in the documentation:

The "auto" option is the default, where rsync bases its algorithm choice on a negotiation between the client and the server as follows:

When both sides of the transfer are at least 3.2.0, rsync chooses the first algorithm in the client's list of choices that is also in the server's list of choices. If no common checksum choice is found, rsync exits with an error. If the remote rsync is too old to support checksum negotiation, a value is chosen based on the protocol version (which chooses between MD5 and various flavors of
MD4 based on protocol age).

So, what is done depends on the version of your local and the remote rsync, and the order of the list of hashes.

If both local and remote rsync have the same list of hashes as yours does here, the first one is chosen. That is xxh128.

8
  • Thank you Marcus, I read the docs and it mentioned auto-negotiation for remote, but for the local, it is top-down that I wanted to confirm. The uses of brackets confused me, I also read a doc on git hub but that didn't mention the alias of xx64 as xxhash. Commented Mar 6, 2023 at 17:39
  • but the official documentation is explicit - so that's what I trust. Commented Mar 6, 2023 at 17:42
  • sorry , If I sounded wrong, let me rephrase, I wanted to confirm that my understanding was correct. I am in no position to question the documentation..DO you have any idea what the STR is? Commented Mar 6, 2023 at 17:46
  • STR is a placeholder, which you replace with one of the valid hash names. So, with xxh128, or xxh3, or xxh64, or md5 or … Commented Mar 6, 2023 at 17:52
  • 1
    Yes, probably . Commented Mar 7, 2023 at 7:22

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.