9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: forsyth@caldo.demon.co.uk
To: 9fans@cse.psu.edu
Subject: Re: [9fans] replica
Date: Wed, 29 May 2002 10:43:03 +0100	[thread overview]
Message-ID: <e8720e4b6139f331c0e930df03026a9f@caldo.demon.co.uk> (raw)

>>Then you have to spend time downloading the
>>remote file when most of the time you're going to throw it away
>>because the local file _has_ been locally modified.
>>I could have included sha1 hashes in the replica(8) metadata.
>>Oh well.  I expected this not to happen very often,
>>and so far have not been proved wrong.

the advantage of keeping a hash (eg, md5 or sha1) is that it distinguishes
contents of files, which usually is what really matters,
whereas modification times and file length by themselves
aren't really adequate (in general, in my experience).  Qid.path and Qid.vers
might do i suppose, but are unique to Plan 9, and even they can change
when the contents of a file hasn't actually changed.  the hash makes it easier
to track versions historically (eg, if i have a file with a given hash code,
i can check distribution packages or logs to see whether that file was
ever actually distributed as it stands, and if so, when).  similarly,
if i've got an external replica, i can also use
the hash values to relate it to the contents of a (worm) file system dump.
there is a risk with hashing of false hits, but perhaps venti suggests
that people can be relaxed about that if the hash is peculiar enough.

in short, i thought the use of hash values in wrap was a good idea
and was surprised it wasn't part of replica!



             reply	other threads:[~2002-05-29  9:43 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-05-29  9:43 forsyth [this message]
2002-05-29 16:32 Russ Cox
2002-07-04  9:21 okamoto
2002-07-04  9:26 Fco.J.Ballesteros
2002-07-04 10:16 okamoto
2002-07-04 10:20 Fco.J.Ballesteros
2002-07-30 12:15 Russ Cox
2004-03-24 13:20 David Presotto
2005-02-12 13:42 Sergey Reva
2005-02-12 16:15 ` Russ Cox
2006-08-25  2:30 Richard Bilson
2006-08-25  3:38 ` Lyndon Nerenberg
2006-08-25  4:08   ` geoff
2006-08-25  8:19     ` Martin Neubauer
2006-08-27 23:23       ` geoff
2006-08-28  2:46         ` Richard Bilson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=e8720e4b6139f331c0e930df03026a9f@caldo.demon.co.uk \
    --to=forsyth@caldo.demon.co.uk \
    --cc=9fans@cse.psu.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).