go-ethereum icon indicating copy to clipboard operation
go-ethereum copied to clipboard

Geth docker full node synchronisation failed. err="retrieved hash chain is invalid: missing parent"

Open abc-1211 opened this issue 2 years ago • 1 comments

System information

Geth version: 1.10.23-stable OS & Version: Ubuntu 22.04.1 LTS

Docker compose file

version: "3.8"

networks:
  mynet:

# Docker
services:
  # Geth Docker
  ethereum-geth:
    container_name: erc20
    image: ethereum/client-go:stable
    volumes: [/mydata/blockchain/erc20:/root]
    ports:
      # HTTP server / GraphQL API
      - 8545:8545
      # WebSocket
      - 8546:8546
      # Network listening port (P2P networking)
      - 30303:30303
    command: ["--syncmode=full", "--http", "--http.addr=0.0.0.0", "--ws", "--ws.addr=0.0.0.0"]
    restart: always
    logging:
      options:
        max-size: "25k"
        max-file: "5"

Expected behaviour

Connect to peers keep syncing

Actual behaviour

erc20  | WARN [09-02|04:31:12.766] Synchronisation failed, dropping peer    peer=98eff4d8cac4349efb2a5a76c3f516390059bbcc93c6220c0fe37716fa7a6dd7 err="retrieved hash chain is invalid: missing parent"
erc20  | INFO [09-02|04:31:15.255] Looking for peers                        peercount=2 tried=37 static=8
erc20  | WARN [09-02|04:31:30.042] Synchronisation failed, dropping peer    peer=c90982186c0cc076633cf78b02fe26cd967f8c0926453ef22da804b54909b92f err="retrieved hash chain is invalid: missing parent"
erc20  | INFO [09-02|04:31:35.281] Looking for peers                        peercount=1 tried=42 static=8
erc20  | INFO [09-02|04:31:45.618] Looking for peers                        peercount=1 tried=40 static=8
erc20  | WARN [09-02|04:31:50.773] Synchronisation failed, dropping peer    peer=d2f47c21d108711c8baec703601e2d2f31811c60c7e659866319b0121294d564 err="retrieved hash chain is invalid: missing parent"
erc20  | INFO [09-02|04:31:55.649] Looking for peers                        peercount=0 tried=44 static=8
erc20  | INFO [09-02|04:32:05.694] Looking for peers                        peercount=1 tried=43 static=8
erc20  | INFO [09-02|04:32:16.008] Looking for peers                        peercount=0 tried=26 static=8
erc20  | WARN [09-02|04:32:21.743] Merge is configured, but no beacon client seen. Please ensure you have one available before the transition arrives! eta=9y1mo3w
erc20  | INFO [09-02|04:32:26.278] Looking for peers                        peercount=0 tried=51 static=8
erc20  | INFO [09-02|04:32:36.291] Looking for peers                        peercount=1 tried=40 static=8
erc20  | WARN [09-02|04:32:36.717] Synchronisation failed, dropping peer    peer=8d1da4c5bc682f8f8ad141f60d2889fa4232144c7d2b29b88f81ca33e586ef9d err=timeout
erc20  | INFO [09-02|04:32:46.967] Looking for peers                        peercount=1 tried=49 static=8
erc20  | INFO [09-02|04:32:53.486] Downloader queue stats                   receiptTasks=0 blockTasks=379  itemSize=25.98KiB throttle=8192
erc20  | WARN [09-02|04:32:55.935] Synchronisation failed, dropping peer    peer=3fb2bb7152a1ff54c0ff9e5a49ab9325c9030fb23627fd8da4eef53d9a937232 err="retrieved hash chain is invalid: missing parent"

abc-1211 avatar Sep 02 '22 04:09 abc-1211

can you provide some more logs and context?

ligi avatar Sep 06 '22 12:09 ligi

can you provide some more logs and context?

Do you mean I need to change the log level? What information you need exactly to help?

abc-1211 avatar Oct 04 '22 08:10 abc-1211

First of all, you should use a more recent version. About 1.10.25:

Geth v1.10.25 is a tiny update to flip the mainnet chain configuration to be post-merge. This disables legacy sync and will prevent Geth from even starting sync until a consensus client is attached and sends forkchoice updates. The update prevents bad PoW actors from trying to get the node to - temporarily, but annoyingly - download bad state data.

Secondly, however, your node is telling you that it needs a beacon-node to tell geth what head is canonical:

erc20 | WARN [09-02|04:32:21.743] Merge is configured, but no beacon client seen. Please ensure you have one available before the transition arrives! eta=9y1mo3w

Thirdly, loglevel can be set by

    --verbosity value              (default: 3)
          Logging verbosity: 0=silent, 1=error, 2=warn, 3=info, 4=debug, 5=detail

It can also be set from the console/rpc , e,g. debug.verbosity(4)

holiman avatar Oct 04 '22 08:10 holiman

This issue is pretty stale now, could you retry with a new version and a beacon node? I'll close this for now, feel free to reopen if the issue still persists

MariusVanDerWijden avatar Jan 02 '23 11:01 MariusVanDerWijden