How does zsync diff against the local file without downloading the contents from the server?
How does zsync diff against the local file without downloading the contents from the server?
It works by expecting a .zsync metadata file which gets downloaded first and is used to guide the differential download.
"Rsync over HTTP — zsync provides transfers that are nearly as efficient as rsync -z or cvsup, without the need to run a special server application. All that is needed is an HTTP/1.1-compliant web server. So it works through firewalls and on shared hosting accounts, and gives less security worries."
The other child comment also touches on something that I seem to have skipped over, the .zsync metadata file which contains pre-calculated rsync hashes. Using this means software isn't needed, but during upload the file needs to be processed to produce this metadata.
> in fact, the .zsync can be generated and offered by a third party, while still leaving most of the download to the original distribution site.
So you'd zsync http://third-party/file.zsync and this file would contain the url for the main file.
> What happens if the .zsync is out of sync with the resource?
I'm not sure, I've not managed to get it working on a simple file yet.
It's just a pair of files. The big thing you're trying to transfer and the zsync file that details the content of that first file, to guide the downloader.
You don't need a plugin, you don't need to change your httpd.conf, ...