[mirror-admin] master server sync stats and recommendations

Axel Thimm Axel.Thimm at ATrpms.net
Thu Apr 23 05:19:47 EDT 2009


On Wed, Apr 22, 2009 at 08:15:25AM -0700, Jesse Keating wrote:
> On Wed, 2009-04-22 at 17:22 +0300, Axel Thimm wrote:
> > With pure rsync I meant protocol-wise, of course we all wrap our
> > scripts around it one way or the other.
> > 
> > But as a minimal rsync & sh implementation one could have
> > 
> > rsync rsync://master/module/.lastupdated /tmp/somefile
> > diff /tmp/somefile /storage/my/local/mirror/.lastupdated > /dev/null \
> >   && rm -f /tmp/somefile && exit
> > <Full rsync command>
> 
> Um, why don't you use the rsync protocol to see if it would update the
> fullfilelist?

I wish rsync had a --check-updates option. Unfortunately, the only way
to work here in the way you describe is to screen-scrape rsync's
output, which is not only less than elegant, but also error prone to
any changes in the screen output.

> Rsync itself can tell you rather quickly if that file has
> changed, and then you're just doing a quick poke on a single file before
> turning it loose upon the rest of the filesystem.  No need to actually
> pull it down and do any diffing, just see if rsync /would/ download it.

Apart for the screen scraping argument the rsync command above would
only transfer an rsync block of 512 bytes (remember the proposed file
is 30 bytes long). Also it would really examine the contents and not
the date of the file. As someone else noted, the dates of the current
fullfilelists are randomly changed, if for example the .lastupdated
instead contains the date of the newest file, you can run the
server-side scripts as often as you like changing .lastpdated also as
often, but the client side would remain stable and not care about the
file's date.
-- 
Axel.Thimm at ATrpms.net
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
Url : http://mail.ale.org/pipermail/mirror-admin/attachments/20090423/ea5ad57b/attachment.bin 
-------------- next part --------------
--


More information about the Mirror-admin mailing list