K8s by Example: Control Plane
| The control plane makes global decisions about the cluster. It consists of: API Server (communication hub), etcd (state store), Scheduler (Pod placement), Controller Manager (reconciliation loops). Usually runs on dedicated nodes. |
| architecture.txt | |
| All components communicate through the API Server. etcd stores state, Scheduler places Pods, Controllers reconcile state. | |
| terminal | |
| The API Server is the front door to Kubernetes. All components communicate through it. It validates requests, updates etcd, and exposes the REST API. | |
| terminal | |
| Check API Server health with raw endpoints. The proxy command exposes the API locally for direct REST calls. | |
| terminal | |
| etcd stores all cluster state - Pods, Services, Secrets, ConfigMaps. Distributed key-value store using Raft consensus. Always run multiple replicas. | |
| terminal | |
| Back up etcd regularly. Keys follow the format: | |
| scheduler-workflow.txt | |
| The Scheduler assigns Pods to nodes. It watches for unscheduled Pods, filters nodes by constraints, scores remaining nodes, then binds Pod to best node. | |
| Scoring ranks nodes by soft preferences. Highest score wins. | |
| terminal | |
| View scheduler decisions in Pod events. If a Pod is Pending, check events for why no node was selected. | |
| controllers.txt | |
| Controller Manager runs control loops that watch state and reconcile current state toward desired state. Each controller handles one resource type. | |
| cloud-controllers.txt | |
| Cloud Controller Manager handles cloud-specific logic. Separated so cloud providers can release independently. Manages load balancers, routes, and node lifecycle. | |
| ha-control-plane.txt | |
| High availability requires 3+ control plane nodes. API Servers run behind a load balancer. etcd needs odd number for quorum. Scheduler and Controller Manager use leader election. | |