Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Stats and monitoring

/_combd/stats

Every node answers GET /_combd/stats on its main port with what it’s doing, as JSON. It isn’t behind a token, so anyone who can reach the port can read it. Counters count up from the node’s start. The rest are now.

curl -s https://n0.arena.combd.dev/_combd/stats

Objects

FieldWhat it is
objects_liveDurable objects in memory now.
objects_openedObjects started or brought back from storage.
evictionsObjects that left memory, idle or squeezed.
alarms_fired, alarms_failedAlarms that ran, and ones whose handler crashed.
forwardedRequests sent to another loop or node that owns their object.
mailbox_refusedRequests refused because a mailbox was full, 503 overloaded.
batchedRequests that ran in a handle_batch batch.

Writes (D1)

FieldWhat it is
commitsCommits that wrote something.
fsyncsThe fsyncs that made them durable. Far fewer than commits means the group commit is working.
checkpointsWAL checkpoints.
fsyncs_slow, fsync_max_usfsyncs of 10 ms or more, and the slowest, in µs.

A fleet

FieldWhat it is
peer_acksWrites acknowledged by peers, for D3.
bucket_acksWrites acknowledged by the bucket, for D2.
uploadsSegments sent to the bucket, retries too.
fencesTakeovers that fenced an older owner.
fence_waitsFences told to wait out a peer’s promise, when a read lease held off a takeover.
tail_entriesEntries recovered from peers in takeovers.
lease_readsReads answered under a read lease, with no round.
gc_deletedBucket keys deleted by compaction.
movesObjects handed to another node by placement.

WebSockets and sessions

FieldWhat it is
sockets_openWebSockets open now.
ws_messagesMessages in from them.
ws_frames, ws_flushesFrames sent, and the writes that sent them. A socket’s frames can share one write.
ws_handoffsHandshakes one loop took and handed to the loop of their object.
sessions_livews sessions now.
sessions_hibernatedOf those, asleep.
sessions_wokenTimes a session woke.
sessions_readySleeping sessions with work, waiting for room under COMBD_MAX_AWAKE.
sessions_waitedTimes one had to wait.

Connections and memory

FieldWhat it is
conns_openConnections open now.
conns_refusedConnections accepted, then refused for being full or over COMBD_MAX_CONNS.
tcp_refusing1 while the node is full and not listening.
accept_failedConnections accept failed on, out of files.
memory_usedThe node’s memory, by its own count. With a cgroup, what the cgroup is charged, less file cache it would give back.
memory_budgetIts budget, COMBD_MEMORY_BUDGET or what it found.
machine_availableWhat the machine can still hand out without swapping.
heap_in_useBytes the allocator has handed out. glibc only, 0 elsewhere.
pressure0 fine, 1 reclaiming, 2 refusing. See Overload.
disk_low1 while the data disk is too full for new objects.

Event cells, and the rest

FieldWhat it is
ev_instances, ev_requestsEvent-cell instances started, and the requests they took.
procsPer org/app/process: cpu_us, its cells’ run time with host calls, slices, and engine, compiled or interpreted.
nodeThis node’s number in a fleet, null on one node.
versionThe combd version, dev for a build with none set.

Watch these first: pressure, tcp_refusing, sessions_ready, mailbox_refused, conns_refused, and disk_low. Any of them above 0 means the node is turning work away.

/v1/nodes

On a fleet’s admin API, GET /v1/nodes, with a */*:read token, asks every node in COMBD_PUBLIC_URLS for its /_combd/stats at once, 3 s each at most.

curl -s -H "authorization: Bearer $COMBD_TOKEN" https://n0.arena.combd.dev:9443/v1/nodes
{"nodes": [
  {"node": 0, "url": "https://n0.arena.combd.dev", "stats": {"objects_live": 65, "...": "..."}},
  {"node": 1, "url": "https://n1.arena.combd.dev", "error": "..."}
]}

A node that doesn’t answer says why, and the rest still come.

The panel

GET / on the admin port is the panel. Given a token, it shows /v1/nodes and /v1/deploys as a page: every node, where each process’s CPU goes, and deploys waiting for builds.

Logs

combd logs to stdout and stderr, the journal under systemd. A cell that crashes is logged with the reason and the tail of what it printed, so a Rust panic’s message shows up beside it:

object "acme/shop/cart/42" trapped: unreachable (panicked at src/lib.rs:12: ...)

From outside

GET /_combd/ping answers {} and is cheap. The arena’s scripts wait on it to know a node is up.