Skip to main content

K3s Appliance Troubleshooting

Run these as root on the machine. k3s's own kubectl with its kubeconfig spelled out is the one to use: a plain kubectl on the host may be another one, reading another config.

k3s kubectl --kubeconfig /etc/rancher/k3s/k3s.yaml get nodes,pods -A -o wide
k3s kubectl --kubeconfig /etc/rancher/k3s/k3s.yaml get events -A --sort-by=.lastTimestamp
systemctl status k3s
journalctl -u k3s -f

Start with sudo ./install.sh status. It exits 0 when healthy and 1 when not, and its output says which part is not.

The installer stops or waits​

SymptomCause and fix
install.sh exits 2 with the usage textA mistake on the command line, found before anything changed. The last line says what. A bare ./install.sh also stops here: give --backup-dest, or --no-offbox-backup for a proof of concept
It says the bundle "was built without the 'cluster' profile" (or ha, or monitoring)The tarball is a single-machine one. A cluster, --ha or --monitoring needs a bundle built with those profiles: ask Support for it
A join stops before it changes anything, naming the release or the k3s versionThe machine's bundle is not the cluster's. Extract the same release the cluster runs and run it again
A bare install.sh on a cluster's first server is refused, naming --joinIts etcd directory is gone (after an etcd restore it must rejoin through the restored server): sudo ./install.sh --join <API address>. A bare run would start a second, separate cluster
--s3-bucket is goneEKB keeps its files in fourteen buckets, not one. The message lists them. Create every one on your S3, or give --s3-bucket-prefix and create the prefixed names: see Install
preflight: the FAIL above stops the installFix what the FAIL line names and run again. sudo ./install.sh preflight repeats the checks without installing
bundle integrity check FAILEDA file in the bundle is missing or altered. Nothing on the machine changed. Copy the tarball again, run sha256sum -c on it, extract it into an empty directory and re-run
It waits a long time for the node to be ReadyThe first start imports every bundled image, which takes minutes on a slow disk. It waits up to 15 minutes; sudo ODIN_READY_TIMEOUT_SECONDS=1800 ./install.sh waits longer. Watch journalctl -u k3s -f

Preflight results​

CheckWhat it means and what to do
cgroupk3s needs cgroup v2. Enable it on the host
default routek3s will not start without an IPv4 default route, even air-gapped. Add one over the LAN interface, and make it permanent in the host's network configuration
portsSomething else holds a port EKB needs. The line names the port and the holder
time syncThe clock is not synchronized. It is a FAIL when no time service is running at all, and a WARN when one runs but has not caught up. Turn on chrony or systemd-timesyncd and point it at a time source the site can reach
s3 bucket, s3 buckets, s3 endpointWith your own S3. s3 bucket <name>: that bucket is missing, or the key cannot write to it. Create every bucket in the list printed under the FAIL lines, twelve in all, and check the key's permissions. s3 endpoint: the endpoint or the key does not work at all; check the URL, its certificate, that the machine reaches it, and the key. s3 buckets as a FAIL or WARN: preflight could not make the check, and the line says why (for example, the --s3-creds file cannot be read)
s3 keysA WARN: the buckets take writes, but the key cannot list buckets. Generated images and meeting recordings will fail to save. Give the key that right (s3:ListAllMyBuckets on AWS)
disk syncSynchronous writes are slower than 10 ms: k3s and PostgreSQL will be slow. Use local SSD or NVMe
cpus, memory, disk spaceUnder the provisional minimums (4 CPUs, 14 GiB, 50 GiB free). Some pods may never start
swapSwap is on. A pod that outgrows its memory then slows the whole machine. swapoff -a and remove swap from /etc/fstab
hostname/etc/hosts gives the machine's name two addresses. Keep one line, with the address other machines reach it on
firewalldIt is running, and install.sh opens the ports and trusts the pod and service networks itself (the PASS line lists them). A WARN means you ran with --no-host-setup: open the ports it lists and trust the networks, using the firewall-cmd lines it prints. If the install stops with firewall-cmd could not open ..., read firewalld's message in it, fix that, and run install.sh again
selinuxSELinux is enforcing. A PASS says install.sh installs the k3s-selinux policy from the bundle and turns it on. A FAIL means the bundle has no package for this OS: install k3s-selinux (with container-selinux) from the OS's repositories, then run install.sh again. A WARN means --no-host-setup: install the package and set selinux: true in a k3s drop-in as the line says. If the install stops with could not install the SELinux policy from the bundle, the package manager's output is printed above it; the usual cause is an OS older than RHEL 9.2 or 8.6 (the bundled container-selinux needs a recent selinux-policy), and the fix is to update the OS or install k3s-selinux yourself

EKB does not load​

