public inbox for bitcoindev@googlegroups.com
 help / color / mirror / Atom feed
From: Pieter Wuille <pieter.wuille@gmail•com>
To: Bitcoin Dev <bitcoin-development@lists•sourceforge.net>
Subject: [Bitcoin-development] Ultraprune merged in mainline
Date: Sun, 21 Oct 2012 00:33:12 +0200	[thread overview]
Message-ID: <CAPg+sBjh0CTYHTZovg=wzy=YJTRwoci3QDJO=qO2kV8wQnndnA@mail.gmail.com> (raw)

Hello everyone,

I've just merged my "ultraprune" branch into mainline (including
Mike's LevelDB work). This is a very significant change, and all
testing is certainly welcome. As a result of this, many pull requests
probably don't apply cleanly anymore. If you need help rebasing them
on the new structure, ask me.

The idea behind ultraprune is to use an ultra-pruned copy (only
unspent transaction outputs in a custom compact format) of the block
chain for validation (as opposed to a transaction index into the block
chain). It still keeps all blocks around for serving them to other
nodes, for rescanning, and for reorganisations. As such, it is still a
full node. So, despite the name, it does not implement any actual
pruning yet, though pruning would be trivial to implement now. This
would have profound effects on the network though, so may still need
some discussion first.

A small summary of the changes:
 * Instead of blk000?.dat, we have blocks/blk000??.dat files of max
128 MiB, pre-allocated per 16 MiB
 * Instead of a Berklely DB blkindex.dat, we have a LevelDB directory
blktree/. This only contains a block index, no transaction index.
 * A new LevelDB directory coins/, which contains data about the
current unspent transaction output set.
 * New files blocks/rev000??.dat contain undo data for blocks
(necessary for reorganisation).
 * More information is kept about blocks and block files, so
facilitate pruning in the future, and to prepare for a headers-first
mode.
 * Two new RPC calls are added: gettxout and gettxoutsetinfo.

The most noticeable change should be performance: LevelDB deals much
better with slow I/O than BDB does, and the working set size for
validation is an order of magnitude smaller. In the longer run, I
think it is an evolution towards separation between validation nodes
and archive nodes, which is needed in my opinion.

-- 
Pieter



             reply	other threads:[~2012-10-20 22:33 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-20 22:33 Pieter Wuille [this message]
2012-10-21  1:38 ` Arklan Uth Oslin

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='CAPg+sBjh0CTYHTZovg=wzy=YJTRwoci3QDJO=qO2kV8wQnndnA@mail.gmail.com' \
    --to=pieter.wuille@gmail$(echo .)com \
    --cc=bitcoin-development@lists$(echo .)sourceforge.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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