Skip to content

Inspect health and logs

Record the request time, endpoint, HTTP status, and non-secret error message. Distinguish “cannot connect,” “request rejected,” and “generation is slow.”

For an existing WSL service:

Terminal window
systemctl status devsecops-ai ollama
journalctl -u devsecops-ai -n 100 --no-pager

For the terminal lab, inspect the terminal output and logs/ai_backend.log beneath the working directory. Current logs can include user input and credential information; do not publish them without redaction.

SignalInterpretation
/health respondsAPI and knowledge-store count are reachable
Ollama registry respondsModel server can list installed models
Query returns a nonempty answerInference succeeded for that request
Known document appears in sourcesRetrieval succeeded for that sample
Disk and memory usageResource pressure may explain failures
Terminal window
df -h .
free -h
ollama ps

Monitoring scripts exist, but configuration variables in an example file are not proof that a timer, alert, or restart policy is installed. Check the actual service/timer configuration. The backend currently performs blocking operations inside async handlers, so a long inference can delay other requests on the same worker.

Next: Troubleshoot by symptom.