Monero v0.14.1 has just been released with pruning. How does one activate it on the command line for ubuntu?
1 Answer
Quoting relevant part of the commit message:
There are three ways to prune a blockchain:
- run monerod with --prune-blockchain
- run "prune_blockchain" in the monerod console
- run the monero-blockchain-prune utility
The first two will prune in place. Due to how LMDB works, this will not reduce the blockchain size on disk. Instead, it will mark parts of the file as free, so that future data will use that free space, causing the file to not grow until free space grows scarce.
The third way will create a second database, a pruned copy of the original one. Since this is a new file, this one will be smaller than the original one.
Once the database is pruned, it will stay pruned as it syncs. That is, there is no need to use --prune-blockchain again, etc.
-
So the best method is to just use the third option by running the command monero-blockchain-prune ? Then I can delete the lmdb file? and how do I make it use the pruned db file?– Patoshi パトシ ♦Commented Jun 17, 2019 at 14:44
-
1Currently I just did the first option and its pruned, but it still takes up the 71GB of space? how do I convert it to the 25gb file?– Patoshi パトシ ♦Commented Jun 17, 2019 at 14:45
-
2As per the quote, the first 2 options wont free disk space, they just make space in the database available for future needs. You can still use the 3rd option on an already pruned database. That will then reduce the database size freeing up disk space. Commented Jun 17, 2019 at 15:18
-
1That's odd, who would want to use option #1 or #2 when #3 makes more sense in any scenario. thanks.– Patoshi パトシ ♦Commented Jun 17, 2019 at 15:19
-
2Not really. They are all valid options. E.g. if I'm happy with the current 70G being used now but don't want to have to use more in the next N years, pruning now ensures I won't need more disk space for a considerable amount of time. However, if I need to free up some of that 70G now, the 3rd option works best for me. Commented Jun 17, 2019 at 15:24