2 Way Syncing

Bennett Todd bet at rahul.net
Wed Feb 26 01:48:12 EST 2003


2003-02-25T08:52:38 va_public <yahoogroups at vikas.mailshell.com>:
> --- In rsync at yahoogroups.com, Wayne Davison <wayned at u...> wrote:
> > On Mon, Feb 24, 2003 at 08:13:15PM -0800, Len Sh wrote:
> > > I need to be-able to sync both ways so the files can be changed on
> > > either server? 
> > 
> > I recommend using the program "unison" for this -- I find it to be
> > indispensable.
> 
> Why not just use rsync as mentioned in the FAQ for this?
> 
> rsync --update source target
> rsync --update target source

The difference is there's a problem unison solves, that rsync
cannot.

Suppose a file is updated on both sides, between syncs?

Rsync has no way of knowing that that has happened; in the above
back-n-forth --update, rsync will overwrite the older file with the
newer; the edits made first will be lost.

Unison can recognize this situation and report the conflicting
edits.

This is possible because Unison keeps some private data, notes to
itself describing the last state in which it left the files.

Rsync on the other hand looks at only the actual state of the files
as found on disk, it has no private notes to itself. This is a
strength in some applications and a weakness in others. The two
tools solve different problems, albeit with some overlap.

-Bennett
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://lists.samba.org/archive/rsync/attachments/20030225/9c36c80d/attachment.bin


More information about the rsync mailing list