rsync doesn't checksum for local transfers?

Shriramana Sharma samjnaa at gmail.com
Thu Dec 4 17:17:21 MST 2014


On Fri, Dec 5, 2014 at 4:30 AM,  <devzero at web.de> wrote:
> After being written to disk, for both local and remote transfers,  the
> destination file as a whole is not being re-read for checksumming.
> Checksumming is only being done for the reconstruction process:
> The checksum is calculated across the bits being received and the
> bits being read from the target file, so essentially the updated
> target file is being checksummed while it`s being written to.

Some slight modifications, including clarifications from Kevin:

For remote transfers, the integrity of the data is verified by
checksumming on-the-fly at the sending/receiving rsync instances. For
local transfers, the reading and writing are done by the same rsync
instance so such integrity verification is not required unless you
have bad RAM or storage. This means that for both local and remote
transfers, the destination file as a whole is not being re-read for
checksumming.

Note that sync may be required at the destination to actually ensure
that the received files are written to storage. Also note that an
extra rsync -c with the same source/target arguments as the first time
may be done to ensure that the received/stored files are checksum-wise
identical to the source by re-reading the files. Again, this is only
useful if the kernel will actually be accessing the data from disk
such as after clearing its read-write cache.

-- 
Shriramana Sharma ஶ்ரீரமணஶர்மா श्रीरमणशर्मा


More information about the rsync mailing list