Skip to content

How does bootnode peering work in geth? #30122

Closed as not planned
Closed as not planned
@SyedMuhamadYasir

Description

@SyedMuhamadYasir

I am quite unsure about the peering tendency of the geth peers

My question is about geth bootnodes not peering properly - however, instead of leaving the question as it is here, i would like to provide some elaboration.

i have set up a private ethereum PoS network with geth + lighthouse,

and i am now struggling with setting up a bootnode

I started a geth node (lets call it Node A), assigned to it its OWN enode address (using the --bootnode parameter)

I then added a static peer (lets call it SPeer ) to Node A

this worked, so Node A who is supposed to be a bootnode, is now synced with the PoS private testnet

NOW, i start another geth node (Node B), it is fresh and has no peers

Node B is given the enode of Node A, so basically Node B, in its --bootnode parameter, has the enode address of
Node A

here is what happens

Node B only discovers Node A as a peer

but Node B does NOT discover SPeer (the static peer of Node A), as an additional peer for itself

why is that?

am i missing something in how geth peering works?

or what the bootnode is supposed to do?

Aren't geth nodes supposed to also discover OTHER nodes connected to their peers, so that they can have a healthy collection of peers? ( the analogy of 'knowing a friend of a friend' applies here)

This is exactly the problem i am facing with my PoS test network, i cannot set up auto peering through bootnodes and every time, i have to add peers through the geth js console

at best, if the node, whose enode address is provided to others, is healthy, then those other nodes will peer with it and start working normal

but thats about it,

how can i make my geth nodes find other peer nodes in the private testnetwork seamlessly and thorugh a bootnode (or a collection of bootnodes atleast)

I am looking forward to some help, as i have asked this in geth discord among other places but i did not get any helpful answers (S1na was willing to help me on discord, but he's busy i believe, as he hasn't replied in a while)

Best,
Yasir

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions