rsync efficiency

Marcelo Leal diversos at
Fri Sep 19 19:40:05 GMT 2008

 Hello all,
 I have a doubt that i think you hackers of rsync has the answer. ;-)
 I have make this post on my blog:
 to start a serie about the copy-on-write semantics of ZFS. In my test
"VI" did rewrite the whole file just for change 3 bytes, so the whole
file was reallocated.
 What i want to know from you is about the techniques used by rsync
(and about other softwares that you know), for change a few bytes in
the middle of a big file. Can be a simple question for you, but i
really think how rsync can change 18k inside a 1gb file, without
rewrite the whole file (or a lot of indirect blocks).
 If we are talking about a SO without copy-on-write filesystem, maybe
we can rewrite just that block (??), but in ZFS for example, if we
have a 128K block, and we need to add 10k, that change will propagate
to the whole tree of blocks, right?
 And i think rsync like many softwares, create a temporary file on the
destination, and the whole file is rewriten locally, just the changes
over the wire. Is that right?
 The question is: There is a efficient/safe way to change 10k of data
in a 1gb file, whithout a lot of rewrites? rsync uses some technique
for that, or is totally dependent on the filesystem?

 Thanks a lot!


--------==== pOSix rules ====-------

More information about the rsync mailing list