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

[DH-377] Increase ephemeral ports by default #6441

Conversation

shaneknapp
Copy link
Contributor

@shaneknapp shaneknapp commented Oct 30, 2024

instead of manually patching proxy pods that run out of ephemeral ports in a terrible game of whack-a-mole, just give every hub's chp more ports by default.

it's a band-aid for jupyterhub/configurable-http-proxy#557, and while it doesn't fix the problem outright it definitely lessens the impact significantly.

instead of ~15-45m of "503 service unavailable" being presented to the users when we hit the default limit of 28231 ephemeral ports (60999 - 32768), we give ourselves 55000 ephemeral ports (65000 - 10000). this limits downtime to a few minutes of high hub response times, and possibly a few users seeing 503.

we haven't seen any impact on other services, and remain slightly optimistic of it's efficacy in smoothing out the road.

we've also given the worst impacted chp pods 3G of ram each, but could also consider scaling that down to 2.5G. under max load, when the port count is ~32000, the chp pod ram usage is typically between ~1.2-1.6G.

i will test this on logodev.d.b.e

@shaneknapp
Copy link
Contributor Author

deployed to logodev.d.b.e and the updated port range has been applied!

/srv/configurable-http-proxy $ sysctl -a|grep range
net.ipv4.ip_local_port_range = 10000    65000

@shaneknapp shaneknapp changed the title [DH-301] Increase ephemeral ports by default [DH-377] Increase ephemeral ports by default Oct 30, 2024
Copy link
Contributor

@felder felder left a comment

Choose a reason for hiding this comment

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

LGTM

@shaneknapp shaneknapp merged commit 601f008 into berkeley-dsep-infra:staging Oct 30, 2024
2 checks passed
@shaneknapp shaneknapp deleted the increase-ephemeral-ports-by-default branch October 30, 2024 19:33
@shaneknapp
Copy link
Contributor Author

shaneknapp commented Oct 30, 2024

this took down all hubs that already had the kubectl patch in place.

other hubs were unaffected.

ofc the hubs that went down are the ones that get the most usage. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants