IT lexicon › Infra & Ops › Stern

Stern

Infra & Ops På svenska → Updated: 2026-07-29

Tails the logs of every pod matching a pattern at once, colour-coded per pod, and automatically picks up new pods as they appear.

The limitation in kubectl logs shows up immediately: it wants one pod, and in a deployment with six replicas you don't know which one is handling the request you're debugging. Opening six terminals works until a rolling update replaces all of them, at which point all six commands die and you start over with new pod names. Stern instead takes a regular expression or a label selector, connects to everything matching, and keeps doing so as pods come and go. Output from different pods is interleaved but stays distinguishable because each pod gets its own colour. It is one of the tools you install on day two as a cluster operator and then never go without.

← Back to the lexicon