public inbox for bitcoindev@googlegroups.com
 help / color / mirror / Atom feed
From: Mike Hearn <mike@plan99.net>
To: "Bjørn Øivind Bjørnsen" <bo.bjornsen@gmail.com>
Cc: Bitcoin Dev <bitcoin-development@lists.sourceforge.net>
Subject: Re: [Bitcoin-development] About the small number of bitcoin nodes
Date: Mon, 19 May 2014 14:15:54 +0200	[thread overview]
Message-ID: <CANEZrP28PQNwuLYTgzyaTDUY-Sg2fEijiPZ26k3NbwvgYoqLww@mail.gmail.com> (raw)
In-Reply-To: <5379CE4D.5040100@gmail.com>

[-- Attachment #1: Type: text/plain, Size: 1385 bytes --]

>
> As an interested party not intimately familiar with the bitcoin codebase
> who also spent some time setting up a node a while ago, I would like to
> add one thing to the above list - network rate limiting.


The problem is that this is easier said than done. Bitcoin Core won't
notice a remote peer is working but slow and switch to a faster one, and
even if it did, it'd just mean throttling your connection would cause all
remote nodes to give up and hit the other unthrottled peers even more.

The best way to implement this is to do chain pruning, so your node will
still try and shovel bytes as fast as possible, but it's limited by how
many bytes it has to shovel. Remote nodes that are pulling down the block
chain can then switch between nodes depending on what they have available
in order to try and avoid hitting one node too hard. Nodes that were
offline for a while and just catching up would prefer nodes that have less
of the chain.

It'd be great if someone could experiment with this. The first step is
extending the p2p protocol so addr broadcasts and version messages include
how much of the chain (counting blocks from the head?) the peer is willing
to serve, and then updating the downloading code so it tries to be smarter
about peer selection. Unfortunately all this work is sort of backed up
waiting for sipa to finish merging in headers-first downloading.

[-- Attachment #2: Type: text/html, Size: 1681 bytes --]

  reply	other threads:[~2014-05-19 12:16 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-05-18 17:43 [Bitcoin-development] About the small number of bitcoin nodes Raúl Martínez
2014-05-18 20:15 ` Raúl Martínez
2014-05-19  7:11 ` Jeff Garzik
2014-05-19  7:25   ` Justus Ranvier
2014-05-19 14:02   ` Scott Howard
2014-05-19  8:48 ` Wladimir
2014-05-19 10:39   ` Wladimir
2014-05-19 10:47     ` Felipe Micaroni Lalli
2014-05-19  9:26 ` Bjørn Øivind Bjørnsen
2014-05-19 12:15   ` Mike Hearn [this message]
2014-05-19 12:24     ` Bjørn Øivind Bjørnsen
2014-05-19 12:28       ` Mike Hearn
2014-05-19 12:44   ` Wladimir
2014-05-19 12:53     ` Mike Hearn
2014-06-30 10:16 ` Wladimir

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=CANEZrP28PQNwuLYTgzyaTDUY-Sg2fEijiPZ26k3NbwvgYoqLww@mail.gmail.com \
    --to=mike@plan99.net \
    --cc=bitcoin-development@lists.sourceforge.net \
    --cc=bo.bjornsen@gmail.com \
    /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