[GH-ISSUE #10422] UNTIL being set to 4 minutes, --keepalive NOT being used #53361

Closed
opened 2026-04-29 02:43:05 -05:00 by GiteaMirror · 4 comments
Owner

Originally created by @DocHogan on GitHub (Apr 26, 2025).
Original GitHub issue: https://github.com/ollama/ollama/issues/10422

What is the issue?

I'm friggen stumped, and don't know what background I need to give up front here. This seems to be new behavior, I don't remember running into it previously.

If I instantiate ollama with a run command and model ("ollama run llama3.2"), then run a "ollama ps", it shows llama3.2 running, with "4 minutes" shown under an "UNTIL" heading. If I kill everything (processes included) and instantiate with "ollama run llama3.2 --keepalive -2m", the ps shows "Forever" for the until. The next time I run a model, though, the new run goes right back to a 4 minute keepalive timer.

Same behavior regardless of which model loaded.

Issue began, or I first caught it, earlier today, running ollama v0.6.4; I just updated to v0.6.6, which has same behavior.

Relevant log output


OS

Windows

GPU

Nvidia

CPU

No response

Ollama version

0.6.6

Originally created by @DocHogan on GitHub (Apr 26, 2025). Original GitHub issue: https://github.com/ollama/ollama/issues/10422 ### What is the issue? I'm friggen stumped, and don't know what background I need to give up front here. This *seems* to be new behavior, I don't remember running into it previously. If I instantiate ollama with a run command and model ("ollama run llama3.2"), then run a "ollama ps", it shows llama3.2 running, with "4 minutes" shown under an "UNTIL" heading. If I kill everything (processes included) and instantiate with "ollama run llama3.2 --keepalive -2m", the ps shows "Forever" for the until. The next time I run a model, though, the new run goes right back to a 4 minute keepalive timer. Same behavior regardless of which model loaded. Issue began, or I first caught it, earlier today, running ollama v0.6.4; I just updated to v0.6.6, which has same behavior. ### Relevant log output ```shell ``` ### OS Windows ### GPU Nvidia ### CPU _No response_ ### Ollama version 0.6.6
GiteaMirror added the bug label 2026-04-29 02:43:05 -05:00
Author
Owner

@rick-github commented on GitHub (Apr 26, 2025):

-2m (minus two minutes) is Forever minus two minutes or about 292 years. Try --keepalive 2m.

<!-- gh-comment-id:2832484699 --> @rick-github commented on GitHub (Apr 26, 2025): `-2m` (minus two minutes) is Forever minus two minutes or about 292 years. Try `--keepalive 2m`.
Author
Owner

@pdevine commented on GitHub (Apr 26, 2025):

Hey @DocHogan , sorry this is confusing. This is the correct behaviour though. If you don't set keepalive it will default to 5 mins (although it will show 4 mins since it rounds down). If you set it to a negative number it will stay loaded forever. I'm going to go ahead and close the issue.

<!-- gh-comment-id:2832514861 --> @pdevine commented on GitHub (Apr 26, 2025): Hey @DocHogan , sorry this is confusing. This is the correct behaviour though. If you don't set keepalive it will default to 5 mins (although it will show 4 mins since it rounds down). If you set it to a negative number it will stay loaded forever. I'm going to go ahead and close the issue.
Author
Owner

@DocHogan commented on GitHub (Apr 26, 2025):

Hey @DocHogan , sorry this is confusing. This is the correct behaviour though. If you don't set keepalive it will default to 5 mins (although it will show 4 mins since it rounds down). If you set it to a negative number it will stay loaded forever. I'm going to go ahead and close the issue.

Perfect, thank you. I don't know how I missed this behavior previously, and I've been tearing my system completely apart all day trying to track down whatever stupid thing I did to break it. Thanks!

<!-- gh-comment-id:2832537322 --> @DocHogan commented on GitHub (Apr 26, 2025): > Hey [@DocHogan](https://github.com/DocHogan) , sorry this is confusing. This is the correct behaviour though. If you don't set keepalive it will default to 5 mins (although it will show 4 mins since it rounds down). If you set it to a negative number it will stay loaded forever. I'm going to go ahead and close the issue. Perfect, thank you. I don't know how I missed this behavior previously, and I've been tearing my system completely apart all day trying to track down whatever stupid thing I did to break it. Thanks!
Author
Owner

@DocHogan commented on GitHub (Apr 26, 2025):

-2m (minus two minutes) is Forever minus two minutes or about 292 years. Try --keepalive 2m.

You miss the point of my issue; or, more accurately, you misunderstand my misunderstanding. :)

<!-- gh-comment-id:2832537996 --> @DocHogan commented on GitHub (Apr 26, 2025): > `-2m` (minus two minutes) is Forever minus two minutes or about 292 years. Try `--keepalive 2m`. You miss the point of my issue; or, more accurately, you misunderstand my misunderstanding. :)
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/ollama#53361