Open LinkRiver-Vitor opened 8 months ago
I have the same problem, how should I recover it
{"level":"info","ts":1711357977.7955174,"caller":"synchronizer/synchronizer.go:415","msg":"L1 state fully synchronized","pid":58,"version":"v0.6.4"}
{"level":"info","ts":1711357977.7982047,"caller":"synchronizer/synchronizer.go:348","msg":"latestSequencedBatchNumber: 2002026, latestSyncedBatch: 2001448, lastVerifiedBatchNumber: 2002013","pid":58,"version":"v0.6.4"}
{"level":"info","ts":1711357977.798247,"caller":"synchronizer/synchronizer.go:394","msg":"Syncing L1 blocks sequentially lastEthBlockSynced=19494172","pid":58,"version":"v0.6.4"}
{"level":"info","ts":1711357977.8322341,"caller":"synchronizer/synchronizer.go:519","msg":"Syncing block 19494173 of 19510534","pid":58,"version":"v0.6.4"}
{"level":"info","ts":1711357977.8322897,"caller":"synchronizer/synchronizer.go:520","msg":"Getting rollup info from block 19494173 to block 19494273","pid":58,"version":"v0.6.4"}
{"level":"error","ts":1711357977.950064,"caller":"state/l1infotree.go:74","msg":"error add new leaf to the L1InfoTree. Error: mismatched leaf count: 4928, expected: 5341\n/src/log/log.go:142 github.com/0xPolygonHermez/zkevm-node/log.appendStackTraceMaybeArgs()\n/src/log/log.go:217 github.com/0xPolygonHermez/zkevm-node/log.Error()\n/src/state/l1infotree.go:74 github.com/0xPolygonHermez/zkevm-node/state.(*State).AddL1InfoTreeLeaf()\n/src/synchronizer/actions/etrog/processor_l1_info_tree_update.go:47 github.com/0xPolygonHermez/zkevm-node/synchronizer/actions/etrog.(*ProcessorL1InfoTreeUpdate).Process()\n/src/synchronizer/actions/processor_manager/processor_manager.go:66 github.com/0xPolygonHermez/zkevm-node/synchronizer/actions/processor_manager.(*L1EventProcessors).Process()\n/src/synchronizer/synchronizer.go:625 github.com/0xPolygonHermez/zkevm-node/synchronizer.(*ClientSynchronizer).ProcessBlockRange()\n/src/synchronizer/synchronizer.go:533 github.com/0xPolygonHermez/zkevm-node/synchronizer.(*ClientSynchronizer).syncBlocksSequential()\n/src/synchronizer/synchronizer.go:395 github.com/0xPolygonHermez/zkevm-node/synchronizer.(*ClientSynchronizer).Sync()\n/src/cmd/run.go:318 main.runSynchronizer()\n","pid":58,"version":"v0.6.4","stacktrace":"github.com/0xPolygonHermez/zkevm-node/state.(*State).AddL1InfoTreeLeaf\n\t/src/state/l1infotree.go:74\ngithub.com/0xPolygonHermez/zkevm-node/synchronizer/actions/etrog.(*ProcessorL1InfoTreeUpdate).Process\n\t/src/synchronizer/actions/etrog/processor_l1_info_tree_update.go:47\ngithub.com/0xPolygonHermez/zkevm-node/synchronizer/actions/processor_manager.(*L1EventProcessors).Process\n\t/src/synchronizer/actions/processor_manager/processor_manager.go:66\ngithub.com/0xPolygonHermez/zkevm-node/synchronizer.(*ClientSynchronizer).ProcessBlockRange\n\t/src/synchronizer/synchronizer.go:625\ngithub.com/0xPolygonHermez/zkevm-node/synchronizer.(*ClientSynchronizer).syncBlocksSequential\n\t/src/synchronizer/synchronizer.go:533\ngithub.com/0xPolygonHermez/zkevm-node/synchronizer.(*ClientSynchronizer).Sync\n\t/src/synchronizer/synchronizer.go:395\nmain.runSynchronizer\n\t/src/cmd/run.go:318"}
{"level":"error","ts":1711357977.9501545,"caller":"etrog/processor_l1_info_tree_update.go:49","msg":"error storing the l1InfoTree(etrog). BlockNumber: 19494192, error: mismatched leaf count: 4928, expected: 5341%!(EXTRA string=\n/src/log/log.go:142 github.com/0xPolygonHermez/zkevm-node/log.appendStackTraceMaybeArgs()\n/src/log/log.go:251 github.com/0xPolygonHermez/zkevm-node/log.Errorf()\n/src/synchronizer/actions/etrog/processor_l1_info_tree_update.go:49 github.com/0xPolygonHermez/zkevm-node/synchronizer/actions/etrog.(*ProcessorL1InfoTreeUpdate).Process()\n/src/synchronizer/actions/processor_manager/processor_manager.go:66 github.com/0xPolygonHermez/zkevm-node/synchronizer/actions/processor_manager.(*L1EventProcessors).Process()\n/src/synchronizer/synchronizer.go:625 github.com/0xPolygonHermez/zkevm-node/synchronizer.(*ClientSynchronizer).ProcessBlockRange()\n/src/synchronizer/synchronizer.go:533 github.com/0xPolygonHermez/zkevm-node/synchronizer.(*ClientSynchronizer).syncBlocksSequential()\n/src/synchronizer/synchronizer.go:395 github.com/0xPolygonHermez/zkevm-node/synchronizer.(*ClientSynchronizer).Sync()\n/src/cmd/run.go:318 main.runSynchronizer()\n)","pid":58,"version":"v0.6.4","stacktrace":"github.com/0xPolygonHermez/zkevm-node/synchronizer/actions/etrog.(*ProcessorL1InfoTreeUpdate).Process\n\t/src/synchronizer/actions/etrog/processor_l1_info_tree_update.go:49\ngithub.com/0xPolygonHermez/zkevm-node/synchronizer/actions/processor_manager.(*L1EventProcessors).Process\n\t/src/synchronizer/actions/processor_manager/processor_manager.go:66\ngithub.com/0xPolygonHermez/zkevm-node/synchronizer.(*ClientSynchronizer).ProcessBlockRange\n\t/src/synchronizer/synchronizer.go:625\ngithub.com/0xPolygonHermez/zkevm-node/synchronizer.(*ClientSynchronizer).syncBlocksSequential\n\t/src/synchronizer/synchronizer.go:533\ngithub.com/0xPolygonHermez/zkevm-node/synchronizer.(*ClientSynchronizer).Sync\n\t/src/synchronizer/synchronizer.go:395\nmain.runSynchronizer\n\t/src/cmd/run.go:318"}
{"level":"error","ts":1711357977.9501953,"caller":"synchronizer/synchronizer.go:627","msg":"error: mismatched leaf count: 4928, expected: 5341\n/src/log/log.go:142 github.com/0xPolygonHermez/zkevm-node/log.appendStackTraceMaybeArgs()\n/src/log/log.go:217 github.com/0xPolygonHermez/zkevm-node/log.Error()\n/src/synchronizer/synchronizer.go:627 github.com/0xPolygonHermez/zkevm-node/synchronizer.(*ClientSynchronizer).ProcessBlockRange()\n/src/synchronizer/synchronizer.go:533 github.com/0xPolygonHermez/zkevm-node/synchronizer.(*ClientSynchronizer).syncBlocksSequential()\n/src/synchronizer/synchronizer.go:395 github.com/0xPolygonHermez/zkevm-node/synchronizer.(*ClientSynchronizer).Sync()\n/src/cmd/run.go:318 main.runSynchronizer()\n","pid":58,"version":"v0.6.4","stacktrace":"github.com/0xPolygonHermez/zkevm-node/synchronizer.(*ClientSynchronizer).ProcessBlockRange\n\t/src/synchronizer/synchronizer.go:627\ngithub.com/0xPolygonHermez/zkevm-node/synchronizer.(*ClientSynchronizer).syncBlocksSequential\n\t/src/synchronizer/synchronizer.go:533\ngithub.com/0xPolygonHermez/zkevm-node/synchronizer.(*ClientSynchronizer).Sync\n\t/src/synchronizer/synchronizer.go:395\nmain.runSynchronizer\n\t/src/cmd/run.go:318"}
{"level":"warn","ts":1711357977.950311,"caller":"synchronizer/synchronizer.go:399","msg":"error syncing blocks: mismatched leaf count: 4928, expected: 5341","pid":58,"version":"v0.6.4"}
System information
zkEVM Node version:
v0.5.13
OS & Version:Ubuntu 22.04.4 LTS
Network:Mainnet
Expected behaviour
PoolDB and StateDB were synced via Polygon's official snapshot (https://docs.polygon.technology/zkEVM/get-started/state-sync-snapshots/) and there was no error outputed.
The expected behavior was the node to start cleanly, catching up to latest blocks naturally.
Actual behaviour
zkevm-rpc has an error stack and there is a stuck block
Steps to reproduce the behaviour
Download Polygon's official snapshots, inject sql commands into. Is there a way to set the chain head back to a previous block? This could solve the issue in this case (L1 BlockNumber: 19328412, zkEVM stuck block 10322004).
Thanks for your assistance!
Backtrace
{ "level": "error", "ts": 1710237765.7419765, "caller": "state/l1infotree.go:74", "msg": "error add new leaf to the L1InfoTree. Error: mismatched leaf count: 2247, expected: 2248 /src/log/log.go:142 github.com/0xPolygonHermez/zkevm-node/log.appendStackTraceMaybeArgs() /src/log/log.go:217 github.com/0xPolygonHermez/zkevm-node/log.Error() /src/state/l1infotree.go:74 github.com/0xPolygonHermez/zkevm-node/state.(State).AddL1InfoTreeLeaf() /src/synchronizer/actions/etrog/processor_l1_info_tree_update.go:47 github.com/0xPolygonHermez/zkevm-node/synchronizer/actions/etrog.(ProcessorL1InfoTreeUpdate).Process() /src/synchronizer/actions/processor_manager/processor_manager.go:66 github.com/0xPolygonHermez/zkevm-node/synchronizer/actions/processor_manager.(L1EventProcessors).Process() /src/synchronizer/synchronizer.go:596 github.com/0xPolygonHermez/zkevm-node/synchronizer.(ClientSynchronizer).ProcessBlockRange() /src/synchronizer/synchronizer.go:504 github.com/0xPolygonHermez/zkevm-node/synchronizer.(ClientSynchronizer).syncBlocksSequential() /src/synchronizer/synchronizer.go:412 github.com/0xPolygonHermez/zkevm-node/synchronizer.(ClientSynchronizer).Sync() /src/cmd/run.go:319 main.runSynchronizer() ", "pid": 1, "version": "v0.5.13", "stacktrace": "github.com/0xPolygonHermez/zkevm-node/state.(State).AddL1InfoTreeLeaf \t/src/state/l1infotree.go:74 github.com/0xPolygonHermez/zkevm-node/synchronizer/actions/etrog.(ProcessorL1InfoTreeUpdate).Process \t/src/synchronizer/actions/etrog/processor_l1_info_tree_update.go:47 github.com/0xPolygonHermez/zkevm-node/synchronizer/actions/processor_manager.(L1EventProcessors).Process \t/src/synchronizer/actions/processor_manager/processor_manager.go:66 github.com/0xPolygonHermez/zkevm-node/synchronizer.(ClientSynchronizer).ProcessBlockRange \t/src/synchronizer/synchronizer.go:596 github.com/0xPolygonHermez/zkevm-node/synchronizer.(ClientSynchronizer).syncBlocksSequential \t/src/synchronizer/synchronizer.go:504 github.com/0xPolygonHermez/zkevm-node/synchronizer.(ClientSynchronizer).Sync \t/src/synchronizer/synchronizer.go:412 main.runSynchronizer \t/src/cmd/run.go:319" }, { "level": "error", "ts": 1710237765.742093, "caller": "etrog/processor_l1_info_tree_update.go:49", "msg": "error storing the l1InfoTree(etrog). BlockNumber: 19328412, error: mismatched leaf count: 2247, expected: 2248%!(EXTRA string= /src/log/log.go:142 github.com/0xPolygonHermez/zkevm-node/log.appendStackTraceMaybeArgs() /src/log/log.go:251 github.com/0xPolygonHermez/zkevm-node/log.Errorf() /src/synchronizer/actions/etrog/processor_l1_info_tree_update.go:49 github.com/0xPolygonHermez/zkevm-node/synchronizer/actions/etrog.(ProcessorL1InfoTreeUpdate).Process() /src/synchronizer/actions/processor_manager/processor_manager.go:66 github.com/0xPolygonHermez/zkevm-node/synchronizer/actions/processor_manager.(L1EventProcessors).Process() /src/synchronizer/synchronizer.go:596 github.com/0xPolygonHermez/zkevm-node/synchronizer.(ClientSynchronizer).ProcessBlockRange() /src/synchronizer/synchronizer.go:504 github.com/0xPolygonHermez/zkevm-node/synchronizer.(ClientSynchronizer).syncBlocksSequential() /src/synchronizer/synchronizer.go:412 github.com/0xPolygonHermez/zkevm-node/synchronizer.(ClientSynchronizer).Sync() /src/cmd/run.go:319 main.runSynchronizer() )", "pid": 1, "version": "v0.5.13", "stacktrace": "github.com/0xPolygonHermez/zkevm-node/synchronizer/actions/etrog.(ProcessorL1InfoTreeUpdate).Process /src/synchronizer/actions/etrog/processor_l1_info_tree_update.go:49 github.com/0xPolygonHermez/zkevm-node/synchronizer/actions/processor_manager.(L1EventProcessors).Process /src/synchronizer/actions/processor_manager/processor_manager.go:66 github.com/0xPolygonHermez/zkevm-node/synchronizer.(ClientSynchronizer).ProcessBlockRange /src/synchronizer/synchronizer.go:596 github.com/0xPolygonHermez/zkevm-node/synchronizer.(ClientSynchronizer).syncBlocksSequential /src/synchronizer/synchronizer.go:504 github.com/0xPolygonHermez/zkevm-node/synchronizer.(ClientSynchronizer).Sync /src/synchronizer/synchronizer.go:412 main.runSynchronizer /src/cmd/run.go:319" }, { "level": "error", "ts": 1710237765.7421873, "caller": "synchronizer/synchronizer.go:598", "msg": "error: mismatched leaf count: 2247, expected: 2248 /src/log/log.go:142 github.com/0xPolygonHermez/zkevm-node/log.appendStackTraceMaybeArgs() /src/log/log.go:217 github.com/0xPolygonHermez/zkevm-node/log.Error() /src/synchronizer/synchronizer.go:598 github.com/0xPolygonHermez/zkevm-node/synchronizer.(ClientSynchronizer).ProcessBlockRange() /src/synchronizer/synchronizer.go:504 github.com/0xPolygonHermez/zkevm-node/synchronizer.(ClientSynchronizer).syncBlocksSequential() /src/synchronizer/synchronizer.go:412 github.com/0xPolygonHermez/zkevm-node/synchronizer.(ClientSynchronizer).Sync() /src/cmd/run.go:319 main.runSynchronizer() ", "pid": 1, "version": "v0.5.13", "stacktrace": "github.com/0xPolygonHermez/zkevm-node/synchronizer.(ClientSynchronizer).ProcessBlockRange /src/synchronizer/synchronizer.go:598 github.com/0xPolygonHermez/zkevm-node/synchronizer.(ClientSynchronizer).syncBlocksSequential /src/synchronizer/synchronizer.go:504 github.com/0xPolygonHermez/zkevm-node/synchronizer.(ClientSynchronizer).Sync /src/synchronizer/synchronizer.go:412 main.runSynchronizer /src/cmd/run.go:319" }, { "level": "warn", "ts": 1710250686.408073, "caller": "synchronizer/synchronizer.go:416", "msg": "error syncing blocks: mismatched leaf count: 2247, expected: 2248", "pid": 1, "version": "v0.5.13" }, { "level": "info", "ts": 1710250686.4086125, "caller": "synchronizer/synchronizer.go:431", "msg": "L1 state fully synchronized", "pid": 1, "version": "v0.5.13" }, { "level": "info", "ts": 1710250686.5991907, "caller": "synchronizer/synchronizer.go:367", "msg": "latestSequencedBatchNumber: 1998448, latestSyncedBatch: 1994914, lastVerifiedBatchNumber: 1998444", "pid": 1, "version": "v0.5.13" }, { "level": "info", "ts": 1710250686.599275, "caller": "synchronizer/synchronizer.go:411", "msg": "Syncing L1 blocks sequentially lastEthBlockSynced=19328387", "pid": 1, "version": "v0.5.13" }, { "level": "info", "ts": 1710250686.8075888, "caller": "synchronizer/synchronizer.go:490", "msg": "Syncing block 19328388 of 19419346", "pid": 1, "version": "v0.5.13" }, { "level": "info", "ts": 1710250686.8076491, "caller": "synchronizer/synchronizer.go:491", "msg": "Getting rollup info from block 19328388 to block 19328488", "pid": 1, "version": "v0.5.13" }