bitcoind assertion failed, macOS 10.13.0 #11767

issue Varunram opened this issue on November 25, 2017
  1. Varunram commented at 10:24 AM on November 25, 2017: contributor

    OS version: macOS 10.13.0 Core built on commit a933cb14c75b9c79a02f8de8397a8eae405a264f Steps to Reproduce:

    1. Standard steps to build on OSX
    2. ./bitcoind does not work and spawns the following error:
    Assertion failed: ((pindexFirstNeverProcessed != nullptr) == (pindex->nChainTx == 0)), function CheckBlockIndex, file validation.cpp, line 4203.
    Abort trap: 6
    

    Strangely enough, bitcoin-cli works, so I think this might be isolated to bitcoind and similar.

    I Didn't observe this earlier, think it may have occurred recently (or I may have done something which causes this). Any help is greatly appreciated. Thanks!

  2. MarcoFalke commented at 12:58 PM on November 25, 2017: member

    Do you see this assertion hit on main net?

    On Nov 25, 2017 05:24, "Varunram Ganesh" notifications@github.com wrote:

    OS version: macOS 10.13.0 Core built on commit a933cb1 https://github.com/bitcoin/bitcoin/commit/a933cb14c75b9c79a02f8de8397a8eae405a264f Steps to Reproduce:

    1. Standard steps to build on OSX
    2. ./bitcoind does not work and spawns the following error:

    Assertion failed: ((pindexFirstNeverProcessed != nullptr) == (pindex->nChainTx == 0)), function CheckBlockIndex, file validation.cpp, line 4203. Abort trap: 6

    bitcoin-cli works though, so that's weird.

    Didn't observe this earlier, think it may have occurred recently (or I may have done something which causes this). Any help is greatly appreciated. Thanks!

    — You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/bitcoin/bitcoin/issues/11767, or mute the thread https://github.com/notifications/unsubscribe-auth/AGGmv8XEmX9nWqPveIID2DYsTUFUyqNjks5s5-rdgaJpZM4QqYTO .

  3. Varunram commented at 1:25 PM on November 25, 2017: contributor

    Yep, same with testnet and regtest too.

  4. TheBlueMatt commented at 1:34 PM on November 25, 2017: member

    Well you obviously shouldn't be seeing an assertion failure either way, but CheckBlockIndex shouldn't be called in normal runtime - it's gated by the -checkblockindex option which defaults to false on mainnet.

    On November 25, 2017 2:24:10 AM PST, Varunram Ganesh notifications@github.com wrote:

    OS version: macOS 10.13.0 Core built on commit a933cb14c75b9c79a02f8de8397a8eae405a264f Steps to Reproduce:

    1. Standard steps to build on OSX
    2. ./bitcoind does not work and spawns the following error:
    Assertion failed: ((pindexFirstNeverProcessed != nullptr) ==
    (pindex->nChainTx == 0)), function CheckBlockIndex, file
    validation.cpp, line 4203.
    Abort trap: 6
    

    bitcoin-cli works though, so that's weird.

    Didn't observe this earlier, think it may have occurred recently (or I may have done something which causes this). Any help is greatly appreciated. Thanks!

    -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/bitcoin/bitcoin/issues/11767

  5. MarcoFalke commented at 2:02 PM on November 25, 2017: member

    Mind to provide some further details?

    • The most recent date without this issue (commit or rough time).
    • The bitcoin.conf or command line args or debug.log

    On Nov 25, 2017 08:25, "Varunram Ganesh" notifications@github.com wrote:

    Yep, same with testnet and regtest too.

    — You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/bitcoin/bitcoin/issues/11767#issuecomment-346940470, or mute the thread https://github.com/notifications/unsubscribe-auth/AGGmv1SEFM-i96x_KZ3fuTVo-pHpkVkXks5s6BVYgaJpZM4QqYTO .

  6. Varunram commented at 2:45 PM on November 25, 2017: contributor

    I think I got the solution. I had another instance of Core, figured out that would interfere and changed the data dir and boom, it worked. So I guess, this ain't a bug, but maybe a more helpful error message would've been great. Thanks for responding!

  7. MarcoFalke commented at 3:01 PM on November 25, 2017: member

    I don't think we can provide helpful error messages when the datadir ends up in a consensus incompatible state. (Assuming that this is what happened here)

    On Nov 25, 2017 09:45, "Varunram Ganesh" notifications@github.com wrote:

    I think I got the solution. I had another instance of Core, figured out that would interfere and changed the data dir and boom, it worked. So I guess, this ain't a bug, but maybe a more helpful error message would've been great. Thanks for responding!

    — You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/bitcoin/bitcoin/issues/11767#issuecomment-346944646, or mute the thread https://github.com/notifications/unsubscribe-auth/AGGmvy0nVe0IcZ682d-bzLklVLzdwZxnks5s6CgEgaJpZM4QqYTO .

  8. TheBlueMatt commented at 3:03 PM on November 25, 2017: member

    What is "another instance of Core"? I'm not aware of any cases that could trigger this, except possibly if you ran some other Software that wrote garbage to your chain state (eg a BCH fullnode, btc1, etc)

    On November 25, 2017 6:45:11 AM PST, Varunram Ganesh notifications@github.com wrote:

    I think I got the solution. I had another instance of Core, figured out that would interfere and changed the data dir and boom, it worked. So I guess, this ain't a bug, but maybe a more helpful error message would've been great. Thanks for responding!

    -- You are receiving this because you commented. Reply to this email directly or view it on GitHub: https://github.com/bitcoin/bitcoin/issues/11767#issuecomment-346944646

  9. Varunram commented at 3:21 PM on November 25, 2017: contributor

    Nah, I'm not attracted to trash, so no problems there. Here's what I did:

    1. I currently have two clones - one on commit 6157e8ce3937af3f46d3e7dd922d19d6dc272145 running at ~/bitcoin and another on ~/temp/bitcoin (used to test #11731 with master in this case)

    2. I use the one at ~/bitcoin with the default home directory (~/Library/Application\ Support/Bitcoin/) to run a regtest node. I did not sync any block on mainnet.

    3. I tried to start mainnet (and others consequently) at ~/temp/bitcoin and it didn't work.

    This led me to the conclusion that it might be the data directory which may be causing problems.

    On 25 November 2017 at 20:34, Matt Corallo notifications@github.com wrote:

    What is "another instance of Core"? I'm not aware of any cases that could trigger this, except possibly if you ran some other Software that wrote garbage to your chain state (eg a BCH fullnode, btc1, etc)

    On November 25, 2017 6:45:11 AM PST, Varunram Ganesh < notifications@github.com> wrote:

    I think I got the solution. I had another instance of Core, figured out that would interfere and changed the data dir and boom, it worked. So I guess, this ain't a bug, but maybe a more helpful error message would've been great. Thanks for responding!

    -- You are receiving this because you commented. Reply to this email directly or view it on GitHub: https://github.com/bitcoin/bitcoin/issues/11767#issuecomment-346944646

    — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/bitcoin/bitcoin/issues/11767#issuecomment-346945746, or mute the thread https://github.com/notifications/unsubscribe-auth/ARvML7dA7dv7eeEPeJNkdsfs-eIj2NaVks5s6CxsgaJpZM4QqYTO .

  10. jonasschnelli added the label MacOSX on Nov 25, 2017
  11. MarcoFalke commented at 8:41 PM on November 25, 2017: member

    I am still surprised that you see that on main and test net. Would you mind double checking and sharing the corresponding debug.log or -printtoconsole?

  12. Varunram commented at 5:08 AM on November 26, 2017: contributor

    I just checked debug.log and it seems that I synced till block 115000 (must've been running in the background, my bad). Still dunno about testnet, but I shall assume that something similar would've happened since cleaning the directories, recloning and building seems to work just fine. Thanks for the inputs and sorry to have taken up your time.

  13. Varunram closed this on Nov 26, 2017

  14. MarcoFalke locked this on Sep 8, 2021

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-04-21 18:15 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me