bnb-chain / bsc

A BNB Smart Chain client based on the go-ethereum fork
GNU Lesser General Public License v3.0
2.71k stars 1.56k forks source link

ERROR Unexpected error when getting snapshot error="unknown ancestor" blockNumber=39,378,510 blockHash=5a9470..0f6f68 #2529

Closed osizadmin closed 2 months ago

osizadmin commented 3 months ago

I install new wallet in new server with version ubuntu 22 & bsc Releases v1.4.10. its showing this error.

Error Alert: Some nodes on the Binance Smart Chain (BSC) network are encountering unexpected errors related to block decoding and an "unknown ancestor" issue. Here are the details: Error Message: ERROR[06-21|14:46:02.948] Unexpected error when getting snapshot error="unknown ancestor" blockNumber=39,378,603 blockHash=e5401d..7bbb2d Additional Errors: WARN [06-21|14:46:03.020] Failed to decode block body block=39,288,647 error=EOF

WARN [06-21|14:46:03.130] Unclean shutdown detected booted=2024-06-21T12:21:44+0000 age=2h24m19s

Please let me know how to resolve this

jingjunLi commented 3 months ago

Hi @osizadmin, you can refer to this issue for more details: https://github.com/bnb-chain/bsc/issues/2528#issuecomment-2183663447.

osizadmin commented 3 months ago

Hello jingjunLi,

Thanks for the details. I hope my issue has been resolved.

osizadmin commented 3 months ago

Hello Team,

Now currentBlock: 39970716 highestBlock: 39970455,

eth.syncing.highestBlock - eth.syncing.currentBlock -302

currentBlock (39970716) is greater than highestBlock

please let me know how to resolve this?

jingjunLi commented 3 months ago

when txIndex is in progress it is not synced yet, the highestBlock may less than the currentBlock. txIndex could take a few hours.

zzzckck commented 2 months ago

https://github.com/bnb-chain/bsc/pull/862/files#diff-3c2d807e8f58e4a69928b183eb41bdf8f33b758bc87be98b5821dbb0887bb5eeR456

image

@joeylichang can we just remove the following part of code in function: gcKVStore(...)?

// Step into the future and delete and dangling side chains
if frozen > 0 {
...
}
zzzckck commented 2 months ago

fixed in: https://github.com/bnb-chain/bsc/pull/2562

zzzckck commented 2 months ago

https://github.com/bnb-chain/bsc/pull/862/files#diff-3c2d807e8f58e4a69928b183eb41bdf8f33b758bc87be98b5821dbb0887bb5eeR456 image @joeylichang can we just remove the following part of code in function: gcKVStore(...)?

// Step into the future and delete and dangling side chains
if frozen > 0 {
...
}

removed in this PR: https://github.com/bnb-chain/bsc/pull/2582/files