Author

Topic: Bitcoin Core & pruning mode (Read 6269 times)

HCP
legendary
Activity: 2086
Merit: 4361
December 08, 2017, 08:51:50 PM
#19
The parameter is the number of blocks.
are you sure?

Reduce storage requirements by enabling pruning (deleting) of old blocks. This allows the pruneblockchain RPC to be called to delete specific blocks, and enables automatic pruning of old blocks if a target size in MiB is provided. This mode is incompatible with -txindex and -rescan. Warning: Reverting this setting requires re-downloading the entire blockchain. (default: 0 = disable pruning blocks, 1 = allow manual pruning via RPC, >550 = automatically prune block files to stay under the specified target size in MiB)

Given that blocks used to be 1MiB... it would have been the same... since SegWit and the slightly larger than 1MiB blocks, it is likely that it won't be the same anymore Wink Either way, OP still got the number out by a factor of 1000 Tongue
legendary
Activity: 2030
Merit: 1076
A humble Siberian miner
December 08, 2017, 02:06:20 PM
#18
Yep, I got it. ) It's 5000 now...
legendary
Activity: 2674
Merit: 2965
Terminated.
December 08, 2017, 04:37:41 AM
#17
Code:
prune=5000000
You've set the prune to the last 5 million blocks, that's why. The parameter is the number of blocks.
legendary
Activity: 2030
Merit: 1076
A humble Siberian miner
December 08, 2017, 02:30:30 AM
#16
Well, I'm using Bitcoin Core 0.15.1.

I've inserted a line in my bitcoin.conf:

Code:
prune=5000000

But after the Bitcoin Core starts the blockchain doesn't became "pruned" to 5 Gb. It's still 150+ Gb.

Shoud I do some further actions to reduce the blockchain size?

 
staff
Activity: 3458
Merit: 6793
Just writing some code
May 18, 2017, 06:05:11 PM
#15
Will Bitcoin Core need to re-sync or validate the blockchain all over again (which will take 4-5 days)?
No. It will just delete the stuff it doesn't need.
jlp
sr. member
Activity: 266
Merit: 264
May 18, 2017, 05:15:17 PM
#14
I've already synchronized the block with prune=2096 in bitcoin.conf.  Can I simply change this to prune=550 and relaunch Bitcoin Core?  Will it reduce the block folder down to 550MiB?
Yes.

Will Bitcoin Core need to re-sync or validate the blockchain all over again (which will take 4-5 days)?
staff
Activity: 3458
Merit: 6793
Just writing some code
May 17, 2017, 04:02:36 PM
#13
I've already synchronized the block with prune=2096 in bitcoin.conf.  Can I simply change this to prune=550 and relaunch Bitcoin Core?  Will it reduce the block folder down to 550MiB?
Yes.
jlp
sr. member
Activity: 266
Merit: 264
May 17, 2017, 03:44:49 PM
#12
Just use the default prune size of 550. It is the smallest size but still provides sufficient protection against reorgs as it stores ~2 days worth of blocks.

I've already synchronized the block with prune=2096 in bitcoin.conf.  Can I simply change this to prune=550 and relaunch Bitcoin Core?  Will it reduce the block folder down to 550MiB?
staff
Activity: 3458
Merit: 6793
Just writing some code
May 17, 2017, 03:20:12 PM
#11
What are blockchain reorgs?
Reorgs are short for reorganizations. These happen when there are forks in the blockchain and your node switches from one fork to a different fork.

I want to use Bitcoin Core, but I would prefer to store as little of the blockchain as possible.  Is there an optimal size for the pruned block folder?
Just use the default prune size of 550. It is the smallest size but still provides sufficient protection against reorgs as it stores ~2 days worth of blocks.
jlp
sr. member
Activity: 266
Merit: 264
May 17, 2017, 03:03:34 PM
#10
What are benefits of setting prune to be anything greater than 550, such as 551, 2000, 3000?
You will be storing more of the blockchain and thus be less likely to be affected by very large blockchain reorgs.

What are blockchain reorgs?

I want to use Bitcoin Core, but I would prefer to store as little of the blockchain as possible.  Is there an optimal size for the pruned block folder?

staff
Activity: 3458
Merit: 6793
Just writing some code
May 17, 2017, 01:22:56 PM
#9
What are benefits of setting prune to be anything greater than 550, such as 551, 2000, 3000?
You will be storing more of the blockchain and thus be less likely to be affected by very large blockchain reorgs.

I'm planning to run Bitcoin Core 0.14.1 on two machines:  one that is online and another that is offline (hence offline wallet).  I'll have to update the blockchain once in a while on my online machine.  The offline machine will be the same physical machine except booted from a Ubuntu USB stick.  To run Bitcoin Core on the offline machine, I was thinking of running Bitcoin Core from the same USB stick.  Is this do-able?

