Skip to content
Opod

Design decisions

Kubernetes, capacity and placement

Kubernetes as the only executor but never the truth, a ledger of measured VRAM, dedicated cards by default, advice instead of refusal, identities instead of names, and proof per engine and vendor.

These decisions decide where a model runs and how opod knows it fits. Each one says what it gives you and what it costs.

Kubernetes is the only executor, and never the truth

The decision. opod runs every leader, worker, gang and job as a Kubernetes workload. There is no second way to deploy. On bare machines, opodcp infra up installs k3s for you over SSH, so you never run Kubernetes yourself. And Kubernetes holds no decision: the plan in opod's database is the desired state, and Kubernetes objects are rendered from it.

Why. Kubernetes already restarts pods, schedules them, mounts Secrets, lands a multi-pod gang as one unit (LeaderWorkerSet) and scales replicas (KEDA). Rebuilding that would be a second, weaker Kubernetes. But Kubernetes does not know VRAM budgets, licences, team quotas or which revision was proven, so it cannot be the record.

What it gives you.

  • Healing, rescheduling and gang landing that are Kubernetes' own, tested by everyone who runs it.
  • One product API. The console, the CLI and scripts all speak it; kubectl shows you what opod rendered.
  • A cluster you can inspect with the tools you know. Every object carries opod.io/endpoint-id and opod.io/cell.
  • A helm upgrade of opod does not restart serving pods. A changed pod template waits for a rollout, which proves it.

What it costs.

  • You need Kubernetes 1.28 or later, or a machine that can take k3s. There is no "just a binary" install of the control plane. Core alone runs without Kubernetes (opod up, opod join), with no control plane.
  • A hand edit to an opod object is drift. The reconciler puts it back to the plan.

What we chose not to do. A host executor beside Kubernetes was decided and then reversed the next day. The control plane reaches the cluster only through one interface (controller.Executor), so a second executor stays possible if a customer ever refuses Kubernetes. No custom operator or CRD spine either: the objects are plain Deployments, Services, LeaderWorkerSets and Jobs, written with Server-Side Apply.

VRAM is measured, never assumed

The decision. A probe DaemonSet per vendor reads every card every 20 s, and the control plane collects the reading: in 0.3.6 the probe pushes it, and from the release after 0.3.6 every control-plane replica reads each probe itself, so each replica holds every card. The ledger holds, per card, the measured size, what each worker claims, and what something outside opod already uses. The placer judges every plan against those numbers. A card nobody could measure is never treated as having room.

Why. A card's nameplate is not its free memory. Drivers reserve some, other processes hold some, and one SKU id can ship with two memory sizes. A placer that guesses high overcommits the card, and the engine dies at load.

What it gives you.

  • A plan that does not fit is refused before any pod starts, with the numbers: E-FIT names the need, the free memory and the largest card.
  • Memory used by something outside opod is seen and avoided.
  • Every number comes from the driver or the hardware, never from a table. NVIDIA reports through its own tool. AMD's amdgpu publishes size and use in sysfs. Tenstorrent maps its whole board memory through the PCI window. Intel reads its memory regions from the driver's own query.
  • An unhealthy card (uncorrected ECC errors, an active slowdown) is fenced for new placements. Nothing running is killed.

What it costs.

  • A card is placeable only after its first reading: a fresh control plane waits for the telemetry probe, about two minutes.
  • Where a driver reports no size, the card is allocated whole and cannot be packed. For an Intel card that answers neither query, the remedy is a host setting (Resizable BAR). We keep no table of capacities by device id, on purpose: one wrong row would overcommit every card of that model.
  • Without the opod.io/gpu-vendor label on a node, no probe lands there, and every create on it is E-FIT. The control plane writes the label from device-plugin resources; on an unusual cluster, check it first.

See Placement and the VRAM ledger.

The VRAM ledger: place a model

Change the model or the class: the drawing shows where it goes before you place it

