Skip to content
This repository was archived by the owner on Oct 28, 2021. It is now read-only.
This repository was archived by the owner on Oct 28, 2021. It is now read-only.

Aleth tries to sync with peer after status verification fails #5643

@halfalicious

Description

@halfalicious

Take node 2124182c… in the following log snippet:

DEBUG 06-29 14:58:52 p2p  ethcap Status (from ##2124182c…): 63 / 1 / #82270b80…, TD: 44733633866011995653 = #b41213a3…
DEBUG 06-29 14:58:52 p2p  sync   Peer ##2124182c… not suitable for sync: Genesis hash mismatch. Host genesis hash: d4e56740…, peer genesis hash: 82270b80…
TRACE 06-29 14:58:52 p2p  net    Disconnecting (our reason: Peer had no use for this node.) from (##2124182c…@54.39.102.75:30005)
TRACE 06-29 14:58:52 p2p  net    Disconnect to (##2124182c…@54.39.102.75:30005)
TRACE 06-29 14:58:52 p2p  net    Closing (Peer had no use for this node.) connection with (##2124182c…@54.39.102.75:30005)
TRACE 06-29 14:58:52 p2p  net    Received Disconnect (1) from (##3440a67b…@206.189.205.173:30303)
TRACE 06-29 14:58:52 p2p  p2pcap Disconnect from (##3440a67b…@206.189.205.173:30303)
DEBUG 06-29 14:58:52 p2p  p2pcap Disconnect (reason: Peer had too many connections.) from (##3440a67b…@206.189.205.173:30303)
TRACE 06-29 14:58:52 p2p  net    Closing (Disconnect was requested.) connection with (##3440a67b…@206.189.205.173:30303)
DEBUG 06-29 14:58:52 p2p  net    Closing peer session with (##3440a67b…@206.189.205.173:30303)
DEBUG 06-29 14:58:52 p2p  sync   Discovered new highest difficulty (44733633866011995653) from peer ##2124182c…
INFO  06-29 14:58:52 p2p  sync   Starting full sync
DEBUG 06-29 14:58:52 p2p  sync   Syncing with peer ##2124182c…
DEBUG 06-29 14:58:52 p2p  peer   Requesting 1 block headers starting from #b41213a3… from ##2124182c… 2124182c…
TRACE 06-29 14:58:52 p2p  net    GetBlockHeaders to (##2124182c…@54.39.102.75:30005)
TRACE 06-29 14:58:52 p2p  net    Starting RLPX handshake with ##2e7d35b9…@18.162.59.149:3332
DEBUG 06-29 14:58:52 p2p  net    Closing peer session with (##2124182c…@54.39.102.75:30005)
TRACE 06-29 14:58:52 p2p  net    Starting RLPX handshake with ##85d95b32…@18.228.30.92:21000
DEBUG 06-29 14:58:52 p2p  net    Starting peer session with giov/v0.0.6-unstable/linux-amd64/go1.11.5 (protocol: V5) ##4223300e… capabilities: (eth,63) port: 0
DEBUG 06-29 14:58:52 p2p  net    New session for capability eth; idOffset: 16 with ##4223300e…@47.245.30.101:30303
TRACE 06-29 14:58:52 p2p  net    Status to (##4223300e…@47.245.30.101:30303)

Log breakdown:

  1. Aleth determines that the node can't be sync'd with since it's on a different chain so it sends a disconnect p2p capability packet to the node and closes its session:
DEBUG 06-29 14:58:52 p2p  sync   Peer ##2124182c… not suitable for sync: Genesis hash mismatch. Host genesis hash: d4e56740…, peer genesis hash: 82270b80…
TRACE 06-29 14:58:52 p2p  net    Disconnecting (our reason: Peer had no use for this node.) from (##2124182c…@54.39.102.75:30005)
TRACE 06-29 14:58:52 p2p  net    Disconnect to (##2124182c…@54.39.102.75:30005)
TRACE 06-29 14:58:52 p2p  net    Closing (Peer had no use for this node.) connection with (##2124182c…@54.39.102.75:30005)
  1. However, Aleth then tries to sync with the node before suddenly closing the peer session:
DEBUG 06-29 14:58:52 p2p  sync   Discovered new highest difficulty (44733633866011995653) from peer ##2124182c…
INFO  06-29 14:58:52 p2p  sync   Starting full sync
DEBUG 06-29 14:58:52 p2p  sync   Syncing with peer ##2124182c…
DEBUG 06-29 14:58:52 p2p  peer   Requesting 1 block headers starting from #b41213a3… from ##2124182c… 2124182c…
TRACE 06-29 14:58:52 p2p  net    GetBlockHeaders to (##2124182c…@54.39.102.75:30005)
DEBUG 06-29 14:58:52 p2p  net    Closing peer session with (##2124182c…@54.39.102.75:30005)

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions