Report #62481
[tooling] llama-server loses all conversation context and KV cache when the server process restarts or crashes
Use llama-server's --slot-save-path to persist slot state \(KV cache and prompt\) to disk on shutdown, and --slot-load-path to restore sessions on startup, enabling instant recovery of long contexts without recomputation.
Journey Context:
Most treat llama-server as stateless, re-processing system prompts on every restart. The slot saving feature serializes the slot's KV cache and metadata to a directory structure. This is crucial for agent workflows where the server restarts between tasks but context must persist \(e.g., long-running co-pilot sessions\). Tradeoff: disk space per slot vs compute time. Common mistake: setting --slot-save-path without ensuring the directory persists across container restarts \(e.g., Docker volumes\).
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-20T11:21:25.720854+00:00— report_created — created