🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.software.nntp
Article #63739

Re: xBin and PARity files

#63739
From: Kjetil Torgrim Homme
Date: Fri, 31 Jan 2003 14:54
75 lines
3855 bytes
[Curt Welch]:
>
>   > >    $H hash
>   > >    $S file size
>   > >    $o segment offset in hash blocks
>   > >    $s segment size in hash blocks
>   > >    $P parity sequence number
>   > >    $N number of segments spanned by parity data (100 in my example
>   > >    above)
>   > >
>   > > So, the data out of the full xBin file spanned by this parity data
>   > > would start at the $o offset, and would continue for $N blocks of size
>   > > $s. THis means the Message-ID for a PAR file will only have a few more
>   > > characters than a normal xBin articles.

PAR was absent from my xBin draft (I simply forgot about it :-).  just
a detail: clearly specifying either P or N is mandatory.  we could do
either:

  P  parity sequence number (defaults to 1)
  N  number of segments spanned by parity data (mandatory)

or

  P  parity sequence number (mandatory, the first file has number 1)
  N  number of segments spanned by parity data (defaults to 100)

it feels more natural to identify PAR articles by looking for P.  the
latter approach also has the advantage of giving a strong
recommendation for how many parts a PAR file should cover, and it also
reduces the msgid size slightly.

  <...~NBk...>
  <...~PC~NBk...>
  <...~PD~NBk...>

vs.

  <...~PB...>
  <...~PC...>
  <...~PD...>

(we may want to choose a different default value than 100, but it
seems a nice and round number to me.)

>   By adding in the segment offset and size (and for PAR files the par
>   sequence number) the download tool _never_ had to do anything else besides
>   look at the message-id to figure out what it has to download to complete
>   the files it's looking for.

the segment size is the size of the PAR article, right?

>   > > So, if you post a set of articles each with this number of hash blocks
>   > > each:
>   > >
>   > >    20 20 20 20 20 19 19 19 19 19 19 19 19
>   > >
>   > > You can then post par files of size 20 for the first 5
>   > > articles, and par files of size 19, which cover the last
>   > > files.  And then the par files exactly match the data they are
>   > > replacing, and if you are missing 19 blocks of data, you only
>   > > need to download 19 blocks of par file to replace it.

the algorithm I specified will actually produce the sequence

   20 20 20 20 19 19 19 19 19 19 19 19 20

where the last block is only partially full.  I don't think this
matters much, the PAR file covering the last article will simply
contain 22500 bytes more than necessary.

-- 
Kjetil T.			|  read and make up your own mind
				|  http://www.cactus48.com/truth.html
Technical Details
Message-ID: <1ry951werx.fsf@vingodur.ifi.uio.no>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.mbox.zip!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!syros.belnet.be!news.belnet.be!news.tele.dk!news.tele.dk!small.news.tele.dk!newsfeed1.e.nsc.no!nsc.no!nextra.com!uio.no!nntp.uio.no!ifi.uio.no!not-for-mail
References: <20021230133312.202$K5@newsreader.com> <20021230171837.399$Im@newsreader.com> <20030103212914.998$3s@newsreader.com> <20030130214337.749$eF@newsreader.com>

Show Full Headers
Complete Article Headers
Message-ID: <1ry951werx.fsf@vingodur.ifi.uio.no>
Subject: Re: xBin and PARity files
Date: Fri, 31 Jan 2003 14:54:42 +0000
From: Kjetil Torgrim Homme <kjetilho@haey.ifi.uio.no>
References: <20021230133312.202$K5@newsreader.com> <20021230171837.399$Im@newsreader.com> <20030103212914.998$3s@newsreader.com> <20030130214337.749$eF@newsreader.com>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.mbox.zip!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!syros.belnet.be!news.belnet.be!news.tele.dk!news.tele.dk!small.news.tele.dk!newsfeed1.e.nsc.no!nsc.no!nextra.com!uio.no!nntp.uio.no!ifi.uio.no!not-for-mail
Newsgroups: news.software.nntp
Organization: Dept. of Informatics, Univ. of Oslo, Norway
Lines: 74
NNTP-Posting-Host: vingodur.ifi.uio.no
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
X-Trace: maud.ifi.uio.no 1044024883 28589 129.240.68.200 (31 Jan 2003 14:54:43 GMT)
X-Complaints-To: abuse@ifi.uio.no
NNTP-Posting-Date: 31 Jan 2003 14:54:43 GMT
User-Agent: Gnus/5.0808 (Gnus v5.8.8) Emacs/20.7