Understanding Kubernetes Architecture: Components and Infrastructure

Kubernetes commonly abbreviated as k8s, is an open-source container orchestration tool that makes containerized workload management easier. It provides a robust set of features for automating the deployment, scaling, and management of containers.

Kubernetes architecture consists of multiple components that work together to create a scalable, fault-tolerant, and flexible platform for executing and controlling containerized applications.

In this blog, we will go through the Kubernetes architecture components, such as the Control Plane and node architecture, as well as the various infrastructure components that build a Kubernetes cluster.

What is Kubernetes Architecture?

Kubernetes has a client-server architecture in which the Kubernetes API server acts as the cluster’s central control plane and receives requests from various clients such as kubectl, the Kubernetes dashboard, or third-party tools.

When a client sends a request to the Kubernetes API server, the server authenticates the request and verifies it against the Kubernetes API schema. If the request is valid, the API server modifies the status of the Kubernetes objects in the etcd data store and sends a response to the client.

Kubernetes clients can run on any system that can connect to the Kubernetes API server, such as a developer’s laptop or a remote server. Clients connect with the Kubernetes API server over HTTP or HTTPS, and they may execute a variety of tasks, such as creating or changing Kubernetes objects, querying the cluster’s state, or deploying new applications.

Let’s have a look at the k8s architectural image below.

Kubernetes architecture components:

1. Pods: In Kubernetes, a pod is the smallest deployable unit. It represents a single running process instance in the cluster that may consist of one or more containers.

2. Services:  A Kubernetes service is a logical abstraction that specifies a group of pods and a policy for accessing them. It gives a stable IP address and DNS name for external clients to connect to the pods.

3. Ingress: It is a Kubernetes resource that exposes HTTP and HTTPS routes from outside the cluster to cluster services.

4. ConfigMaps and Secrets: ConfigMaps and Secrets are Kubernetes objects that store configuration data and confidential information, respectively. They may be used to configure containers and applications running in the cluster.

What is Kubernetes Master Node architecture?

The master node is the brain of Kubernetes and is in charge of controlling’s entire cluster. It is made up of various components that work together to produce the Kubernetes API server, which acts as the core hub for all cluster administration activities. The following are the components of the master node:

1. API Server: The API server offers a RESTful interface for managing Kubernetes objects such as pods, services, and deployments. It acts as the central center for all Kubernetes cluster management activities.

2. Scheduler: The Scheduler is in charge of scheduling pods to execute on nodes depending on resource availability and other constraints.

3. Controller Manager: The Controller Manager is in charge of managing various controllers, such as the replication controller, endpoint controller, and service controller. It ensures that the desired state of the cluster corresponds to the actual state.

4. Etcd: etcd is a distributed key-value store that holds the whole state of the Kubernetes cluster. It is used to hold configuration data, cluster state, and metadata.

What is Kubernetes Worker node architecture?

The worker node architecture is in charge of running containers and providing them with the resources they require. It is made up of various components, including:

1. Kubelet: The Kubelet is in charge of managing the status of each node in the cluster. It connects with the Control Plane to obtain the required state of the cluster and ensures that the containers operating on the node match the desired state.

2. kube-proxy: The kube-proxy is in charge of managing network connectivity between pods and services. It routes traffic to the correct pods depending on the service’s IP address and port number.

3. Container Runtime: The container runtime is in charge of running containers. Kubernetes supports several container runtimes, including Docker, and CRI-O.

Infrastructure Components for Kubernetes

In addition to the Control Plane and node architecture, there are various more infrastructure components that make up a Kubernetes cluster, including:

1. Networking: To communicate between containers running on various nodes in the cluster, Kubernetes requires a network overlay. Calico, Flannel, and Weave Net are popular Kubernetes networking options.

2. Storage: Kubernetes supports a variety of storage choices, including local storage, network-attached storage [NAS], and storage area networks [SANs]. It also has various volume kinds, such as emptyDir, hostPath, and persistent volume.

3. Monitoring and logging: Kubernetes includes a number of tools for monitoring and logging, including Prometheus and Grafana. These tools help track the health of the cluster, give insights into resource usage, and aid in troubleshooting difficult

I hope it helped you understand the responsibilities and roles of each component and how they work together to run your application. By having a good grasp of Kubernetes architecture, you can deploy, scale, and manage your applications with confidence.

Thank you for reading, and do follow us for more informative content in the future!

Leave a Reply

Your email address will not be published. Required fields are marked *