Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve network parameters #5177

Merged
merged 1 commit into from
Feb 8, 2024

Conversation

AgeManning
Copy link
Member

The current state of mainnet is changing due to how clients are subscribing to long lived subnets. The modification has lead to more scarcity in the subnets as we expected.

We are now seeing issues where clients are unable to find and maintain useful peers to span all subnets, leading to missed attestations and the warning log, failed to publish message with the error InsufficientPeers. It is not enough for individual nodes to simply increase their peer counts, because it is often the case that other nodes on the network have already reached their peer limits and non-lighthouse clients often simply reject the connection. The best solution currently (and has been planned for a while) is to increase lighthouse's default target-peer count to ~120. However, we want to do this gradually. This PR takes an intermediate approach and sets the default value to 100.

We have been testing a default value of 100 peers for a while now and load seems acceptable for small home users. See attached:
peer-counts

There is a secondary issue where Lighthouse attempts to maintain 6 peers for every required subnet. For nodes with lots of validators this becomes an impossible task with an 80 peer target and results in continuous discovery queries.

higher-peer-counts

With a target peer count of 100, and each peers subscribing to two subnets, a healthy target peer count per subnet is 3. This should result in little to no discovery queries once the right set of peers are found. Having all nodes on the network update to this logic, should allow for more connections between all peers and more stability on the subnets.

@AgeManning AgeManning added the ready-for-review The code is ready for review label Feb 4, 2024
Copy link
Member

@pawanjay176 pawanjay176 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Strongly in favour

@AgeManning AgeManning added ready-for-merge This PR is ready to merge. and removed ready-for-review The code is ready for review labels Feb 7, 2024
@AgeManning
Copy link
Member Author

@Mergifyio queue

Copy link

mergify bot commented Feb 7, 2024

queue

🛑 The pull request has been removed from the queue default

The queue conditions cannot be satisfied due to failing checks.

You can take a look at Queue: Embarked in merge queue check runs for more details.

In case of a failure due to a flaky test, you should first retrigger the CI.
Then, re-embark the pull request into the merge queue by posting the comment
@mergifyio refresh on the pull request.

mergify bot added a commit that referenced this pull request Feb 7, 2024
@AgeManning
Copy link
Member Author

@Mergifyio requeue

Copy link

mergify bot commented Feb 8, 2024

requeue

✅ This pull request will be re-embarked automatically

The followup queue command will be automatically executed to re-embark the pull request

Copy link

mergify bot commented Feb 8, 2024

queue

✅ The pull request has been merged automatically

The pull request has been merged automatically at 4db84de

@AgeManning AgeManning added the v5.0.0 Q1 2024 label Feb 8, 2024
mergify bot added a commit that referenced this pull request Feb 8, 2024
@mergify mergify bot merged commit 4db84de into sigp:unstable Feb 8, 2024
29 checks passed
danielramirezch pushed a commit to danielramirezch/lighthouse that referenced this pull request Feb 14, 2024
* Modify network parameters for current mainnet conditions
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ready-for-merge This PR is ready to merge. v5.0.0 Q1 2024
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants