Skip to content

Commit eb4c43e

Browse files
committed
doc: documents how to calculate m_assumed_blockchain_size and m_assumed_chain_state_size on the release process.
1 parent b3f8228 commit eb4c43e

File tree

1 file changed

+21
-1
lines changed

1 file changed

+21
-1
lines changed

doc/release-process.md

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ Before every minor and major release:
2323
Before every major release:
2424

2525
* Update hardcoded [seeds](/contrib/seeds/README.md), see [this pull request](https://github.com/bitcoin/bitcoin/pull/7415) for an example.
26-
* Update [`src/chainparams.cpp`](/src/chainparams.cpp) m_assumed_blockchain_size and m_assumed_chain_state_size with the current size plus some overhead.
26+
* Update [`src/chainparams.cpp`](/src/chainparams.cpp) m_assumed_blockchain_size and m_assumed_chain_state_size with the current size plus some overhead (see [this](#how-to-calculate-m_assumed_blockchain_size-and-m_assumed_chain_state_size) for information on how to calculate them).
2727
* Update `src/chainparams.cpp` chainTxData with statistics about the transaction count and rate. Use the output of the RPC `getchaintxstats`, see
2828
[this pull request](https://github.com/bitcoin/bitcoin/pull/12270) for an example. Reviewers can verify the results by running `getchaintxstats <window_block_count> <window_last_block_hash>` with the `window_block_count` and `window_last_block_hash` from your output.
2929
* Update version of `contrib/gitian-descriptors/*.yml`: usually one'd want to do this on master after branching off the release - but be sure to at least do it before a new major release
@@ -336,3 +336,23 @@ bitcoin.org (see below for bitcoin.org update instructions).
336336
- Optionally twitter, reddit /r/Bitcoin, ... but this will usually sort out itself
337337

338338
- Celebrate
339+
340+
### Additional information
341+
342+
#### How to calculate `m_assumed_blockchain_size` and `m_assumed_chain_state_size`
343+
344+
Both variables are used as a guideline for how much space the user needs on their drive in total, not just strictly for the blockchain.
345+
Note that all values should be taken from a **fully synced** node and have an overhead of 5-10% added on top of its base value.
346+
347+
To calculate `m_assumed_blockchain_size`:
348+
- For `mainnet` -> Take the size of the Bitcoin data directory, excluding `/regtest` and `/testnet3` directories.
349+
- For `testnet` -> Take the size of the `/testnet3` directory.
350+
351+
352+
To calculate `m_assumed_chain_state_size`:
353+
- For `mainnet` -> Take the size of the `/chainstate` directory.
354+
- For `testnet` -> Take the size of the `/testnet3/chainstate` directory.
355+
356+
Notes:
357+
- When taking the size for `m_assumed_blockchain_size`, there's no need to exclude the `/chainstate` directory since it's a guideline value and an overhead will be added anyway.
358+
- The expected overhead for growth may change over time, so it may not be the same value as last release; pay attention to that when changing the variables.

0 commit comments

Comments
 (0)