[bittorrent] question on the blocks downloading in BT

Elliott Mitchell ehem at m5p.com
Sun Jun 12 01:58:40 EDT 2005


>From: Tom H. Lan <tomlan at ust.hk>
> > You have to worry about it, but the strategy needn't be quite so drastic.
> > In this case you merely need to redownload the pieces that you didn't get
> > from the existing peer. You combine these duplicates with the ones that
> > you'd already downloaded from the peer. If these together verify
> > correctly you can attribute the bad block to one of the peers that didn't
> > give you the entire piece. If this doesn't verify you blame the new peer,
> > disconnect and keep the older blocks.
> 
> You refer to redownloading. Does the peer just ask its neighbors to upload
> some block from some piece to some piece? Or it just asks its neighbor to 
> upload
> the half-baked block but do not inform them which piece it needs.

Huh? Simply ask for the required blocks using the normal protocol.

For an example. Imagine getting  piece #n blocks 1-4 from peer 1, and
piece #n blocks 5-8 from peer 2, due to peer 1 disconnecting;
subsequently piece #n fails hash check. You now ask for piece #n blocks
1-4 from peer 2. If piece #n now checks correctly, peer 1 was at fault.
If piece #n doesn't check correctly, peer 2 was at fault, and blocks 1-4
from peer 1 can still be used.

> I think it is better to say whether the piece has ID so that peers know 
> which piece in which block is missing.

Huh? The peers never know which blocks of a piece you're missing, unless
you ask them for those blocks. Or if you advertise possession of the
piece, at which point they know you've got all the blocks (though you can
lie on the premise that you'll have all of them imminently).


-- 
(\___(\___(\______          --=> 8-) EHM <=--          ______/)___/)___/)
 \BS (    |         EHeM at gremlin.m5p.com PGP 8881EF59         |    )   /
  \_CS\   |  _____  -O #include <stddisclaimer.h> O-   _____  |   /  _/
    \___\_|_/82 04 A1 3C C7 B1 37 2A*E3 6E 84 DA 97 4C 40 E6\_|_/___/





More information about the BitTorrent mailing list