Skip to content
Opod

Install

Preflight

opodcp preflight checks a cluster before helm install. Every row, its severity, and the flags that change what it checks.

In short

opodcp preflight reads your cluster and tells you, row by row, whether helm install opodcp will work. It changes nothing. A fatal row (✘) blocks the install; a warning (!) or information row (i) tells you about a value you may want to set. The chart runs the same check as a hook, so running it first only shows you the answer sooner.

When you need it

  • Before the first helm install, on any cluster.
  • Before an upgrade, with --upgrade, to see what the pre-upgrade hook will say.
  • When helm install or helm upgrade stops with Job Failed and you need the full report.
  • Before you raise replicas or set workloads.leaderPool, to check there are enough nodes.

Do it

  1. Run it against the cluster

    docker run --rm --network host -v ~/.kube:/kube:ro \
      ghcr.io/opod-io/opodcp:0.3.6 preflight --kubeconfig /kube/config

    Add the flags of the release you will install, so the rows judge the same thing: --namespace opodcp, --replicas 3 for HA, --leader-pool opod.io/pool=fronts with a leader pool.

  2. Fix each fatal row

    Every ✘ row ends in → and the remedy. For example:

    ✘ dns.coredns        0 CoreDNS pod(s)  → cluster DNS is required (workers join leaders via Service DNS)
  3. Run it again, then install

    Repeat until no row is fatal, then go on with Install on Kubernetes, step 2.

Check it worked

docker run --rm --network host -v ~/.kube:/kube:ro \
  ghcr.io/opod-io/opodcp:0.3.6 preflight --kubeconfig /kube/config; echo "exit=$?"

A good answer ends with cluster ready for: helm install opodcp charts/opodcp -n opodcp --create-namespace and exit=0. That line names the chart by a local path; use oci://ghcr.io/opod-io/charts/opodcp as the other pages do. Warnings and information rows do not change the exit status.

If it fails

OutputCauseFix
error: 1 fatal check(s): k8s.version — …Kubernetes older than 1.28upgrade the cluster
✘ nodes.ready 3/4 nodes Ready → kubectl describe node <notready> (from the release after 0.3.6 the remedy names the NotReady nodes: → kubectl describe node node-d)a node is NotReadykubectl describe node NODE; on an upgrade the hook passes --upgrade and this row is a warning
✘ ha.nodes--replicas is larger than the Ready, schedulable nodesadd or uncordon nodes, or lower replicas
✘ fronts.poolthe leader pool matches fewer than two nodes, or is not a label selectorlabel two nodes so the pool matches, or widen workloads.leaderPool
✘ endpoints.exposeendpoints.expose=gateway and no Programmed Gatewayfix the Gateway, or use endpoints.expose=auto
preflight could not read the cluster: … — retrying once in 5sthe kubeconfig is wrong or the API server does not answerthat is the check failing, not a verdict; fix --kubeconfig or the network and run it again
error: kubeconfig PATH: stat PATH: no such file or directory — pass --kubeconfig PATH or set KUBECONFIG (the release after 0.3.6; 0.3.6 waited 5 s and retried)the file you named is not therepass the right path
unknown cloud provider "ibm" (have: aws, azure, gcp, onprem)--cloud names an adapter this build does not carry (0.2.1 carries only onprem)use one of the names it lists, or leave --cloud out

How it reads the cluster

opodcp preflight reads a cluster and says whether helm install opodcp will work. It changes nothing. The chart runs the same check as a pre-install and pre-upgrade hook Job and refuses a half-install. Run it yourself first to see the answer earlier.

opodcp preflight --kubeconfig ~/.kube/config
opodcp preflight --json | jq '.[] | select(.pass == false)'
 
# without the binary
docker run --rm --network host -v ~/.kube:/kube:ro \
  ghcr.io/opod-io/opodcp:0.3.6 preflight --kubeconfig /kube/config

Each row prints ✔ (pass), i (information), ! (warning) or ✘ (fatal), its id, a message and, on a failure, a remedy after →. A fatal row makes the command exit 1 and names every fatal id. If the check itself cannot read the cluster (an unreachable API server, a bad kubeconfig), it retries once after 5 s and then says preflight could not read the cluster: that is the check failing, not a verdict on the cluster.

Rows

The rows print in this order. A row marked "only when" is left out otherwise.

