Skip to content
$ lynuxpro

INTERVIEW PREP

Interview questions

570 questions from real DevOps, SRE, platform engineering and MLOps interviews, with the answer an interviewer wants to hear. Try answering out loud first, then open the model answer.

Showing 16–20 of 20 questions

Learn Kubernetes →
16.How do you upgrade a cluster without downtime?Senior

Upgrade the control plane first, then node pools one at a time; cordon and drain nodes, with PodDisruptionBudgets, multiple replicas and anti-affinity so apps stay available. Check deprecated APIs before upgrading.

17.How would you secure a multi-tenant cluster?Senior

Namespace per team with RBAC least privilege, NetworkPolicies default-deny, Pod Security Admission (restricted), ResourceQuotas and LimitRanges, admission policies (Kyverno or Gatekeeper), image signing, and secrets from an external store.

18.How does RBAC work in Kubernetes?Senior

A Role (or ClusterRole) lists allowed verbs on resources; a RoleBinding (or ClusterRoleBinding) gives it to users, groups or ServiceAccounts. Give least privilege, avoid cluster-admin, and test with kubectl auth can-i.

19.What happens when you run kubectl apply -f deployment.yaml?Senior

kubectl sends the object to the API server, which authenticates, authorizes, runs admission controllers and stores it in etcd. The Deployment controller creates a ReplicaSet, which creates Pods; the scheduler picks nodes; kubelet on each node starts the containers through the runtime.

20.How do NetworkPolicies work, and what is a good default?Senior

They are firewall rules for Pods, chosen by labels, enforced by the CNI (Calico, Cilium...). Start each namespace with a default deny for ingress (and ideally egress), then allow only the traffic each app needs, including DNS.