#Problem with Ollama Api
1 messages · Page 1 of 1 (latest)
the error is Ollama API error 500: {"error":"model requires more system memory (20.3 GiB) than is available (6.1
GiB)"}
The ssh -D 1080 … bit is a big clue: -D makes a SOCKS proxy for your local browser, but it does not make your AWS OpenClaw gateway able to reach services running on your laptop (like Ollama). So you can successfully open the UI, but the gateway still can’t talk to Ollama → you’ll get the same model error no matter what you pick.
A couple quick checks to narrow it down:
- What’s the exact error text OpenClaw shows (or the gateway log line)? Paste that.
- Where is Ollama running?
- On the AWS box (same machine as the gateway), or
- On your local machine (laptop/desktop)?
Common gotcha from tutorials: don’t use /v1
OpenClaw’s Ollama integration expects the native Ollama API, so the base URL should be like:
http://<host>:11434âś… (no/v1)
If you point it at http://<host>:11434/v1 (OpenAI-compatible mode), tool calling breaks and you can get weird “everything fails” behavior.
Networking reality (if Ollama is on your laptop)
If Ollama is local but the gateway is on AWS, you need to make port 11434 reachable from AWS, e.g.:
- Tailscale (cleanest), or
- an SSH reverse tunnel (works great for testing):
ssh -R 11434:127.0.0.1:11434 username@remote_server- then configure OpenClaw on AWS to use
http://127.0.0.1:11434
- then configure OpenClaw on AWS to use
What to paste here
openclaw --version- the exact error
- (optional) your
models.providers.ollamaconfig block (redact any keys; for Ollama the “key” can be any dummy string anyway)
Then I can tell you which of the above paths fits your setup.
That error is coming straight from Ollama, not OpenClaw:
model requires more system memory (20.3 GiB) than is available (6.1 GiB)
So the machine running ollama serve only has ~6 GB free RAM, and the specific llama3:8b variant you pulled (or the context it’s trying to allocate) needs ~20 GB to load.
What to do:
- Confirm where Ollama is running
- If Ollama is on the AWS box: you either need a bigger instance (realistically ≥ 24 GB RAM for that model), or use a smaller/quantized model.
- If Ollama is on your laptop but OpenClaw is on AWS: right now OpenClaw is hitting an Ollama instance that only has 6 GB free (likely the AWS one). Your
ssh -DSOCKS tunnel won’t help the gateway reach your laptop’s Ollama—you’d need Tailscale or an SSH reverse tunnel.
- Check what you actually pulled (size/quantization/context)
On the machine running Ollama, run:
ollama list
ollama show llama3:8b
If ollama list shows the model is huge (or show indicates fp16 / high precision), pull a Q4 (or otherwise smaller) variant and use that instead.
- (Optional) If you tell me: is Ollama on AWS or your laptop?
I can point you to the cleanest fix (upgrade instance vs reverse tunnel/Tailscale + correctbaseUrl).
Docs for the “correct URL” side of things (no /v1): https://docs.openclaw.ai/providers/ollama
do i put /v2