Interview Q&A · questions with model answers

Kubernetes Interview Questions

Part of the study plan for: DevOps Engineer · Site Reliability Engineer (SRE) · Cloud Engineer

Ordered by how often they're asked. Most-asked answers are free to read in full; members see every answer and can rate their confidence on each.

  1. Most asked ConfigMaps and Secrets: how do they differ, and how should secrets really be handled?

    Both hold configuration that pods consume as environment variables or mounted files. Secrets are intended for sensitive data, but by default they are only base64-encoded, stored in etcd, and…

  2. Most asked What is the difference between resource requests and limits, and what are the QoS classes?

    Requests are what the scheduler reserves and what the pod is guaranteed; limits are the maximum it may use. Exceeding the memory limit gets the container OOM-killed; exceeding the CPU limit gets it…

  3. Most asked How does autoscaling work in Kubernetes? Compare HPA, VPA, Cluster Autoscaler and Karpenter.

    The Horizontal Pod Autoscaler changes the number of replicas based on metrics (CPU, memory, or custom and external metrics); the Vertical Pod Autoscaler recommends or sets CPU and memory requests;…

  4. Most asked Ingress or Gateway API: how do you expose HTTP services, and what has changed recently?

    An Ingress defines HTTP routing rules (hosts, paths, TLS) implemented by an ingress controller. The Gateway API is its successor: role-oriented resources (GatewayClass, Gateway, HTTPRoute,…

  5. Most asked Helm or Kustomize: how do you manage manifests?

    Helm packages manifests as charts with Go templating, values files, versioning, dependencies and release history; Kustomize keeps plain YAML and applies overlays and patches per environment without…

  6. Should you run databases on Kubernetes?

    It is possible and increasingly common with mature operators (CloudNativePG, Percona, Strimzi for Kafka, the Zalando Postgres operator), but it requires real expertise in storage, backups, failover…

  7. What are labels, selectors and annotations, and how should you use them?

    Labels are key-value pairs used to identify and select objects (Services select pods by labels, Deployments manage pods by labels, kubectl get -l). Annotations hold non-identifying metadata for…

  8. What is the difference between a Deployment's rollout and a restart, and when would you use kubectl rollout restart?

    A rollout happens when the pod template changes (new image, new environment variable): a new ReplicaSet is created and pods are replaced gradually. kubectl rollout restart triggers the same rolling…

Was this page helpful?

Report a mistake