I use rsync on an SSD which is slow at writing, but very fast at reading, so it is important to me to avoid writing data.
I had hoped rsync would only write changes in files when using --inplace, but it seems not: # Make a 1 GB file $ perl -e 'print "x"x1000000000' > 1g # rsync it (as expected this costs 1 GB writes) $ ./rsync-3.1.0/rsync --progress --inplace -cva 1g 1g.copy # Change the first 200 bytes inplace $ perl -e 'open(A,"+<",shift) || die; seek(A,1,1); print A "a\n"x100;' 1g.copy # rsync again $ ./rsync-3.1.0/rsync --progress --inplace -cva 1g 1g.copy I would have expected the final rsync to take 2 GB reads and 1 KB write, but it seems to take 2 GB read and 1 GB write (measured by /sys/block/sda/stat). Had it taken 2 GB reads and 1 KB writes it would have been much faster on my machine, as the 2 GB would be in the read cache. How can I tell rsync to write less given the situation above? /Ole -- Please use reply-all for most replies to avoid omitting the mailing list. To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html
