ethereum / go-ethereum

Go implementation of the Ethereum protocol
https://geth.ethereum.org
GNU Lesser General Public License v3.0
47.42k stars 20.07k forks source link

BAD BLOCK errors #20478

Closed MysticRyuujin closed 4 years ago

MysticRyuujin commented 4 years ago

System information

Geth version: 1.9.10-unstable-f51cf573-20191212 OS & Version: Ubuntu 18.04.3

Expected behaviour

Block is imported successfully

Actual behaviour

BAD BLOCK

Number: 4385565
Hash: 0xeaba95c4970a9a0aaed6432a15ef86906db7b3ec882e1e9834c5a56a9a67c820
...
Error: invalid merkle root (remote: 57bb8a49fdbecb83bc43d1f8a2c5218052775cadf27aec4a91e80870899648de local: 540273554e5ed35860ea6cb1738581957d550d28296d3f53229059d5e76bf564)
...
ERROR[12-20|15:07:39.893] Import error                             err="invalid block 4387500: invalid merkle root (remote: 57bb8a49fdbecb83bc43d1f8a2c5218052775cadf27aec4a91e80870899648de local: 540273554e5ed35860ea6cb1738581957d550d28296d3f53229059d5e76bf564)"

Steps to reproduce the behaviour

From a fully sync'd node (Fast Sync'd > 3 months ago) geth --datadir /data/ethereum --datadir.ancient /archive/ancient export <file>

Wiped chaindata, wiped ancient folder

geth --datadir /data/ethereum --datadir.ancient /archive/ancient --syncmode full import file

Crash ( #20477 ). Restart

geth --datadir /data/ethereum --datadir.ancient /archive/ancient --syncmode full import file

This error. Restart (same command). Same error.

Backtrace

error.log

MysticRyuujin commented 4 years ago

So I haven't found time to do the extended memtest again, but I deleted the cache files like you suggested. It then ran fine for about 3 or 4 days then last night I got the mix hash digest errors again. I deleted the cache again and it picked up where it left off...

holiman commented 4 years ago

Closing this, it's getting pretty stale, and even though we never narrowed down what caused the corruption, we did at least discover the exact bit that flipped :)

istiaque010 commented 2 years ago

I am facing similar problem as follows. Error 1: BAD BLOCK Error 2: invalid proof-of-work Error 3: retrieved hash chain invalid

holiman commented 2 years ago

Please open  a new ticket, and provide full logs. Otherwise it's very difficult to analyse anything.