Chainstate database verification

0

When you download the blockchain, do you download the chainstate too or it has to be generated by your own machine (it says that theoretically can be rebuilt from the block data but it is time consuming)? If it is downloaded how do we verify the integrity of the chainstate database?

Consy

Posted 2017-04-09T16:10:40.707

Reputation: 221

Answers

0

The chainstate is generated as a side effect of validating the blockchain.

Pieter Wuille

Posted 2017-04-09T16:10:40.707

Reputation: 54 032

So if I understand you correctly, there is no need to scan through the whole GBs worth of blockchain to generate chainstate for the first time setting up my machine, instead it will be populated along with the growth of blockchain?Consy 2017-04-09T23:52:46.703

When you initially synchronize with the network, you download all of the historical blocks, and validate those. As a side effect, the chainstate is generated. After validating you can throw away the blocks (pruning mode).Pieter Wuille 2017-04-10T04:53:55.093