diff --git a/.openclaw-sync/source.json b/.openclaw-sync/source.json index 88e81bfab..120573d48 100644 --- a/.openclaw-sync/source.json +++ b/.openclaw-sync/source.json @@ -1,5 +1,5 @@ { "repository": "openclaw/openclaw", - "sha": "0a076bc0fca22e2a71bbc600b6f8bed7ee235408", - "syncedAt": "2026-04-27T12:23:35.776Z" + "sha": "750c180a6ca023a2bd9aebac6fffb65f2b0e6663", + "syncedAt": "2026-04-27T12:25:22.040Z" } diff --git a/docs/gateway/local-models.md b/docs/gateway/local-models.md index 8e36625ec..842f9a081 100644 --- a/docs/gateway/local-models.md +++ b/docs/gateway/local-models.md @@ -11,6 +11,10 @@ Local is doable, but OpenClaw expects large context + strong defenses against pr If you want the lowest-friction local setup, start with [LM Studio](/providers/lmstudio) or [Ollama](/providers/ollama) and `openclaw onboard`. This page is the opinionated guide for higher-end local stacks and custom OpenAI-compatible local servers. + +**WSL2 + Ollama + NVIDIA/CUDA users:** The official Ollama Linux installer enables a systemd service with `Restart=always`. On WSL2 GPU setups, autostart can reload the last model during boot and pin host memory. If your WSL2 VM repeatedly restarts after enabling Ollama, see [WSL2 crash loop](/providers/ollama#wsl2-crash-loop-repeated-reboots). + + ## Recommended: LM Studio + large local model (Responses API) Best current local stack. Load a large model in LM Studio (for example, a full-size Qwen, DeepSeek, or Llama build), enable the local server (default `http://127.0.0.1:1234`), and use Responses API to keep reasoning separate from final text. diff --git a/docs/providers/ollama.md b/docs/providers/ollama.md index 802154382..c189c976e 100644 --- a/docs/providers/ollama.md +++ b/docs/providers/ollama.md @@ -897,6 +897,41 @@ For the full setup and behavior details, see [Ollama Web Search](/tools/ollama-s ## Troubleshooting + + On WSL2 with NVIDIA/CUDA, the official Ollama Linux installer creates an `ollama.service` systemd unit with `Restart=always`. If that service autostarts and loads a GPU-backed model during WSL2 boot, Ollama can pin host memory while the model loads. Hyper-V memory reclaim cannot always reclaim those pinned pages, so Windows can terminate the WSL2 VM, systemd starts Ollama again, and the loop repeats. + + Common evidence: + + - repeated WSL2 reboots or terminations from the Windows side + - high CPU in `app.slice` or `ollama.service` shortly after WSL2 startup + - SIGTERM from systemd rather than a Linux OOM-killer event + + OpenClaw logs a startup warning when it detects WSL2, `ollama.service` enabled with `Restart=always`, and visible CUDA markers. + + Mitigation: + + ```bash + sudo systemctl disable ollama + ``` + + Add this to `%USERPROFILE%\.wslconfig` on the Windows side, then run `wsl --shutdown`: + + ```ini + [experimental] + autoMemoryReclaim=disabled + ``` + + Set a shorter keep-alive in the Ollama service environment, or start Ollama manually only when you need it: + + ```bash + export OLLAMA_KEEP_ALIVE=5m + ollama serve + ``` + + See [ollama/ollama#11317](https://github.com/ollama/ollama/issues/11317). + + + Make sure Ollama is running and that you set `OLLAMA_API_KEY` (or an auth profile), and that you did **not** define an explicit `models.providers.ollama` entry: