0

So I'm trying to set up a full bitcoin node. I compiled bitcoin core fine and I created a config file. I want to download the entire history of the blockchain, so I created a bitcoin.conf file in my ./bitcoin folder (the folder that I cloned from github). My file originally looked like:

txindex=1
prune=9
maxconnections=15
dbcache=150
maxmempool=150
maxreceivebuffer=2500
maxsendbuffer=500

Then I ran bitcoind -daemon but realized that when I was running bitcoin-cli getrawtransaction 32892hf9nvh9832948294383 (fake tx number) that it was returning an error saying that there is no such mempool transaction. I realized my mistake was putting prune in my bitcoin.conf file. So I removed that line so that my file now looks like:

txindex=1
maxconnections=15
dbcache=150
maxmempool=150
maxreceivebuffer=2500
maxsendbuffer=500

Then I ran bitcoin-cli stop, then ran bitcoind -daemon -reindex. I thought this would be fine, but I'm still getting that no mempool transaction error when I try looking at that same transaction - and I verified that the process of download the blockchain has already moved past that transaction date because I ran bitcoin-cli getblockchaininfo and I looked at the time key.

Do I have to wait for the entire blockchain to be downloaded before I run these commands? I'd like to know before I waste a bunch of time doing this the wrong way.

I appreciate your help - thanks!

2
  • 1
    I realized I misinterpreted your question, focusing on the error message rather than what you're doing. Normally, the getrawtransaction <txid> RPC only works for mempool transactions, but with txindex enabled it should work for confirmed transactions too. My guess is that perhaps the txindex hasn't caught up with synchronization so it's giving that error still, but I'm not entirely sure what's going on. Sep 29, 2023 at 2:38
  • @PieterWuille as long as my config file is looking fine then I'm willing to wait it out and see if it works. Sep 29, 2023 at 2:49

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.