--compare-dest; I'm missing the boat
Harry Putnam
reader at newsguy.com
Sat Jan 17 20:57:16 GMT 2009
Matt McCutchen <matt at mattmccutchen.net> writes:
>> And then try to sort through the output .. maybe run it in reverse and
>> sort through that output before making a final determination.
>
> You know, there are two-way synchronization tools such as unison
> ( http://www.cis.upenn.edu/~bcpierce/unison/ ) that are designed for
> this situation and would make your job much easier.
I was experimenting with unison when I hit on the scheme I laid out.
I thought unison was pretty punky compared to rsync.
Unless you use the gui version you never see the big picture. The gui
is pretty lame too, but mostly it isn't an option very often. What I
need to see (on occassion) is some indicator that I need to overwrite
completely one way or the other.
even diff -durN is more useful.. (although outputs massive quantities
of data) But at least you can create a diff that will return things
to pre changes status.
Looking at the results of rsync with the -n flag can really be a
chore...even after I've shell scripted filters to find what I want.
But I'm finding the technique using the compare-dest flag to be pretty
useful. The actual changed files usually only come down to 50-60 or
there abouts, but that number appears to be a deadening chore with
unison.
With one run, using compare-dest and the empty receiver I have the big
picture in seconds. Another few seconds to run the rsync script that
overwrites in one direction or the other.
And my cvs module and /cvsb are pretty small potatoes to rsync.
Consisting of only 23M currently, but an astounding 2610 files in that
small weight. Sizes that rsync handles effortlessly. Even comparing
2610 files to 2610 other files happens in the blink of an eye.
Also what would queer things with unison is that active work happens
in /cvsb with all the concomitant *~ files, partial unfinished
scripts, temporary directories and files that can produce.
Mind you I only need the compare-dest technique occasionally. Usually
I just know which way to run the overwriting script.
More information about the rsync
mailing list