[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [coldsync-hackers] Hotsync proxy to coldsync ...



On Mon, Nov 05, 2001 at 12:53:07PM -0500, JD Smith wrote:
> I use this to avoid having the fast/slow sync issue when I sync on my
> laptop.  That way, I can always use the "-F" option.  Rsync is probably
> pretty close in terms of network usage as a record-based system you
> describe is, though it is somewhat more computationally intensive, since
> it has no notion of the granularity of the data.  For small data sets
> like Palm dumps though, these syncs really fly (e.g. faster than
> fast-syncing the Palm when used over a 28Kb modem).
> 
> For a nice whitepaper describing the algorithm, see
> http://rsync.samba.org/rsync/tech_report/

	Thanks for the pointer. Quite an interesting paper.
	I think it should be possible to use something like this to
sync PDB files between two Unix machines, but since we already know
something about the files we'll be dealing with, it should be possible
to improve upon this.
	For starters, a PDB is record-based, which means that you
don't have to go through the convolutions that 'rsync' does to find a
matching block. If the remote machine sends a
	(record-ID, flags, simple-checksum, md4-checksum)
tuple for each record, then the local machine can use the record ID
and only check that record. (For completeness, it might be nice to
check to see if there's an identical local record with a different ID,
but ColdSync has traditionally ignored this: different records with
identical contents are different records.)
	The above information ought to be enough to determine which
records need to be transferred. If the records are long enough, it
might even be worth applying rsync's algorithm to individual records.

	Another important difference is that rsync copies files, it
doesn't do two-way syncing. Here, if you start with files
	A: foo		B: foo
	   bar		   quux
	   baz		   baz
you want to wind up with both A and B being
	foo
	bar
	quux
	baz

	Lastly, conventional wisdom has it that the order of records
in a PDB doesn't matter (there's been some discussion of that on this
list, but for now I'm going to assume that the order doesn't matter;
and if it does, the sort block can be used).

-- 
Andrew Arensburger                      This message *does* represent the
arensb@ooblick.com                      views of ooblick.com
	Crime doesn't pay, but at least you're your own boss.
This message was sent through the coldsync-hackers mailing list.  To remove
yourself from this mailing list, send a message to majordomo@thedotin.net
with the words "unsubscribe coldsync-hackers" in the message body.  For more
information on Coldsync, send mail to coldsync-hackers-owner@thedotin.net.