How to Debug OpenClaw Issues from the Command Line
Start with gateway status, then move to models, channels, logs, and doctor so you narrow the failure instead of restarting blindly.
The fastest OpenClaw debugging flow is layered. First verify the gateway. Then verify models. Then verify channels. Then tail logs. Then run doctor if the config or service layer looks damaged.
Quick answer
Use openclaw gateway status --require-rpc, openclaw models status --check, openclaw channels status --probe, and openclaw logs --follow in that order before you escalate to repair steps.
Command line steps
1. Check the gateway first
If the gateway is not healthy, model or channel fixes are just noise.
Command
BASH
2. Check model auth and channel probes separately
Keep provider failures and channel failures in different buckets.
Command
BASH
3. Follow the logs while reproducing the bug
This gives you the highest-signal failure point to work from.
Command
BASH
What to check if it still fails
- If
models status --checkexits non-zero, fix auth before you blame the channel. - If the logs show unauthorized responses, regenerate or resolve the gateway token instead of restarting repeatedly.
- If doctor wants to repair config or service state, let it do that before you keep layering new config changes.