openclaw - 💡(How to fix) Fix [Bug]: Llama 3.1 8B via Ollama hangs indefinitely — gateway blocks on first request [1 comments, 2 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
openclaw/openclaw#68662Fetched 2026-04-19 15:08:57
View on GitHub
Comments
1
Participants
2
Timeline
3
Reactions
0
Timeline (top)
labeled ×2commented ×1

Trying to run a local model using Ollama but it fails.

Root Cause

Trying to run a local model using Ollama but it fails.

RAW_BUFFERClick to expand / collapse

Bug type

Behavior bug (incorrect output/state without crash)

Beta release blocker

No

Summary

Trying to run a local model using Ollama but it fails.

Steps to reproduce

Environment:

• OpenClaw 2026.4.15 • macOS, Apple M4 Mac Mini, 24GB RAM • Ollama running locally, llama3.1:8b pulled and loaded (confirmed via /api/ps) • Config: baseUrl: http://127.0.0.1:11434, api: ollama (native API, not openai-completions) Steps to reproduce:

  1. Start gateway, switch model to ollama/llama3.1:8b
  2. Send "hello" via TUI or Signal
  3. Typing indicator appears briefly (Signal) or spinner starts (TUI)
  4. No response ever arrives — hangs indefinitely (tested up to 7+ minutes)
  5. Ollama shows model loaded in memory (/api/ps) but no active generation
  6. Gateway logs show no Llama request — the request never reaches Ollama
  7. Second message gets no typing indicator at all — gateway is unresponsive
  8. Only fix is openclaw gateway restart

Expected behavior

Expected: Response to "hello" within reasonable time

Actual behavior

Actual: Gateway hangs, requires restart to recover

OpenClaw version

2026.4.15

Operating system

macOS, Apple M4 Mac Mini, 24GB RAM

Install method

npm

Model

ollama/llama3.1:8b

Provider / routing chain

TUI → OpenClaw gateway :18789 → Ollama native API http://127.0.0.1:11434/api/chat

Additional provider/model setup details

Before switching to native API (api: ollama), config was incorrectly set to api: openai-completions with /v1 URL — this caused raw tool JSON to be output as plain text on first response, then same hang behavior on second message.

Also reproduced through Signal, but TUI shows the same hang, so the cleanest repro does not require any external channel integration.

Logs, screenshots, and evidence

Impact and severity

No response

Additional information

Discord help bot says there is a later version which fixes this but I cannot update to it and the bot says it is not npm stable. openclaw update for me yields the below:

Tag/spec: openclaw@latest Current version: 2026.4.15 Target version: 2026.4.15

extent analysis

TL;DR

The issue can be mitigated by restarting the OpenClaw gateway, but a more permanent solution may involve updating to a later version of OpenClaw, if available.

Guidance

  • Verify that the Ollama model is correctly loaded and configured by checking the /api/ps endpoint.
  • Check the gateway logs to ensure that the request is being sent to Ollama and that there are no errors or timeouts.
  • Consider testing with a different model or API to isolate the issue to the Ollama model or the native API.
  • If updating to a later version of OpenClaw is not possible, try to identify any patterns or triggers that cause the hang behavior.

Example

No code snippet is provided as the issue seems to be related to the configuration and interaction between OpenClaw and Ollama.

Notes

The Discord help bot mentions a later version of OpenClaw that fixes this issue, but it is not available on npm stable. The current version of OpenClaw (2026.4.15) does not have any updates available.

Recommendation

Apply workaround: Restart the OpenClaw gateway when the hang behavior occurs, as this is the only known fix at this time.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

FAQ

Expected behavior

Expected: Response to "hello" within reasonable time

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

openclaw - 💡(How to fix) Fix [Bug]: Llama 3.1 8B via Ollama hangs indefinitely — gateway blocks on first request [1 comments, 2 participants]