--compare-dest weirdness

Kevin Murray k.d.murray.91 at gmail.com
Tue Jul 20 18:22:24 MDT 2010

Hi Henri

Thanks very much. LBackup looks good, but i need a solution which only
copies files which have changed, and does not link the others, as the
folder is destined for a tar archive. Also, the copied files must be
fully functional, i.e. must be whole files, not just differences like
rdiff. this is why im using rsync.

Using checksum works, however with over 600gb to backup it is not a
viable option.

the -i shows that most are being copied due to time differences, so in
theory -t should work? This does in fact work on a little test setup
on my work laptop, i will test it properly when i get home tonight.


Kevin Murray

On 20 July 2010 12:40, Henri Shustak <henri.shustak at gmail.com> wrote:
>> interestingly, i tried to see if something was wrong with my statments by doing:
>> mkdir ~/rsynctest/dir1
>> mkdir ~/rsynctest/dir2
>> mkdir ~/rsynctest/dir3
>> nano ~/rsynctest/dir1/file1 (wrote the line hello world and saved)
>> nano ~/rsynctest/dir1/file2 (wrote the line hello and saved)
>> cp ~/rsynctest/dir1/file* ~/rsynctest/dir2/
>> checked md5sums of both files in both dirs to ensure they were identical
>> the did rsync -rvu --compare-dest=/home/kevin/rsynctest/dir2/
>> /home/kevin/rsynctest/dir1/ /home/kevin/rsynctest/dir3/
>> the two files from dir1 were copied to dir3, even though identical
>> copies, with the same names, existed in dir2.
>> i also tried this again with the compare dir relative to the dest dir,
>> i.e.: rsync -rvu --compare-dest=../dir2/ /home/kevin/rsynctest/dir1/
>> /home/kevin/rsynctest/dir3/ again with same result
> I thought about this further and I think the problem you are having is that the modification times are not being preserved and you are not using the --checksum option.
> As such, I suggest that you add the --times or --checksum option and see if that helps.
> I suspect that this will solve your problem. Let me know =:^)
> ---------------------------------------------------------------------
> This email is protected by LBackup, an open source backup solution.
> Free as in freedom; LBackup is licensed under the GNU GPL
> http://www.lbackup.org

More information about the rsync mailing list