best fit: node-a/0 — 7.4 GB left after. Looser fits, kept for bigger models: node-a/1. Shared placement is NVIDIA only (E-SHARED-VENDOR elsewhere); workers on one card share its memory and fault domain.
our workersplaced / would go hereused outside opod (held, not free)driver reserve

Dedicated by default, shared by choice

The decision. A worker owns its whole card unless its plan says colocation: shared. Shared workers are packed by VRAM budget, and only beside other shared workers.

Why. Outside MIG, two processes on one GPU are isolated only by their budgets: a memory spike or a fault in one can stop the other. An endpoint with a strict latency target should not learn that by surprise.

What it gives you. A safe default with nothing to read first, and many small models per card when you ask for it, with each budget checked against the measured card.

What it costs. Shared is NVIDIA-only today (E-SHARED-VENDOR elsewhere). Isolation on a shared card is cooperative, not hard. A dedicated card may sit partly empty: that is the price of the guarantee.

Advise, do not refuse

The decision. When a plan is possible but slow or risky, opod accepts it and says so in the loudest advisory it has. It refuses only what cannot work. The clearest case: tensor parallelism across machines used to be refused on any fabric not proven fast. It is now allowed, with the cost stated: on plain ethernet, every all-reduce of every token crosses the network, and throughput is commonly an order of magnitude lower than one machine.

Why. The refusal was right about physics and wrong about ownership. You know your fabric, and SGLang's own multi-node scheme is tensor parallel across nodes. A refusal that blocks a whole engine helps nobody.

What it gives you. Every shape the engine supports is available. The advisory names the shapes that avoid the cost: pipeline parallel across nodes (one hop per token), tensor parallel inside one machine (none). A passed fabric proof turns the warning clean.

What it costs. You can now build a slow endpoint on purpose, so read Preview's advisories. Some things stay refused because they are arithmetic or the engine: a tensor group wider than a node's devices (E-TP-DOMAIN), a tensor split on llama.cpp.

The same rule applies elsewhere: with no KV store, an endpoint is created without the peer KV tier and warned; with no checkpoint store, a job runs with "no resume" stated.

See Gangs and parallelism.

Identities, not names

The decision. Everything opod manages is tied to an id, never only to a name. Endpoint objects are named opodcp-ep-<name>-<id6> and selected by the label opod.io/endpoint-id. A worker process carries a boot id minted at start. Every delete, sweep and pod read is scoped by the id.

Why. A name can come back as a new thing. Three bugs had one shape: a re-created worker kept the "ready" rows of a dead one; a control plane with a fresh database adopted another store's workloads and their dead join token; a router dialled a re-created worker at its old pod IP.

What it gives you.

  • Re-creating an endpoint with an old name never adopts the old one's objects.
  • A second control plane pointed at the same namespace reports foreign objects (alert endpoint.foreign-objects) and never touches them.
  • A run that fails gives back what it took, newest first, and the cleanup finds our objects by id only. Nothing that is not ours is ever deleted.

What it costs. Object names are longer and carry a suffix. The leader's Service is the one exception, opodcp-ep-<name>, because clients and workers dial it by name.

Every engine and vendor is proven, or refused by name

The decision. opod says "supported" for an engine on a vendor only when it has served requests there through the control plane. Every combination without an image or without a path is refused when the plan is written, with a named code and the alternatives: E-NO-ENGINE, E-IMAGE-FAMILY, E-SHARED-VENDOR, E-KV-OFFLOAD and more.

Why. A plan that is accepted and then fails at load costs an operator an afternoon. A refusal by name costs one read.

What it gives you. A matrix you can trust: supported, experimental, delegated or unsupported per engine and vendor, and a separate proven mark. GET /api/v1/compat/verified lists the exact paths proven in your own cell, and verifiedOnly: true makes an auto plan refuse anything else.

What it costs. NVIDIA has every feature; other vendors have fewer engines and fewer features, and the table says so cell by cell. Some combinations that may work are refused until they are proven.

See Mixed GPU vendors and Images.

Last updated · Source: content/docs/design/kubernetes-and-capacity.mdx · View as Markdown