SymptomCause and fix
The page does not load by the machine's IP addressWith a domain, the web, API and files routes match only their own host names. Browse by name, or test with curl --resolve odin.corp.example:443:127.0.0.1 -k https://odin.corp.example/
Browsers refuse the certificateWithout --tls-cert and --tls-key, a self-signed certificate is served: for a proof of concept only. Renew or install the real one with install.sh upgrade --tls-cert ... --tls-key ...; the certificate must cover all three host names
File links and the document preview do not openWith the bundled MinIO they need --domain and a certificate (--tls-cert, --tls-key), or your own S3. A domain without a certificate does not open them. See File links and the storage address
The install stops saying the pods could not verify the files hostYour certificate does not lead to a root the application trusts. Pick one: append the CA's root certificate to the --tls-cert file (cat server.crt intermediate.crt root.crt > fullchain.pem), install the CA in this machine's trust store (update-ca-certificates on Ubuntu, update-ca-trust on RHEL), or use your own S3 (--s3-endpoint). Nothing on the machine was changed; run install.sh again
Uploads, downloads or the document preview fail after a certificate was replaced or expiredWith the shared storage address the application reaches its storage through Traefik and TLS and trusts the bundle the installer built. Run install.sh again with the current --tls-cert and --tls-key: it rebuilds the bundle and restarts the application when the bundle changed. sudo ./install.sh status shows the storage address, the DNS rule and the trust bundle, each in place or MISSING. To test from the application itself: k3s kubectl --kubeconfig /etc/rancher/k3s/k3s.yaml -n default exec deploy/fastapi-backend -- python -c 'import os, requests; u = os.environ["S3_ENDPOINT_URL"]; print(u, requests.get(u.rstrip("/") + "/minio/health/live", timeout=20).status_code)' prints the address and 200 when the name resolves and the certificate verifies
Pods are not Ready, or the chart job did not finishRead the chart job's log: k3s kubectl --kubeconfig /etc/rancher/k3s/k3s.yaml -n kube-system logs job/helm-install-odin-services
status lists workloads that are not ReadyDescribe them with kubectl -n default describe pod <name> and look at the events. Memory is the usual cause on a small machine

Upgrades​

SymptomCause and fix
It refuses to skip a minor versionk3s upgrades one Kubernetes minor at a time. Upgrade through the releases in between
It refuses an older releaseGoing back needs --force, and the Kubernetes minor must not be older
It says no --backup-dest is configuredThe install has no backup destination (--no-offbox-backup), so the upgrade has nowhere to put the backup it takes first. Nothing changed. Give --backup-dest, or back up another way and re-run with --yes: see Without a backup destination
The chart's helm upgrade failedk3s leaves the release for an operator rather than reinstalling it. Read the chart job's log (above), and contact support. The backup taken first is in your backup destination
It timed out waiting for the chartThe new bundle is in place and the upgrade may only be slow. Follow the chart job, check status, and run upgrade again from the same bundle

Backups​

SymptomCause and fix
status reports the backup as unhealthyThe last good backup is older than 26 hours (2 when hourly), or the last run failed. Read journalctl -u odin-backup -u odin-backup-datastore
Backups fail to a directoryThe destination is not mounted, or it is full. /etc/fstab mounts it, so it must be mounted
A cluster server's backup fails with "is not shown to be the storage the other servers back up to", or with "No lock was taken and no backup was made"The directory --backup-dest is not shown to be the storage the cluster's servers share: the marker (.odin-install-<cluster id>) is not in it. Mount the same NFS export at the same path on every server, run sudo ./install.sh --backup-dest <dir> on one server where it is mounted (any server, the first or a joined one, which writes the marker), then retry here (a joining server waits up to 2 minutes for the marker before it stops). Or use an s3:// destination
A cluster server's backup fails with "the window's backup is not complete"Another server took this window's lock and has not finished it. Check systemctl status odin-backup.service on the server named; if its run is gone, kubectl -n kube-system delete configmap odin-backup-<full|data>-<window>-<destination tag> (the full name is in the error message), then sudo systemctl start odin-backup.service. A lock that stays is taken over after 6 hours. odin-backup-failed can also fire briefly when one backup is longer than the wait, and clears when it finishes
Backups fail to S3Check the credentials file, the bucket and the endpoint. Without --s3-endpoint on the install, an s3:// destination is on AWS S3, which an air-gapped machine cannot reach. The set is staged under /var/tmp first, so keep free space there
backup.sh says this install was rebuilt on the secrets of a backup set that has not been restored into it yetIntended, after restore.sh --extract-secrets: a backup of the still-empty install would push out the sets that hold your data. Finish the restore, which lifts the hold: see Recovering from the loss of the machine
restore.sh cannot connect to an s3:// source that the scheduled backups write to, or finds no set thereRun by hand, restore.sh looks on AWS S3 unless you give --s3-endpoint. Give your install's endpoint
restore.sh says the MinIO client (mc) was not foundThe file mirror needs tools/mc, which the tarball ships. Run restore.sh from the extracted tarball directory
restore.sh says the postgres pod never appearedA restore expects a running install of the same release on the machine. Install that release first, then restore
restore.sh says this install's generated secrets are not the ones the set was taken underThe backup is from another install, and its database only works with that install's credentials. Rebuild the machine on them: follow the steps it prints, or Recovering from the loss of the machine
restore.sh --datastore=restore says the set was taken on another hostA k3s datastore fits only the machine it came from. Restore without that flag
restore.sh says a set has no COMPLETE object or filebackup.sh never finished writing that set, so it cannot be trusted. Restore an earlier set

Collect information for support​

sudo ./install.sh status
k3s kubectl --kubeconfig /etc/rancher/k3s/k3s.yaml get nodes,pods -A -o wide
k3s kubectl --kubeconfig /etc/rancher/k3s/k3s.yaml get helmchart -A -o yaml
k3s kubectl --kubeconfig /etc/rancher/k3s/k3s.yaml -n kube-system logs job/helm-install-odin-services --tail=200
journalctl -u k3s --since "1 hour ago"

Attach the output to your support ticket. The Versions lines of status give the release and k3s versions. Do not attach /etc/odin/install.env: it stores --db-url and --redis-url as you gave them, passwords included. Do not attach backup sets either: they hold secrets.