LearnBitcoin

Bitcoin Dev Archive 2014

Increasing regularity of block times?

4 messages, 30 to 31 Oct 2014. Started by Rusty Russell.

Rusty Russell (2), Jeff Garzik, Greg Maxwell

Permalink Original thread on gnusha.org

Rusty Russell permalink original

Hi all,

        I've been toying with an algorithm to place a ceiling on
confirmation latency by allowing weaker blocks after a certain time.
Hope this isn't noise, but thought someone must have considered this
before, or know of flaws in the scheme?

Gory details: http://rustyrussell.github.io/pettycoin/2014/10/30/More-Regular-Block-Times.html

Thanks, Rusty.

Jeff Garzik in reply to Rusty Russell permalink original

That's what we do for testnet today: https://en.bitcoin.it/wiki/Testnet

If no block is found for 20 minutes, one minimum-diff block may be mined.

On Thu, Oct 30, 2014 at 7:18 PM, Rusty Russell <rusty@rustcorp•com•au> wrote:

Quoted text (18 lines)
> Hi all,
>
>         I've been toying with an algorithm to place a ceiling on
> confirmation latency by allowing weaker blocks after a certain time.
> Hope this isn't noise, but thought someone must have considered this
> before, or know of flaws in the scheme?
>
> Gory details:
> http://rustyrussell.github.io/pettycoin/2014/10/30/More-Regular-Block-Times.html
>
> Thanks,
> Rusty.
>
> ------------------------------------------------------------------------------
> _______________________________________________
> Bitcoin-development mailing list
> Bitcoin-development@lists•sourceforge•net
> https://lists.sourceforge.net/lists/listinfo/bitcoin-development
Greg Maxwell in reply to Rusty Russell permalink original

On Thu, Oct 30, 2014 at 11:18 PM, Rusty Russell <rusty@rustcorp•com•au> wrote:

Quoted text (9 lines)
> Hi all,
>
>         I've been toying with an algorithm to place a ceiling on
> confirmation latency by allowing weaker blocks after a certain time.
> Hope this isn't noise, but thought someone must have considered this
> before, or know of flaws in the scheme?
>
> Gory details:
> http://rustyrussell.github.io/pettycoin/2014/10/30/More-Regular-Block-Times.html

Irregularity is a required property for convergence. Imagine what would happen in a network where a blocks were produced at an exact interval: Almost everyone would produce one the exact same time, and the network would fragment and because the process would continue it would not converge. It is precisely the variance being some huge multiple of the network radius which allows the network to converge at all.

When lower variance is tolerable for convergence it can be achieved by reducing the expectation. Maybe some other distribution can be proven to be convergent to, it's difficult to reason about.

Bitcoin testnet implements a rule that allows lower difficulty blocks after a delay (20 minutes, in fact), but it's a testing-toy... not secure or intended to be so. At least one altcoin has copied that behavior and been exploited on account of it.

If you're simply looking for faster evidence that the network is working on a particular transaction set, at some lower timescale:, then thats already possible. e.g. look into how the p2pool sharechain builds a consensus around mining work used for pooling. The same mechanism can be used to give faster transaction selection evidence.

I'll dig up some citations for you later. Cheers.

Rusty Russell in reply to Greg Maxwell permalink original

Gregory Maxwell <gmaxwell@gmail•com> writes:

Quoted text (16 lines)
> On Thu, Oct 30, 2014 at 11:18 PM, Rusty Russell <rusty@rustcorp•com•au> wrote:
>> Hi all,
>>
>>         I've been toying with an algorithm to place a ceiling on
>> confirmation latency by allowing weaker blocks after a certain time.
>> Hope this isn't noise, but thought someone must have considered this
>> before, or know of flaws in the scheme?
>>
>> Gory details:
>> http://rustyrussell.github.io/pettycoin/2014/10/30/More-Regular-Block-Times.html
>
> Irregularity is a required property for convergence. Imagine what
> would happen in a network where a blocks were produced at an exact
> interval: Almost everyone would produce one the exact same time, and
> the network would fragment and because the process would continue it
> would not converge.

Your point is well made.

If everyone published their easy blocks at the 20 minute mark, divergence would be a problem (though with 6/7 blocks being normal, the network would probably recover). I was proposing to relay them as normal, they're just not accepted until 20 minutes.

(Though with the suggested variant of accepting the most-compatible rather than first-seen block, this isn't so critical).

Quoted text (2 lines)
> It is precisely the variance  being some huge multiple of the network
> radius which allows the network to converge at all.

I hadn't thought about it that way, but I assumed GHOST mitigate this down to some lower limit. Or?

Quoted text (4 lines)
> Bitcoin testnet implements a rule that allows lower difficulty blocks
> after a delay (20 minutes, in fact), but it's a testing-toy... not
> secure or intended to be so. At least one altcoin has copied that
> behavior and been exploited on account of it.

Agreed, that would be foolish. Note that in my proposal, block timestamps wouldn't reflect the delay (removing incentive to push timestamps forward, but making judging historical blockchain's validity harder).

Quoted text (5 lines)
> If you're simply looking for faster evidence that the network is
> working on a particular transaction set, at some lower timescale:,
> then thats already possible.  e.g. look into how the p2pool sharechain
> builds a consensus around mining work used for pooling. The same
> mechanism can be used to give faster transaction selection evidence.

Nice idea. Publishing WIP blocks like this could provide evidence, but you'd have to incentivize miners to publish them. Can you think of a way to do that (which beats simply reducing the block time)?

Quoted text (1 line)
> I'll dig up some citations for you later. Cheers.

Thanks for your time, Rusty.