[Owncloud] Syncing and Time Synchronization

Rob Oakes lyx-devel at oak-tree.us
Wed Jul 18 19:17:55 UTC 2012


On 07/18/2012 12:45 PM, Evert Pot wrote:

It seems that a robust sync solution would make use of both server-side 
and local logic in order to perform the operation. For example, what if 
you are syncing a collection of files from the server into a partially 
completed sync on the local machine.

In this instance, I want the two to merge (somewhat gracefully). I don't 
want to have to download the entire collection again, or upload it. For 
most people (certainly me), network traffic seems as though it's the 
worst point to have a bottleneck.

In my example, where I would like to merge two existing file 
collections, it would be really useful to have a server MD5 signature 
that could be compared against the local MD5 to see if they are the 
same. If they are, move to the next in the sync.

Why not use server data, mtime, and md5 in order to fine tune the 
operation even further.:

1.) If there are complete copies of both collections (both remote and 
local) and data describing changes, determine what changes need to be 
applied to the local copies of the file or uploaded to the server. 
(Additional md5 and mtime checks might happen at the file level.)

2.) If the local collection is not in a state to make use of the data 
provided by the server, begin a "full sync" using mtime to determine 
what files have been modified or don't exist.

3.) If there are differing mtimes, make a comparison of MD5. If the MD5 
signatures match, skip the file.

If we're concerned that it is too costly to calculate full MD5 
signatures for all files, what about a partial file signature? If we 
were to sample a reasonably sized chunk from the beginning, middle, and 
end of a file, that might provide a starting place to determine which 
files need action.

In the process of trying to integrate ownCloud into my backup client, 
lack of server-side md5 has been my biggest wish. I've resorted to 
uploading XML files with the signatures. Having it available for 
propfind requests would be awesome.



More information about the Owncloud mailing list