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

chore(deployment): reduce cpu requests to realistic requirements allowing more previews #3715

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ spec:
memory: "30Mi"
cpu: 10m
limits:
memory: "100Mi"
memory: "500Mi"
ports:
- containerPort: 5432
env:
Expand Down
2 changes: 1 addition & 1 deletion kubernetes/loculus/templates/loculus-database-standin.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ spec:
resources:
requests:
memory: "200Mi"
cpu: "250m"
cpu: "50m"
limits:
memory: "2Gi"
ports:
Expand Down
7 changes: 3 additions & 4 deletions kubernetes/loculus/values.yaml
Copy link
Member

Choose a reason for hiding this comment

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

We're currently limited in Loculus preview deployments because of having too much CPU requests. The requests are way higher than actual utilization, which means we could actually have more previews without any issues - if we simply reduced overly high CPU requests.

This wasn't the case earlier today when I had to remove previews - my preview was running but various components dying due to OOM issues. I'm not saying that's always true - I presume you are seeing an issue that has prompted this - but presumably we're relatively balanced

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Hmm, there were a bunch of events saying "failed scheduling due to insufficient CPU" throughout the day and we were above 93% for CPU utilization earlier

Google Chrome Beta 2025-02-19 00 06 38

Copy link
Member

Choose a reason for hiding this comment

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

Sure (but in my specific case it was memory that was crashing it - I could see it in argoCD, so both were likely limiting)

Original file line number Diff line number Diff line change
Expand Up @@ -1719,7 +1719,7 @@ resources:
ingest:
requests:
memory: "1Gi"
cpu: "200m"
cpu: "20m"
limits:
cpu: "200m"
memory: "10Gi"
Expand All @@ -1738,7 +1738,7 @@ resources:
lapis:
requests:
memory: "220Mi"
cpu: "30m"
cpu: "20m"
limits:
memory: "5Gi"
silo-preprocessing:
Expand All @@ -1749,7 +1749,7 @@ resources:
backend:
requests:
memory: "640Mi"
cpu: "250m"
cpu: "150m"
limits:
memory: "3Gi" # Backend requires at least 635741K of memory
preprocessing:
Expand All @@ -1763,6 +1763,5 @@ defaultResources:
cpu: "20m"
limits:
memory: "1Gi"
cpu: "20m"
Copy link
Member

Choose a reason for hiding this comment

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

huh - this isn't allowed - seems like a bug in the schema - but your original 1000m seems good for now

Copy link
Contributor Author

Choose a reason for hiding this comment

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

You have to do both or neithe?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Schema complains:
image

Is that a correct complaint or a false positive complaint?

Copy link
Member

Choose a reason for hiding this comment

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

seems like a bug in the schema

Copy link
Member

Choose a reason for hiding this comment

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

ingest:
ncbiGatewayUrl: null
Loading