Behavior of --checksum, suggestion
Moshe Jacobson
moshe at runslinux.net
Tue Jun 7 21:44:25 GMT 2005
Thanks for the prompt reply, Wayne.
I just did a test and found that --partial will prevent rsync from
transferring the entire file again when the mtimes vary but the sizes
are the same. I suppose this is sufficient, but how does it determine
that the files are the same if it's not doing a checksum or
transferring the entire file?
Moshe
whole file again if the size is the same and the mtime is different
On Tue, 7 Jun 2005, Wayne Davison wrote:
> On Tue, Jun 07, 2005 at 04:46:43PM -0400, Moshe Jacobson wrote:
>> Is this something that would be hard to implement?
>
> Yes, it would be rather awkward in the current protocol. The way things
> currently work, the receiving side needs to have all relevant info
> already available in order to decide what files to send. One possible
> solution would be to add an extra "phase" prior to the file-transfer
> phase (before the receiving side forks) where the receiver makes a pass
> through the files and requests checksums for files that might need to be
> transferred, and then proceeds on to the normal checksum-sending phase
> (after forking) but with an optimization that allows it to avoid calling
> stat() on all the files all over again (it would flag changed files,
> required dirs, etc. during the earlier checksum phase).
>
> So, that would be quite a big change, which probably means that it won't
> happen -- at least, not in the current rsync (hopefully a future,
> improved-protocol rsync will be more flexible in this regard, and it
> would sure be nice to get around to working on it again before too
> long).
>
> ..wayne..
>
--
Moshe Jacobson -- http://runslinux.net -- AIM: Jehsom
| This message is strictly confidential; it should be shown to nobody |
| except the listed addressee(s). If you've received this message in |
| error, please promptly delete it and notify the sender. |
More information about the rsync
mailing list