Skip to main content

All Questions

Tagged with
Filter by
Sorted by
Tagged with
1 vote
1 answer
73 views

I can't parse the UTXO from the chainstate

I have a problem with reading tx out from the Bitcoin Core LevelDB chainstate storage. I know that the structure of the current version of the chainstate is key => value where the key is a prefix (...
Novak's user avatar
  • 41
2 votes
1 answer
114 views

When does chainstate get updated?

What i'm trying to do now is reading LevelDB at chainstate folder to save all utxos at my own DB, and keep tracking the changes of utxos by looking at chainstate folder frequently. However, what i ...
Jin's user avatar
  • 61
1 vote
0 answers
98 views

Cannot unserialize chainstate transaction outputs after de-obfuscation

I was able to read chainstate database. Getting the key and de-obfuscating to get a valid last block. However, when it comes to transactions that follow after that, I cannot de-serialize them no ...
Anonymous's user avatar
  • 111
6 votes
1 answer
418 views

When the UTXO in the cache is full, what strategy is used to replace one UTXO with another in the cache?

The UTXO set is stored on the disk, but some UTXOs are also stored in the cache. When validating a transaction, you need to query the UTXO pointed to by the input of the transaction. First, you go to ...
GoneV's user avatar
  • 185
2 votes
1 answer
479 views

bitcoin chainstate database parsing in python giving wrong value

I am trying to decode chainstate db for a specific out index for a transaction in python just for learning. Transaction ID: 4d4a4c6ca4f3c91e69563199943336d3279fad71c9e8d9c1708ef9dc6ac16000 out index = ...
Vizeet Srivastava's user avatar
3 votes
2 answers
752 views

CVarint serialization format

Recently I started analyzing the UTXO set data that every full node stores in chainstate folder (a LevelDB database). By looking into the code you can learn more or less how the data entries are ...
sr_gi's user avatar
  • 3,260
12 votes
1 answer
6k views

Why is Bitcoin Core using LevelDB instead of Redis or SQLite?

Why did Core move from BDB to LevelDB? Why don't they use SQLite or move to Redis now? Is there a technical reason for this choice?
Etherkimist's user avatar
0 votes
1 answer
633 views

What is the memory usage for checking transaction inputs?

Whenever a transaction is received by a node, the node verifies its validity. To that end, it checks for each transaction input whether that input is part of the UTXO set. It is my understanding that ...
Murch's user avatar
  • 77.8k
6 votes
1 answer
639 views

Why does bitcoind use a fork of LevelDB for key-value storage?

Since 0.8 bitcoind uses LevelDB for the storage of the UTXO set in chainstate/ and the block index in blocks/index/. On github special branch of LevelDB can be found: https://github.com/bitcoin/...
Felix Weis's user avatar
2 votes
1 answer
261 views

How does serializing in coins.h work?

I'm talking specifically about this: /** pruned version of CTransaction: only retains metadata and unspent transaction outputs * * Serialized format: * - VARINT(nVersion) * - VARINT(nCode) * - ...
stanm87's user avatar
  • 237