On the rare occasion that I use my offline machine, I was thinking that I would copy the block folder from the online machine onto a second USB stick, go offline, boot up Ubuntu from the first USB stick, copy the block folder from the second USB stick to the first USB stick.  This way, when I launch Bitcoin Core from the first USB stick, it would be synced and therefore I will be able to send out bitcoins.

Does this sound do-able?
Yes.
jlp
sr. member
Activity: 266
Merit: 264
May 17, 2017, 01:12:28 PM
#8
Also minimal number from that command line to start prune mode: "550" - is it linked directly to disk space pruned blockchain will take?
That number is the number of Megabytes to allocate for block and undo files. Each block can have up to 1 Mb of block file and 1 Mb of undo file. 550 will thus store, at a minimum, ~2 days of blocks.

What are benefits of setting prune to be anything greater than 550, such as 551, 2000, 3000?

I'm planning to run Bitcoin Core 0.14.1 on two machines:  one that is online and another that is offline (hence offline wallet).  I'll have to update the blockchain once in a while on my online machine.  The offline machine will be the same physical machine except booted from a Ubuntu USB stick.  To run Bitcoin Core on the offline machine, I was thinking of running Bitcoin Core from the same USB stick.  Is this do-able?

On the rare occasion that I use my offline machine, I was thinking that I would copy the block folder from the online machine onto a second USB stick, go offline, boot up Ubuntu from the first USB stick, copy the block folder from the second USB stick to the first USB stick.  This way, when I launch Bitcoin Core from the first USB stick, it would be synced and therefore I will be able to send out bitcoins.

Does this sound do-able?
staff
Activity: 3458
Merit: 6793
Just writing some code
September 03, 2016, 09:06:52 AM
#7
OK, I have a question. Say: I enabled prune mode and Bitcoin Core effectively started working in this mode.
But it is one way ticket if I ever want to go back to 'full' mode I need to download and verify whole blockchain once again there is no shortcuts?
Yes, you will have to redownload the entire blockchain, there are no shortcuts

Also minimal number from that command line to start prune mode: "550" - is it linked directly to disk space pruned blockchain will take?
That number is the number of Megabytes to allocate for block and undo files. Each block can have up to 1 Mb of block file and 1 Mb of undo file. 550 will thus store, at a minimum, ~2 days of blocks.
legendary
Activity: 1596
Merit: 1005
★Nitrogensports.eu★
September 03, 2016, 02:33:49 AM
#6
OK, I have a question. Say: I enabled prune mode and Bitcoin Core effectively started working in this mode.
But it is one way ticket if I ever want to go back to 'full' mode I need to download and verify whole blockchain once again there is no shortcuts?

Also minimal number from that command line to start prune mode: "550" - is it linked directly to disk space pruned blockchain will take?
staff
Activity: 3458
Merit: 6793
Just writing some code
August 28, 2016, 01:09:49 PM
#5
I read both releases notes you gave me but I still don't fully get it. I mean I understand that to disable it I should set it to "0" but to enable , I should put any number between 0-550 and that will enable it ?  Huh 1 should do the job ?
Put any number 550 or above in order to enable pruning. 550 is the minimum.
legendary
Activity: 2674
Merit: 2965
Terminated.
August 28, 2016, 01:09:31 PM
#4
I read both releases notes you gave me but I still don't fully get it. I mean I understand that to disable it I should set it to "0" but to enable , I should put any number between 0-550 and that will enable it ?  Huh 1 should do the job ?
You need to set it to a minimum of 550 for it to work. Read:
Quote
The minimal value above 0 is 550.
staff
Activity: 3500
Merit: 6152
August 28, 2016, 12:52:17 PM
#3
I read both releases notes you gave me but I still don't fully get it. I mean I understand that to disable it I should set it to "0" but to enable , I should put any number between 0-550 and that will enable it ?  Huh 1 should do the job ?
legendary
Activity: 2674
Merit: 2965
Terminated.
August 28, 2016, 03:10:24 AM
#2
1. How to activate this pruning mode ? I assume It's not automatic
No, it's not automatic. To enable pruning you have to:
2. Pruning mode will work with SegWit , and other features or downloading the whole blockchain is needed
I don't see a reason for which it shouldn't work with Segwit (i.e. why implement it in the first place if you're going to invalidate it +0.1.1 versions later).
staff
Activity: 3500
Merit: 6152
August 28, 2016, 02:43:59 AM
#1
I totally forgot about this pruning mode until I saw Knightdk post answering Amph in the thread where 0.13.0 release was announced...

and since there is some cool new features in Bitcoin core 0.13.0 and upcoming versions as well ,I want to use it but I want to know couple of things first .

1. How to activate this pruning mode ? I assume It's not automatic
2. Pruning mode will work with SegWit , and other features or downloading the whole blockchain is needed
Jump to: