-
Notifications
You must be signed in to change notification settings - Fork 119
Blockchain pruning with JoinMarket #431
Comments
According to this, we're fine: https://np.reddit.com/r/Bitcoin/comments/46f67s/bitcoin_v0120_has_been_tagged_for_release/d04o6n6?context=1 After someone tries this I can close the issue. |
Sendpayment and yield-generator-basic works with a pruned node on a Raspberry Pi B+
|
Thanks @dreboli |
When importing some new wallet, joinmarket instructs to run bitcoin core with -rescan option
But bitcoin-qt -prune=550 -rescan throws an error:
I didn't want to download the whole blockchain again just to prune it yet again. This way the imported wallet shows 0 balance even though it's not empty. Only new transactions (that happened after the wallet was imported) show up. (not sure what happens when the gap limit has to be raised though) Luckily I had a normal, unpruned blockchain on my desktop PC, so I made a copy of the whole ~/.bitcoin directory that also held a wallet file that already had every joinmarket wallet imported. Then pruned the copied directory on my desktop PC
The size of the directory decreased to about 2GB. Then copied the directory containing the now pruned blockchain to my pi. I'm not sure what happens when the joinmarket-wallet-xxx account uses up all the already imported addresses so the gap limit has to be raised in order to have new addresses. Will this lead to problems? |
Id be curious to hear about testing with -blocksonly mode as well. |
When the wallet creates more addresses than were imported, it will import new addresses. Since they're guaranteed to be empty rescan is not needed. https://github.com/JoinMarket-Org/joinmarket/blob/master/joinmarket/wallet.py#L229-L236 Rescan is only needed when recovering a wallet from backup. It looks like the importaddress RPC call with rescan=false works perfectly fine in pruned mode, which is what I was interested in, which means JoinMarket can indeed run in pruned mode (As long as you don't recover a wallet from backup) (so this issue can be closed after some time) For blocksonly, I just opened #436 which I think it necessary for it to work. |
My own node now runs with pruning enabled. Here are some notes since it wasn't absolutely trivial to do this.
|
Experienced similar thing after updating from 0.11.2 to 0.12, the wallet showed some extra bitcoins under Overview - Balances - Pending in bitcoin-qt. These extra coins were on old used joinmarket addresses. Did a -rescan (or -reindex, don't remember) to solve it. |
The release notes say that
JoinMarket uses
importaddress
with the rescan flag false,, which could work with pruning as long as you know for sure the addresses are empty (and JoinMarket guarantees they are.) So in principle that RPC call doesn't have to be disabled entirely.domob uses a pruned node here. On careful reading you see that even then
importaddress
didn't work.The text was updated successfully, but these errors were encountered: