,

Kubernetes – What is it and why its popular?

Posted by

Kubernetes is one of the most widely used and popular technology among the software engineers and operation professionals. Lets learn what is kubernetes and why its popular.

Most of the applications running in on premise data centers are monolithic which means all the components of the applications (ex: web, service, db etc) are tightly coupled and running as single process or multiple processes running in few servers. The problem with these monolithic application is that the long release cycle even for a small enhancement in one of the component. During the release developers package their application code and hand it over to operations team for deployment. Operations team manually deploy the code in the production servers and make sure everything works well after the deployment.

Having made it to the top contenders of the most trending words of the year 2021, Metaverse is here to offer a parallel virtual universe to all of us.

Monolith vs Microservices

Due the above issues the monolithic application are broken down into small or micro services and each service can be deployed independently. This reduces the release cycle and the developers can deliver new features quickly to the users which improves customer experience. But with the larger number of services it becomes difficult for the operations team to configure, manage and run the system smoothly. If there is any issue with the underlying server then the ops teams had to manually migrate the services to new server and configure the clients with the new service address.

Operations needs automation which includes auto scheduling of components in the servers, auto configuration and discovery of services and handling failures without any manual intervention. Kubernetes was invented to solve this problem. Kubernetes enables developers to deploy their application on to the production without any assistance from the operations team. It also helps operations team by automating the scheduling and monitoring of the applications running the server or node.

Kubernetes abstracts the hardware from the developers and expose it as single and unlimited computational resource. It allows the developers and operations to deploy and run the applications without worrying about the nuts and bolts of the hardware infrastructure. Kubernetes takes care of identifying the healthy server and deploy and configure it for other components to discover and connect. Kubernetes is open source and cloud agnostic which can be deployed in any cloud infrastructure and on premise data centers too.

Architecture

Kubernetes Architecture

Kubernetes cluster consists of two types of nodes :

  • Master Node – Hosts Kubernetes control plane which controls and manages the kubernetes system.
  • Worker Nodes – Hosts and runs the actual applications after the deployment.

Control Plane

Master node control plane controls the whole cluster and it consists of multiple components as below :

  1. The Kubernetes API Server – Enables user and the other Control Plane components communicate with.
  2.  The Scheduler – Schedules apps (assigns a worker node to each deployable component of your application)
  3. The Controller Manager – Performs cluster-level functions, such as replicating components, keeping track of worker nodes, handling node failures.
  4. etcd – Distributed data store that persistently stores the cluster configuration.

Worker nodes are used to run containerized applications. The task of running, monitoring, and providing services to applications is done by the following components:

  1. Docker or any container run time which runs containers.
  2. Kubelet – Communicates with API Server and manages containers on its node.
  3. Kube Proxy – Load balances network traffic between application components.

Now I believe you understand the basics of kubernetes, its architecture and various components associated with it. If you would like to learn more there are various resources online but you can start with this link first. https://kubernetes.io/