Understanding Cluster Components · CKA
What happens inside a cluster when you run a kubectl command?
Learn with progress and quizzesFirst, understand the concepts.
Control plane
The API server handles requests, while etcd stores cluster state. The scheduler decides where to run Pods that have not yet been assigned to a node.
Worker node
The kubelet works with the container runtime to run the Pods assigned to its node. Networking details depend on the implementation used by the cluster.
Desired state and current state
Controllers continually reconcile the difference. Setting a Deployment to three replicas asks Kubernetes to maintain that number of replicas.
Why it matters
A request for three web replicas passes through API storage, placement, and process startup. A successful kubectl request does not mean all three Pods are already ready.
Work through the reasoning
Follow the request
The API server validates and stores desired state. Controllers create Pods, the scheduler chooses nodes, and each node’s kubelet asks the runtime to prepare execution. Observe these stages separately.
Match symptoms to stages
For a Pending Pod without nodeName, start with scheduling events. For an assigned Pod with ImagePullBackOff, inspect the image and registry access. If the API request itself fails, separate endpoint, credentials, and connectivity.
Learn by doing.
You need kubectl and access to your own practice Kubernetes cluster. Each lab is independent. Check your current context first, then run the commands in your own terminal.
List the nodes and system Pods in your cluster, and find where the control plane components run.
kubectl config current-context
kubectl cluster-info
kubectl get nodes -o wide
kubectl get pods -n kube-system -o wideHow to check your result
Identify the node names and roles, and explain the components in kube-system. Control plane Pods may not be visible in a managed cluster.
Apply what you learned
A Pod has a node assignment but cannot download its image. Should you investigate the scheduler first? What evidence should you record?
Reveal the reasoning after trying
Record nodeName, containerStatuses, and Events. Since placement happened, inspect image references, credentials, pull errors, and registry connectivity from the node. There is no evidence here that restarting the scheduler will help.
Ready to check your understanding?
Which component chooses a node for a Pod that has not yet been assigned one?
- etcd
- kube-scheduler
- kubelet
- kube-apiserver
Reveal the reasoning after trying
kube-scheduler
The scheduler selects the node. The kubelet manages the execution of Pods assigned to its own node.