Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chain stuck with block marked invalid #214

Closed
cipig opened this issue Oct 2, 2019 · 8 comments
Closed

chain stuck with block marked invalid #214

cipig opened this issue Oct 2, 2019 · 8 comments
Labels
bug something isn't working

Comments

@cipig
Copy link

cipig commented Oct 2, 2019

It happened a couple of times that the wallet gets stuck on a wrong chain:

2019-10-02 00:49:06 ERROR: ConnectBlock(AXE): ProcessSpecialTxsInBlock for block 00000000000003a5d1ba83349a43fd8652e1d051e402439dd96df19ec3ccee59 failed with bad-cbtx-mnmerkleroot (code 16)
2019-10-02 00:49:06 InvalidChainFound: invalid block=00000000000003a5d1ba83349a43fd8652e1d051e402439dd96df19ec3ccee59  height=334842  log2_work=69.35496350  date=2019-10-02 00:48:51
2019-10-02 00:49:06 InvalidChainFound:  current best=000000000000009a8acb2dde20eaa4a47a439e67caf215f976bbd27e33c7be3d  height=334841  log2_work=69.35494614  date=2019-10-02 00:43:57
2019-10-02 00:49:06 ERROR: ConnectTip(): ConnectBlock 00000000000003a5d1ba83349a43fd8652e1d051e402439dd96df19ec3ccee59 failed with bad-cbtx-mnmerkleroot (code 16)
2019-10-02 00:49:06 InvalidChainFound: invalid block=00000000000003a5d1ba83349a43fd8652e1d051e402439dd96df19ec3ccee59  height=334842  log2_work=69.35496350  date=2019-10-02 00:48:51
2019-10-02 00:49:06 InvalidChainFound:  current best=000000000000009a8acb2dde20eaa4a47a439e67caf215f976bbd27e33c7be3d  height=334841  log2_work=69.35494614  date=2019-10-02 00:43:57
2019-10-02 00:49:06 ProcessNewBlock : ACCEPTED
2019-10-02 00:49:06 ERROR: AcceptBlockHeader: block 00000000000003a5d1ba83349a43fd8652e1d051e402439dd96df19ec3ccee59 is marked invalid
2019-10-02 00:49:06 ERROR: invalid header received

How can i get the wallet back on the correct chain without resync?
Can't the wallet do this automagically?

Looks like the error message is wrong, since block 334842 has the same hash on block explorer: https://chainz.cryptoid.info/axe/block.dws?334842.htm
https://insight.axerunners.com/block/00000000000003a5d1ba83349a43fd8652e1d051e402439dd96df19ec3ccee59
But wallet is stuck... axe-cli reconsiderblock 00000000000003a5d1ba83349a43fd8652e1d051e402439dd96df19ec3ccee59 does not help, the same error as above is shown

@charlesrocket
Copy link
Contributor

Clients usually return to the correct tip - relay issues? mnsync reset issued before reconsidering block?

@cipig
Copy link
Author

cipig commented Oct 2, 2019

Daemon is running with litemode=1 and without wallet (compiled with --disable-wallet), so no masternode or wallet stuff included... it is for an electrum server, which does not have a wallet.
mnsync reset returns successand i see this in the log:
CMasternodeSync::SwitchToNextAsset -- Starting MASTERNODE_SYNC_WAITING
everything else remains the same... will wait and see if something changes when i let it run

@cipig
Copy link
Author

cipig commented Oct 5, 2019

Waiting doesn't change anything. In the meantime more nodes got stuck.

@charlesrocket
Copy link
Contributor

@cipig ill spin locally and inspect - looks like this is due our spork policies. same blocks on all nodes?

@cipig
Copy link
Author

cipig commented Oct 5, 2019

Thanks. Yes, it is the same block on all nodes:

2019-10-05 00:53:44 ERROR: ConnectBlock(AXE): ProcessSpecialTxsInBlock for block 000000000000011bb83878cff7d5bbc0f0d2f63ec758c756da291add06f18be8 failed with bad-cbtx-mnmerkleroot (code 16)
2019-10-05 00:53:44 InvalidChainFound: invalid block=000000000000011bb83878cff7d5bbc0f0d2f63ec758c756da291add06f18be8  height=336491  log2_work=69.38691141  date=2019-10-05 00:52:53
2019-10-05 00:53:44 InvalidChainFound:  current best=00000000000005228785790673334f8e8f0bb740166e74ad99c3366bce0b4e19  height=336490  log2_work=69.38689622  date=2019-10-05 00:48:29
2019-10-05 00:53:44 ERROR: ConnectTip(): ConnectBlock 000000000000011bb83878cff7d5bbc0f0d2f63ec758c756da291add06f18be8 failed with bad-cbtx-mnmerkleroot (code 16)
2019-10-05 00:53:44 InvalidChainFound: invalid block=000000000000011bb83878cff7d5bbc0f0d2f63ec758c756da291add06f18be8  height=336491  log2_work=69.38691141  date=2019-10-05 00:52:53
2019-10-05 00:53:44 InvalidChainFound:  current best=00000000000005228785790673334f8e8f0bb740166e74ad99c3366bce0b4e19  height=336490  log2_work=69.38689622  date=2019-10-05 00:48:29

@charlesrocket charlesrocket added the bug something isn't working label Oct 5, 2019
@cipig
Copy link
Author

cipig commented Nov 14, 2019

problem still persists, but i found a workaround:

  1. restart axed
  2. call reconsiderblock

reconsiderblock without restart does not work

@charlesrocket
Copy link
Contributor

@cipig any improvements on 1.5?

@cipig
Copy link
Author

cipig commented Feb 29, 2020

haven't seen this error again, so i think the issue can be closed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants