Skip to content

fix(k8s): bound prompt cache and set memory limit on ollama-64gib tier - #2391

Merged
dan-petty merged 1 commit into
mainfrom
fix/2382-ollama-64gib-prompt-cache-limits
Oct 27, 2026
Merged

dan-petty merged 1 commit into
mainfrom
fix/2382-ollama-64gib-prompt-cache-limits

Conversation

@dan-petty

Copy link
Copy Markdown
Owner

The ollama-64gib pod experienced repeated OOMKilled restarts on node gemini because llama-server saved prompt caches up to the 8192 MiB default in host RAM. Under a 160000 context length, a single prompt can consume over 3.1 GiB.

What changes:

  • Set LLAMA_ARG_CACHE_RAM to "4096" in the ollama-64gib DaemonSet.
  • Set container memory limit to 12Gi on the ollama-64gib DaemonSet.
  • Document prompt cache limits in ollama-profiles.yaml and ollama.md.
  • Add regression test in tests/test_k8s_llm_gateway.py.

Fail-to-pass: devops ci fail-to-pass --base origin/main gives 1 failed on base (1 failed and 64 passed in tests/test_k8s_llm_gateway.py; 0 errored) for test_ollama_64gib_tier_constrains_prompt_cache_and_memory_limit.

Closes #2382

Change:
openspec/changes/archive/2026-10-27-2382-ollama-64gib-prompt-cache-limits/

The ollama-64gib pod experienced repeated OOMKilled restarts on node gemini because llama-server saved prompt caches up to the 8192 MiB default in host RAM. Under a 160000 context length, a single prompt can consume over 3.1 GiB.

What changes:

- Set LLAMA_ARG_CACHE_RAM to "4096" in the ollama-64gib DaemonSet.
- Set container memory limit to 12Gi on the ollama-64gib DaemonSet.
- Document prompt cache limits in ollama-profiles.yaml and ollama.md.
- Add regression test in tests/test_k8s_llm_gateway.py.

Fail-to-pass: devops ci fail-to-pass --base origin/main gives 1 failed on base (1 failed and 64 passed in tests/test_k8s_llm_gateway.py; 0 errored) for test_ollama_64gib_tier_constrains_prompt_cache_and_memory_limit.

Closes #2382

Change:
openspec/changes/archive/2026-10-27-2382-ollama-64gib-prompt-cache-limits/
@dan-petty
dan-petty marked this pull request as ready for review October 27, 2026 23:09
@dan-petty
dan-petty merged commit 69636b6 into main Oct 27, 2026
16 checks passed
@dan-petty
dan-petty deleted the fix/2382-ollama-64gib-prompt-cache-limits branch October 27, 2026 23:11
dan-petty pushed a commit that referenced this pull request Oct 28, 2026
🤖 I have created a release *beep* *boop*
---


##
[0.8.2](v0.8.1...v0.8.2)
(2026-10-28)


### Bug Fixes

* **github:** a failed milestone patch leaves the created issue without
a milestone, the board-less triage audit reports no missing priority,
and review threads read every comment page
([#2158](#2158))
([#2394](#2394))
([d509dba](d509dba))
* **k8s:** bound prompt cache and set memory limit on ollama-64gib tier
([#2391](#2391))
([69636b6](69636b6))
* **k8s:** remove IQ3_S gateway deployment from qwen3.8 and chat groups
([#2393](#2393))
([0b76871](0b76871))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: dan-petty-release[bot] <346998822+dan-petty-release[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix(k8s): the ollama-64gib tier is OOMKilled when llama-server's prompt cache fills the node's memory

1 participant