2
1
I've have a fully tx index node in v.11 and I can do the following below just fine,
bitcoin-cli getrawtransaction c6556ca7e143d108f5ef594057ff83a78bceb4b5fdc565ae160b4783cddad00f
but with a fully tx index node in v.12, I cannot and I get an error
error code: -5
error message:
No information available about transaction
So what has change in v.12 that broke this and what can do to get this functionality back. I already have txindex=1 in my conf file and I already tried bitcoind -daemon -reindex
Are you sure you're fully synced with the 0.12 node? – Pieter Wuille – 2016-07-07T14:08:32.520
Ah, I know the issue. I was not upgrading from .11 to .12, but was running on a fresh install. So it seems like doing "bitcoind -daemon -reindex" without ever having started the daemon before wont do the tx indexing. I must first download the blockchain then do restart bitcoind with "bitcoind -daemon -reindex". That was a bit confusing. It would be cool if bitcoin core can do tx indexing on the first run. Or at least throw an error when running bitcoin core for the first time with the command "bitcoind -daemon -reindex" – user299648 – 2016-07-08T08:08:02.030
It can do txindex on the first run. You need to pass -txindex or txindex=1 in bitcoin.conf at first run to do so. – Pieter Wuille – 2016-07-08T09:44:33.163
Hmm. That was exactly what I did though. I did both of those things. – user299648 – 2016-07-08T18:41:33.083
On a side note. When I do have a fully tx index chain, it means that I can get any tx if I give it the txid right? Because I'm having some issues with that. I have 2 nodes (one v.11 and one v.12) at head (block 419860) and I can get the raw coinbase transaction in block 419859 with (bitcoin-cli getrawtransaction f59d720254b3059db5b397b25312d5e8edb7d7112464f87bf366a593a0b97dc2), but I cannot get the any other tx in the block. For example the 2nd tx in block 419859 with "bitcoin-cli getrawtransaction 437be0c5b1f18c8e87a7b11c91269cf71467165d6a9023b039f909785039e9972016". – user299648 – 2016-07-08T18:54:45.570
the reindexing takes some time, I was able to follow the progress by
tail -f ~/.bitcoin/debug.log– Jiri Kremser – 2018-05-03T11:21:02.423