K8S Notes

Bookmark this to keep an eye on my K8s notes updates!


Project maintained by kevinsulatra Hosted on GitHub Pages — Theme by mattgraham

Kubernetes Architecture

Control plane nodes in a Kubernetes cluster typically host the following services:

  1. API Server:
    • Serves as the front-end for the Kubernetes control plane.
    • Validates and processes RESTful API requests, initiating corresponding actions within the cluster.
  2. etcd:
    • Consistent and highly-available key-value store used as Kubernetes’ primary data store.
    • Stores configuration data, ensuring that the entire cluster maintains a consistent state.
  3. Scheduler:
    • Watches for newly created Pods with no assigned node and selects a node for them to run on.
    • Considers factors such as resource availability, affinity/anti-affinity specifications, and constraints.
  4. Controller Manager:
    • Runs controller processes, responsible for observing the state of the cluster and making necessary changes to achieve the desired state.
    • Examples include the replication controller, endpoint controller, and namespace controller.
  5. Cloud Controller Manager (Optional):
    • Communicates with the underlying cloud provider’s API to manage resources in the cloud (e.g., load balancers or storage).
    • Specific to cloud-based Kubernetes deployments and is optional based on the environment.

Worker nodes in a Kubernetes cluster typically consist of the following components:

  1. Kubelet:
    • The primary agent running on each worker node.
    • Responsible for ensuring that containers within Pods are running and healthy.
    • Communicates with the control plane to receive instructions and report the status of its assigned node.
  2. Container Runtime:
    • The software responsible for running containers, such as Docker, containerd, or cri-o.
    • Implements the Container Runtime Interface (CRI) to interface with the Kubelet.
  3. Kube Proxy:
    • Maintains network rules on nodes, enabling communication between Pods and external traffic.
    • Implements the Kubernetes Service abstraction, ensuring load balancing and network proxying.
  4. Pods:
    • Basic building blocks of a Kubernetes application.
    • Containers within a Pod share the same network namespace, enabling them to communicate easily.
  5. cAdvisor (Optional):
    • Stands for Container Advisor.
    • Collects, aggregates, processes, and exports information about running containers.
    • Optional, but can be used for monitoring and performance analysis.

These components collectively form the worker node, responsible for executing applications and running containers as directed by the control plane.

Kubernetes Fundamentals