Kubernetes and Its Architecture Diagrams


Kubernetes is also known as k8s or “kube” is an open source Container Orchestration platform. It automates many of the manual processes involved in deploying, managing, and scaling containerized applications.

Who Developed Kubernetes

Google’s Engineers first designed and developed the Kubernetes and was one of the early contributors to Linux container technology. Red Hat was the next companies to work with Google on Kubernetes, prior to launch. In year 2015, Google donated the Kubernetes project to the newly formed Cloud Native Computing Foundation (CNCF).

Kubernetes Charctersitics

  • Kubernets provides a flexible framework for distributed systems
  • Kubernets orchestrate the containers across multiple hosts
  • It can maximize the hardware utilization to run the enterprise applications
  • Enable control and automation for application deployments and updates
  • Allows mounting and adding storage to run stateful apps
  • Allows scaling the containerized applications and their resources on the fly
  • Alway-ON with declaratively manage services, which guarantees the deployed applications are always running with no downtime in a production environment
  • Allows health-check and self-healing for the applications with autoplacement, autorestart, autoreplication, and autoscaling.

Kubernetes Architecture 

Kubernetes Architecture follows a client-server architecture approach which is consist of following two main components.

  • Master Nodes
  • Worker Nodes

  • Master Node: Master node has the responsibility to manage the cluster and acts as first point of contact for almost all administrative tasks. Depending upon the setup, there can be one or more master nodes in a cluster to serve high availability but by default there is a single master node. A master node comprises different components such as Controller-manager, ETCD, Scheduler, and API Server.

    • API Server: It is the first point of contact for the entirety of the REST commands, which are used to manage and manipulate the cluster.
    • Scheduler: The scheduler, as its name suggests, is responsible for scheduling tasks to the worker nodes. It also keeps the resource utilization data for each of the slave nodes.
    • ETCD: It is majorly employed for shared configuration, as well as for service discovery. It is basically a distributed key-value store.
      • Kubernetes uses etcd as a key-value database store. It stores the configuration of the Kubernetes cluster in etcd
      • It also stores the actual state of the system and the desired state of the system in etcd
      • It then uses etcd’s watch functionality to monitor changes to either of these two things. If they diverge, Kubernetes makes changes to reconcile the actual state and the desired state
    • Controller-manager: It is a daemon that is responsible for regulating the cluster in Kubernetes, and it also manages various other control loops that are non-terminating.
      • Replication controller: Manages pod replication
      • Node controller: Responsible for noticing and responding when nodes go down.
      • Job controller: Watches for Job objects that represent one-off tasks, then creates Pods to run
        those tasks to completion.
      • Endpoints controller: Populates the Endpoints object (that is, joins Services & Pods).
      • Service Account & Token controllers: Create default accounts and API access tokens for new namespaces
  • Worker/Slave Nodes: Worker also known as slave nodes consist of all the needed services that are required to manage networking among containers. Worker nodes communicates with master and allocate resources to scheduled containers.

  • A worker nodes have the following components:
    • Docker container: Docker must be initialized and run on each worker node in a cluster. Docker containers run on each worker node, and they also run the pods that are configured.
    • Kubelet: The job of kubelet is to get the configuration of pods from the API server. It is also used to ensure that the mentioned containers are ready and running.
    • Kube-proxy: Kube-proxy behaves like a network proxy and act as a load balancer for a service on any single worker node for pods running on the node by implementing east/west load-balancing using NAT in iptables. The kube-proxy handles network communications inside or outside the cluster
    • CAdvisor: Used for monitoring resource usage and performance
    • Label: Used to identify pods
    • Pods: A pod can be thought of as one or more containers, which can logically run on nodes together


Related Posts:


You may also like...