Day 30: Kubernetes Architecture
What is Kubernetes (K8s) and Why "K8s"?
Kubernetes (K8s) is an open-source container orchestration platform that automates the deployment, scaling, and management of containerized applications. It simplifies the management of complex containerized applications across clusters of hosts. The name "Kubernetes" comes from the Greek word for "helmsman" or "pilot," reflecting its role in steering and managing containerized workloads.
Benefits of Using Kubernetes
Scalability: Kubernetes enables effortless scaling of applications by adding or removing containers based on demand.
Fault Tolerance: It ensures high availability and fault tolerance by automatically restarting containers that fail or become unresponsive.
Portability: Kubernetes provides a consistent environment across development, testing, and production, allowing seamless application deployment.
Resource Efficiency: It optimizes resource utilization by efficiently scheduling containers on underlying infrastructure.
Automation: Kubernetes automates various aspects of application management, reducing manual intervention and human errors.
Architecture of Kubernetes
Kubernetes follows a master-slave architecture, consisting of:
Master Node: Controls the Kubernetes cluster and manages its state.
Worker Nodes (Minions): Host the applications and containers managed by Kubernetes.
Control Plane
The Control Plane, also known as the Master Node, consists of several components:
API Server: Serves as the central management point and handles communication with Kubernetes objects via the Kubernetes API.
Scheduler: Assigns newly created pods to worker nodes based on resource availability and scheduling policies.
Controller Manager: Ensures that the cluster's current state matches the desired state, handling node failures, scaling, and other tasks.
etcd: Stores the cluster's configuration data and represents the cluster's single source of truth.
Difference Between kubectl and kubelet
kubectl: Command-line interface (CLI) tool used to interact with the Kubernetes cluster, allowing users to deploy and manage applications, view logs, and perform other administrative tasks.
kubelet: Agent that runs on each worker node and communicates with the Kubernetes API server. It manages the containers on the node and ensures that the containers described in the pod manifests are running as expected.
Role of the API Server
The API server acts as the frontend for the Kubernetes control plane, exposing the Kubernetes API and serving as the gateway for all administrative tasks. It validates and processes requests, updates the cluster state stored in etcd, and communicates with other components to execute user commands and manage cluster resources.
Also look at this beautiful blog written by Mariusz Michalowski
Subscribe to my newsletter
Read articles from Yashraj Singh Sisodiya directly inside your inbox. Subscribe to the newsletter, and don't miss out.
Written by
Yashraj Singh Sisodiya
Yashraj Singh Sisodiya
I am Yashraj Singh Sisodiya, a 3rd Year CSE student at SVVV, born and raised in Shujalpur. Currently residing in Indore, I'm passionate about pursuing a career in DevOps engineering. My tech journey began with an internship at Infobyte, honing my skills as an Android Developer intern. Alongside my academic pursuits, I actively participate in co-curriculars, holding roles as Technical Lead at Abhyudaya and Cloud Lead at GDSC SVVV, while also serving as an MLSA of my college. I have a keen interest in Cloud Computing, demonstrated through projects such as User management and Backup using shell scripting Linux, Dockerizing applications, CI/CD with Jenkins, and deploying a 3-tier application on AWS. Always eager to learn, I'm committed to expanding my knowledge and skills in the ever-evolving tech landscape.