Skip to main content
Menu
Kubernetes Basic Concepts Note | Cheatsheets
Kubernetes Basic Concepts Note

Kubernetes Basic Concepts Note

June 25, 2021
devops, kubernetes
devops, concept

Architecture #

arch

Nodes #

In Kubernetes nodes are the physical or virtual machines where workloads runs. Each nodes are managed by control plane and contains the services necessary to run Pods.

Master Node #

The master node’s role is the command and control for all the other worker nodes. There are many containers running on the master node, the primary of which is the kube-apiserver , which is responsible for validating the configure data for the API objects such as pods, services and others.

Master Node Components #

Worker Node #

On the worker nodes, the primary agent is the kubelet. It receives instructions from the kube-apisever and is responsible for executing the instruction such as deploying pods, which are logical groups of one or more containers, or downloading the image for the containers.

kube-apiserver #

The API server is a component of the Kubernetes control plane that exposes the Kubernetes API. The API server is the front end for the Kubernetes control plane.

etcd #

etcd is database of the cluster and contains all the sensitive data (tokens, passwords, etc.)

kube-scheduler #

kube scheduler only responsible for deciding which pods goes on which nodes and it doesn’t actually place the pod in the nodes.

kube-controller-manager #

A controller is a process that continuously monitors the state of various components in the systems and work towards bringing the whole system to the desired functioning states for example node controller responsible for monitoring the state of nodes and taking necessary actions to keep the application running through the kube-api-server. There are many more such controllers that monitor and take action accordingly. These all are package to the single process known as the kubernetes controller manager.

Worker Node Components #

kubelet #

kubelet register the node in kubernetes cluster and when it is receives the instruction to load a container or a pod then its request the container runtime engine which may be docker to pull the required images and run an instance. The kubelet monitors the state of the pod or container images and reports to the kube-api-server on a timely bases.

kube-proxy #

kube-proxy is a process that runs on each nodes in the kubernetes cluster. Their job to look for new services and every time a new service is created it creates the appropriate rules on each nodes to forward traffic to those services to the backend pods. one way it does that using IP table rule.

pod #

Pods are the smallest, most basic deployable objects in Kubernetes. A Pod represents a single instance of a running process in your cluster. Pods contain one or more containers, such as Docker containers. When a Pod runs multiple containers, the containers are managed as a single entity and share the Pod’s resources.