Does that mean your node will only hold the latest 2GB of blockchain data? And what’s the benefit of increasing that limit to something like 50GB?
edit: sorry about that, I realize now this might belong in the "technical support" section, but I can't delete this post here. Would really appreciate any insights on my question.
What does limiting block storage to 2GB on a pruned node actually mean?
6 replies 59 views
gr3g.0rbitHero Member
Posts: 1025 · Reputation: 2646
#2Dec 30, 2020, 12:49 AM
Yes Literally,
It will try to keep your blockchain's size to that setting's size.
The higher the setting, the more blocks your node keep.
It's useful if you need to rescan more blocks, e.g.: when, you need to load a wallet with recent transactions.
Because it cannot rescan past the deleted blocks.
I asked a Mod to move this to that board if you can't.
Or try to use "move topic" button below (lower-left).
Yes. But FYI, other data (such as UTXO data which currently have size 11.8GB) isn't pruned. So you'll need to have free space more than 2GB in order to run Bitcoin Core.
For general usage, there's no advantage. But it may be helpful when you need to obtain older block data or accidently close wallet file for some time, where you can re-open it without making Bitcoin Core re-download whole blockchain to get all relevant TX data.
AFAIR a pruned node with loaded wallet(s) will also keep all relevant old blocks containing the wallet's transactions, even when those old blocks are past the prune limit where other blockchain's blocks would get pruned.
So for wallets with a larger transaction history over larger time spans it may be advantious to have a slightly bigger prune limit. If your storage media can easily handle it, I would suggest to set a prune limit of at least a few GB, maybe 10 or 20, which should give you plenty enough wiggle room. And yes, as ABCbits said correctly, the space requirement for the chainstate isn't pruned and comes on-top of the prune size.
With my limited experience with pruned nodes, I prefer to keep and have an unpruned node, I wouldn't close my wallet(s) if I had a pruned one and open my wallet(s) frequently to avoid surpassing the prune limit of recent blocks kept by the pruned node.
I once had the situation where I didn't open a specific wallet for weeks or months with a pruned node and when I remembered, it was too late and loading the wallet failed with that pruned node. I don't remember the details but loading this wallet would've triggered a new download and rescan of the whole blockchain for this wallet.
The pruned node was on a virtual machine with limited size of the virtual storage media where I couldn't keep a full blockchain on.
Post edit: highly likely I messed up some blurry memories and redact wrong statements I made.
Are you sure about this, because this sounds like a pointless thing to do. Your wallet only needs to store your raw transactions and maybe the block height/hash that includes that transaction (to know the number of confirmation). The rest of the data in that block is useless to your wallet.
Frankly, I'm not confidently sure about my statement. I've only some blurry memories of what a pruned node actually keeps. Sorry, if I made a bit vague or incorrect statements in this technical section.
At least a wallet in Bitcoin Core keeps its own transaction list which is not affected by pruning, loosely rephrased from Pieter Wuille's statement:
humbleledgerLegendary
Posts: 1027 · Reputation: 6554
#7Dec 30, 2020, 05:17 PM
I'm with pooya87 on this one. Keeping each block related to the wallet could easily add several GB to the blocks directory for a wallet with thousands of transactions. I don't think that happens.
Related topics
- Memory Issues with RPC API REST /rest/block/ 19
- What derivation path does mm-gen wallet use? 3
- Got a free laptop, need help setting up Linux for a node 19
- Affordable quiet mini PC for running a Bitcoin node and blockchain explorer 19
- bitcoin-qt sync issues and slow speeds 6
- Recovering a Bitcoin wallet and address 8