Operations and Troubleshooting
This page covers day-to-day operational tasks and solutions to common problems when running DeerFlow App.
Log files
All services write logs to the logs/ directory when started with make dev:
| File | Service |
|---|---|
logs/langgraph.log | LangGraph / DeerFlow Harness runtime |
logs/gateway.log | FastAPI Gateway API |
logs/frontend.log | Next.js frontend dev server |
logs/nginx.log | nginx reverse proxy |
Tail logs in real time:
tail -f logs/langgraph.log
tail -f logs/gateway.logAdjust the runtime log level in config.yaml:
log_level: debug # debug | info | warning | errorHealth checks
Verify each service is responding:
# Gateway health
curl http://localhost:8001/health
# LangGraph health
curl http://localhost:2024/ok
# Through nginx (verifies full proxy chain)
curl http://localhost:2026/api/modelsConfig upgrade
When you pull a new version of DeerFlow, the config_version in config.example.yaml may be higher than your config.yaml. To merge new fields without losing your customizations:
make config-upgradeCheck the current version in your config:
grep config_version config.yamlCommon problems
The app loads but the agent doesn’t respond
- Check
logs/langgraph.logfor startup errors. - Verify your model is correctly configured in
config.yamlwith a valid API key. - Confirm the API key environment variable is set in the shell that ran
make dev. - Test the model endpoint directly with
curlto rule out network issues.
Model API errors in the agent response
The agent reports an error like "No chat models are configured" or "model not found":
- Check that the
models:section inconfig.yamlhas at least one entry. - Verify the
name:field matches what you are requesting in the UI. - Check that
api_key:is referencing the correct environment variable and that the variable is set.
Frontend build fails with BETTER_AUTH_SECRET
Error: BETTER_AUTH_SECRET is requiredSet the environment variable before building:
export BETTER_AUTH_SECRET=$(openssl rand -base64 32)
pnpm buildOr set it in your .env file at the repo root.
Sandbox-related tool failures
If file tools (read_file, ls, bash) fail with permission or path errors:
- For
LocalSandboxProvider: check thatallow_host_bashis set correctly and that the agent has read/write access to the thread data directory. - For container sandboxes: verify Docker (or Apple Container) is running and the sandbox image is accessible.
- For K8s Provisioner: check that the provisioner service is healthy (
curl http://localhost:8002/health) and that the K8s cluster is reachable.
K8s Provisioner not connecting
Connection refused: http://provisioner:8002- Ensure the provisioner service is running:
docker compose ps. - Check that
K8S_API_SERVERis set correctly (should point to the K8s API from inside the container, notlocalhost). - Verify
~/.kube/configis mounted and the cluster is reachable from the container host.
MCP tools not loading
If MCP tools appear in extensions_config.json but are not available in the agent:
- Check
logs/langgraph.logfor MCP initialization errors. - Verify the MCP server command is installed (
npx,uvx, or the relevant binary). - Test the server command manually to confirm it starts without errors.
- Set
log_level: debugto see detailed MCP loading output.
Memory not persisting across sessions
- Verify
memory.enabled: trueinconfig.yaml. - Check that the storage path is writable:
ls -la backend/.deer-flow/. - Look for memory update errors in
logs/langgraph.log(search for “memory”).
Data backup
Thread data and memory are stored under backend/.deer-flow/:
backend/.deer-flow/
memory.json # global agent memory
agents/ # per-agent memory
threads/ # thread working directories
{thread_id}/
user-data/
uploads/
outputs/
checkpoints.db # SQLite checkpoints (if configured)Back up this entire directory to preserve conversation history, artifacts, and learned memory.
In Docker deployments, the bind-mounted host path ($DEER_FLOW_ROOT/backend/.deer-flow/) is the source of truth — back up the host path.
Restarting services
To restart a single service (local deployment):
make stop
make devIndividual service restart scripts are in scripts/. For targeted restarts, you can kill and relaunch individual processes manually using the PIDs in the log files.