Test what you actually know about Kubernetes. Free sample questions below, from easy to hard, with instant explanations.
OOMKilled specifically means the Linux out-of-memory killer terminated the process because it exceeded the memory limit set for the container. Running out of CPU causes throttling rather than a kill, and disk space or probe failures would show up as a different status entirely.
--previous reads the logs from the last terminated instance of the container, not the fresh one currently restarting. For a container that crashes almost immediately, this is often the only way to see what actually happened.
etcd uses the Raft consensus algorithm, which requires a strict majority (quorum) of members to agree before committing a write, so with 5 members that means at least 3 must be reachable. This is exactly why etcd clusters are deployed with odd member counts, so a partition can never leave two halves each believing they might hold quorum. There's also no such thing as an apiserver "cache" acting as a substitute source of truth, kube-apiserver is stateless and depends entirely on etcd for both reads and writes.
Storage, scheduling, and image registries are all handled by other things entirely, none of them are a Service's job. Because Pod IPs constantly change as Pods come and go, a Service's whole purpose is to give a stable name and address that always routes to whichever matching Pods happen to be running right now.
A Pod only shows as Pending BEFORE it's been scheduled onto a node, and everything else in this list (not enough resources, no matching node, an unbound volume claim) are all things that block scheduling itself. An image pull failure happens AFTER a Pod is already scheduled onto a node, which is why it shows up as ImagePullBackOff instead, not Pending.
NetworkPolicy is enforced by the CNI plugin at the pod/node level - it has no visibility into or control over firewalls, security groups, or NAT gateways further upstream in the cloud provider's network. Traffic can leave the pod exactly as allowed and still be dropped somewhere else entirely.
Pods come and go, and each new one gets a new IP, so nothing else in the cluster could reliably talk to them directly. A Service gives you one stable address (an IP and a DNS name) that stays the same and automatically load-balances traffic to whichever Pods happen to be running right now.
No single command tells the whole story of a crash: --previous shows you what the container printed right before it died, describe pod shows recent events and how many times it's restarted, and get events shows broader scheduling/health signals from the cluster. Using all three together gives you the fullest picture of what actually went wrong.
With maxUnavailable at 0, Kubernetes can't remove any old pods until new ones are ready, and maxSurge is supposed to create extra pods temporarily to make that possible, but if the cluster has no spare capacity those surge pods just sit Pending forever, deadlocking the rollout. This is purely a capacity problem, unrelated to revision history limits or probes.
kubectl apply reads whatever's described in a YAML file and either creates it (if it doesn't exist) or updates it (if it does), which is exactly the 'point at this file and make the cluster match it' behavior you want for deploying from app.yaml.
Real scenario-based DevOps questions, hands-on practice, and clear explanations for every answer.