I have a mirroring system in place with rsync and it works well. However, moving a file causes it to be transferred again in its entirety.
Given what I know about the rsync algorithm's rolling checksum, wouldn't it be possible to:
- tar all the source files
- rsync the tar
and only incur a block-size penalty for the change in file name, after which the checksum would resynchronise? However, i don't have the temporary spool space for a large .tar file.
My questions:
Is there an efficient, read/write way to mount a filesystem as a tar, which i can rsync?
Is there a way of piping tar | rsync in some way to achieve this behaviour?
Best Answer
If you use
gzip
instead oftar
, there is thersyncable
option.Gzip
the source, then usersync
to copy it to the destination. Each night, update the gzip archive, and usersync
again.rsyncable
will update the gzip archive in such a way that it will comply with rsync's update algorithm and only the changed parts within the gzip archive are sync'ed across each night, not the whole archive.