Get started
KVStash documentation
How to run the KVStash daemon, connect your inference engines to it, and operate it in production. Every setting on these pages is named exactly as the software names it, with its default.
Last updated
What runs where
KVStash has two parts. The daemon, kvblockd, is one static Linux binary that stores KV-cache blocks in DRAM, on NVMe and in S3. An adapter, a small Python package, runs inside each inference engine and talks to the daemon over plain TCP.
- Engines write once, read many times. When an engine computes the KV cache for a prompt prefix, the adapter stores it as fixed-size blocks. Any engine connected to the same namespace can read those blocks back instead of recomputing them.
- The daemon never looks inside a block. It stores opaque bytes with a checksum; it has no knowledge of models, tensors or layouts. That is why one daemon serves vLLM and SGLang at the same time.
- Failures become cache misses. If the daemon is down, slow or returns a damaged block, the adapter reports a miss and the engine recomputes. Serving keeps working.
Where to start
- Try it on one machineStart the daemon with a DRAM tier, store and read a block, and look at the metrics. About ten minutes.
- Connect vLLM or SGLangPick the connector for your engine, set one flag or one config block, and confirm the engine reads from the store.
- Plan a production nodeSize the DRAM arena, add an NVMe tier and an S3 cold tier, set up tenants and scrape the metrics.
Getting the software
Download the daemon from the install page: static binaries for Linux x86-64 and arm64 (macOS arm64 for development), with SHA-256 checksums, or run curl -fsSL https://kvstash.com/install.sh | sh. The container image and Helm chart are available on request. Contact us for the container image and Helm chart, or if your engine, model or GPU is not covered here.
PyPI packages, checked end to end on 8 November 2026 with the official engine images: kvblockd 0.2.0 with vllm-kvblockd 0.1.2 on vLLM 0.33.0, and sglang-kvblockd 0.2.1 on SGLang 0.5.23. Both store, reload into a restarted engine and give the answer the engine gives from its own cache. lmcache-kvblockd 0.2.1 is not recommended yet: in LMCache's own image (LMCache 0.5.6, vLLM 0.31.0) a prompt reloaded from LMCache's own cache answered wrongly, with or without KVStash. On vLLM, use the native vllm-kvblockd connector.
The install page lists every channel and what it contains.
All pages
Get started
- QuickstartStart the kvblockd daemon with a DRAM tier, store and read a block with kvbctl, and check the metrics endpoint. About ten minutes on any Linux machine.
- How it worksWhat KVStash stores and how: sealed KV blocks, prefix-chained keys, namespaces, the DRAM, NVMe and S3 tiers, leases, pins, eviction and fail-open reads.
Connect an engine
- Choose a connectorWhich KVStash connector to use for each inference engine, what is GPU-tested, what to install, and how to confirm the engine is really using the store.
- vLLMvllm-kvblockd is a native vLLM KV connector for KVStash, GPU-tested on vLLM 0.25.1, 0.27.1 and 0.33.0. Setup, measured reloads, the 0.27 layout change, limits.
- SGLangsglang-kvblockd makes KVStash an L3 storage backend for SGLang HiCache. Tested on SGLang 0.5.15.post1 on L40S and H100. Setup, results and known limits.
- LMCachelmcache-kvblockd connects LMCache to KVStash through remote_storage_plugins. The path exists and is tested in CI; it is not yet qualified on GPUs.
Run in production
- InstallInstall channels for KVStash: static binary, container image, systemd unit and Helm chart for the daemon, and the Python adapters for each engine.
- Kubernetes (Helm)Deploy kvblockd with its Helm chart: values for the DRAM arena, NVMe volume, S3 tier, hugepages, tenants and IRSA credentials, plus a smoke test.
- DRAM, NVMe and S3 tiersSet up the KVStash DRAM arena and hugepages, the NVMe warm tier and the S3 cold tier, including the required bucket lifecycle rule and failure behaviour.
- Tenants and securityNamespaces and tokens in KVStash: hashed tokens, per-tier quotas, the loopback admin plane, adding tenants at runtime, and where to expose each port.
- MonitoringThe kvblockd metrics endpoint: every kvb_ metric family, health checks, the Grafana dashboard, and the counters that prove an engine is reading from the store.
- Sizing and networkHow much DRAM and NVMe a KVStash node needs, bytes per token for common models, socket and sysctl tuning, and how to measure your own network ceiling.
Reference
- ConfigurationEvery kvblockd configuration key with its default and meaning, the KVBLOCKD_ environment overrides, command-line flags and the precedence between them.
- kvbctl CLIkvbctl, the KVStash command-line tool: put, get, exists, delete and stats on the data plane, and namespace and quota commands on the admin plane.
- Python clientUse the kvblockd Python package to talk to KVStash directly: connect, put, batch get, prefix probes, zero-copy reads, leases, pins and error handling.
- TroubleshootingFixes for common KVStash problems: engines that never hit the store, startup refusals, PYTHONHASHSEED errors, slow reads, NVMe and S3 warnings.
Something missing or wrong on this page? Email rudray@kvstash.com and it gets fixed.