RowSeverityPasses whenRemedy on a failure
k8s.versionfatalKubernetes 1.28 or newer (an N-2 policy), compared as numbers from 0.3.0 (on 0.2.1 the minor was compared as text, so a three-digit minor failed)upgrade the cluster
nodes.readyfatal (warning with --upgrade)every node is Ready; the message reads 3/4 nodes Ready. Zero Ready nodes is always fatalkubectl describe node <node>
ha.nodesfatal, only when --replicas is above 1there are as many Ready, schedulable nodes as replicas: the chart runs each replica on a node of its ownuncordon or add nodes, or lower replicas
nodes.vendorswarningsome node carries opod.io/gpu-vendor; the message lists the count per vendornone needed: the control plane labels nodes itself from what each node advertises, on every reconcile. opodcp infra up and NFD also set it
gpu.allocatablewarningsome node advertises */gpu, gpu.intel.com/* or tenstorrent.com/*; the message lists the totalsthe chart installs the per-vendor device plugins
storage.defaultwarninga default StorageClass existsneeded only for ha.postgres.provide, pvc:// job checkpoints and the 0.2.1 SQLite volume (k3s: local-path). The control plane itself keeps nothing on a volume
runtime.nvidiawarningRuntimeClass nvidia exists, or no node is labelled nvidiaon k3s, install nvidia-container-toolkit on NVIDIA nodes and k3s registers the class by itself. On EKS, GKE and AKS the class is absent by design: on 0.2.1 create it (see Managed Kubernetes notes); from 0.3.0 GPU pods are rendered without it and the warning needs no action
dns.corednsfatalat least one k8s-app=kube-dns pod runs in kube-systemworkers join leaders by Service DNS, so cluster DNS is required
network.policyinformationsays whether the CNI enforces NetworkPolicy: enforced (naming it), not enforced (naming the network), or unknownwith no enforcement, networkPolicy.enabled=true is stored and does nothing. Install Cilium or Calico (Canal beside flannel) if the namespace must be isolated; when unknown, apply a deny-all policy in a scratch namespace and test
nodes.taintsinformationlists GPU nodes whose taints no pod of ours tolerates. Such nodes are measured and counted, and the placer skips them. GPU-resource taints (for example nvidia.com/gpu) are tolerated without any settingthe workloads.tolerations value to set, printed as --set-json
cp.nodewarning (0.3.0)some Ready, uncordoned node with no hard taint has no accelerator; the control plane prefers such a nodeadd a CPU node, or tolerate a GPU-less node's taint with tolerations. A cluster of GPU nodes only installs and runs as it is
fronts.poolwarning, only with --leader-pool; fatal when the value is not a label selectorat least two Ready, unfenced nodes match the pool; the message names themlabel two nodes so the pool matches, or widen workloads.leaderPool
secrets.at-restwarning; information on a managed clusterevery k3s server runs with --secrets-encryption. On EKS, GKE or AKS the API cannot say, so the row names the provider's settingon each k3s server: sudo k3s secrets-encrypt enable, then sudo systemctl restart k3s. The install key that seals stored connector credentials is a Secret, so it is only as private as etcd
substrate.lwsinformationsays whether the LeaderWorkerSet API is already served by this clusterif this chart did not install that controller, install with substrate.leaderWorkerSet.enabled=false: Helm will not adopt a CRD another release owns (invalid ownership metadata). An upgrade of a release that brought its own needs nothing
policy.enginewarning, only when Kyverno or Gatekeeper is presentnames the enginethe pods the control plane renders meet Pod Security Standards baseline. restricted also needs runAsNonRoot, which the upstream vLLM and llama.cpp images do not support: exempt the release namespace from restricted
ns.opodinformationsays whether namespace opodcp exists alreadyhelm install --create-namespace creates it

Rows a cloud adapter adds

opodcp preflight --cloud <provider> (default onprem, or OPODCP_CLOUD) prints the adapter's rows after the ones above. onprem adds none. The aws, gcp and azure adapters are new in 0.3.0, built and not yet proven on a real cluster:

opodcp preflight --kubeconfig ~/.kube/config --cloud gcp --replicas 3
RowSeverityPasses whenRemedy on a failure
cloud.<provider>.storageclasswarningthe default StorageClass uses the cloud's own CSI driver: ebs.csi.aws.com, pd.csi.storage.gke.io or disk.csi.azure.commake the cloud's class the default (EKS gp3, GKE standard-rwo, AKS managed-csi)
cloud.<provider>.gpu-nodeswarningsome node carries the cloud's accelerator labeladd a GPU node pool
cloud.gcp.autopilotfatalthe cluster is not GKE Autopilotuse GKE Standard: Autopilot forbids the host path the weights live in and the host driver tree the GPU probes read
lws.controllerinformation, or warning when half-installedthe LeaderWorkerSet CRD, webhook and controller are whole (pass), or all absent (gangs then land as per-part Deployments)a half-installed controller would accept a gang and never schedule it: helm upgrade --reset-then-reuse-values restores it. Until it is whole, gang plans are refused with E-GANG-SUBSTRATE
endpoints.exposeinformation; fatal with endpoints.expose=gateway and no ready Gatewaysays how endpoints will be reached from outside and why: one HTTPRoute per endpoint, one Ingress per endpoint or no route from outsideinstall or fix the Gateway (it must be Programmed), name it with endpoints.gateway.name and namespace, or set endpoints.expose=auto

A cloud adapter may add its own cloud.<provider>.* rows. onprem adds none. From 0.3.0, --cloud aws adds cloud.aws.storageclass and cloud.aws.gpu-nodes, --cloud azure adds cloud.azure.storageclass and cloud.azure.gpu-nodes, and --cloud gcp adds cloud.gcp.storageclass, cloud.gcp.gpu-nodes and cloud.gcp.autopilot. These three adapters are built and not yet proven on a real EKS, GKE or AKS cluster.

A missing GPU is a warning, not a failure: the control plane installs and serves its console on a cluster with no GPU.

Example output

✔ k8s.version        Kubernetes v1.31.4+k3s1
✔ nodes.ready        4/4 nodes Ready
✔ nodes.vendors      vendor labels: map[nvidia:2]
✔ gpu.allocatable    allocatable accelerators: map[nvidia.com/gpu:4] on 2 node(s)
! storage.default    default StorageClass:   → no default StorageClass: the chart's optional ha.postgres and pvc:// job checkpoints need one (k3s: local-path); the control plane itself does not
✔ runtime.nvidia     RuntimeClasses: [nvidia]
✔ dns.coredns        1 CoreDNS pod(s)
…
i endpoints.expose   no route from outside — …
cluster ready for: helm install opodcp charts/opodcp -n opodcp --create-namespace

With --json the command prints one array of objects: id, node (cluster), pass, severity (on 0.2.1 a number: 0 information, 1 warning, 2 fatal; from 0.3.0 its name: "info", "warn", "fatal"), message and remedy.

When a fatal row fails, the last line names every fatal id, for example error: 2 fatal check(s): k8s.version, dns.coredns — each is printed above with what to do about it, and the exit status is 1.

Flags

FlagDefaultMeaning
--kubeconfig$KUBECONFIGkubeconfig path; empty = in-cluster
--jsonfalseJSON output
--namespace$OPODCP_NAMESPACE, else opodcpthe namespace the chart installs into; the LeaderWorkerSet controller and the Gateway choice are read there
--cloud$OPODCP_CLOUD, else onpremcloud provider adapter; adds its own checks. An unknown name is refused with the list of registered ones
--upgradefalsea release already runs here (the pre-upgrade hook sets it): NotReady nodes are a warning, zero Ready nodes stays fatal
--leader-pool$OPODCP_LEADER_POOLthe chart's workloads.leaderPool label selector; adds fronts.pool
--replicas1control-plane replicas the release runs; above 1 adds ha.nodes

The pre-install Job

substrate.preflight=true (the default) renders the Job <release>-opodcp-preflight as a Helm pre-install,pre-upgrade hook (weight -5) and as an Argo CD PreSync hook, so a GitOps sync that renders with helm template still runs it. In a fleet release it is not rendered.

What the Job does:

  1. It runs the control plane's own image with preflight, in-cluster. On an upgrade it adds --upgrade. It always passes --replicas from the chart's replicas, and --leader-pool when workloads.leaderPool is set. It also gets the endpoints.expose, endpoints.gateway.* and endpoints.ingress.* settings, so endpoints.expose is judged the way the control plane will judge it.
  2. It runs under its own ServiceAccount, created as an earlier hook (weight -10), with a ClusterRole that can only get and list nodes, namespaces, pods, StorageClasses, RuntimeClasses and Gateways — and, from 0.3.0, the Endpoints, Deployments and webhook configurations the lws.controller row reads (on 0.2.1 it could not read them). From 0.3.0 it also passes --namespace with the release's namespace; on 0.2.1 it judged opod whatever the release namespace was. The role and binding are deleted when the hook succeeds.
  3. It honours the chart's nodeSelector, tolerations and imagePullSecrets, so it runs where the control plane will run. That matters on a cell where only some nodes can pull the image.
  4. A read that fails right after the binding is created is retried once after 5 s.
  5. backoffLimit is 0 and the Job is kept for 10 minutes after it finishes. Its last words go into the pod's termination message as well as its log, so they survive when the log is gone.

When Helm reports only Job Failed, read the pod's status or run the command yourself for the full report:

kubectl -n opodcp get pods -l app.kubernetes.io/name=opodcp -o jsonpath='{.items[*].status.containerStatuses[*].state.terminated.message}'
opodcp preflight --kubeconfig ~/.kube/config --upgrade

To skip the Job (for example on a cluster where a hook cannot run), set substrate.preflight=false and run the command yourself first.

Last updated · Source: content/docs/control-plane-install/preflight.mdx · View as Markdown