Skip to content
Daemon

The daemon keeps network and maintenance work away from compiler processes. Local cache lookup and storage do not require it.

Responsibilities

  • Download an exact entry after a local miss.
  • Upload newly stored entries in the background.
  • Replay durable upload intents after a restart.
  • Prefetch likely entries at the start of a build session.
  • Refresh the remote key index used by fallback planning.
  • Run garbage collection at startup and every six hours.

Set cache.prefetch_enabled = false or KACHE_PREFETCH_ENABLED=0 to disable speculative prefetch while retaining exact remote checks and uploads.

When it is required

Local-only caching works with no daemon. A configured remote needs the daemon for reads, writes, and prefetch. If the daemon is unavailable, the wrapper continues with the local store and compiles an exact remote miss locally.

Endpoint placement

On Unix the default socket is <runtime_dir>/daemon.sock. Windows derives a named-pipe identity from the configured path. Override the runtime root with KACHE_RUNTIME_DIR or only the endpoint with an absolute KACHE_SOCKET_PATH.

Use a short, user-owned runtime directory. Unix socket paths are length-limited, and shared temporary directories allow another local user to interfere with adjacent lock and state files.

Every client and daemon process must resolve the same runtime and socket settings. Installed services do not inherit later shell exports; put persistent values in the config or service definition.

Basic commands

kache daemon start
kache daemon status
kache daemon log
kache daemon stop

Bare kache daemon is an alias for kache daemon status.

See Lifecycle for service installation and restart behavior.

Available for:
Apple macOS logomacOSMicrosoft Windows logoWindowsLinux logoLinux
Download Kunobi