Get Started with Kubernetes : A Beginners Guide

Kubernetes: It is a open source container orchestration tool.

  1. Centralized Management:
  • Kubernetes helps you control and manage all your container servers (Docker hosts) from a single place.

  • You don't need to log in to each Docker server one by one; everything can be managed from the Kubernetes dashboard or command line.

  • This saves time and makes life easier for system admins.

2. Failover :

  • Kubernetes can create a group of Docker servers (a cluster) and manage them together.

  • If one server fails, Kubernetes can automatically move (migrate) your container apps to another working server in the cluster.

  • This keeps your apps running without interruption.

  • Kubernetes (K8s) provides failover, which means your applications can keep running even if one of your servers stops working.

3. Reliability :

  • Kubernetes makes sure your applications are always running and healthy.

  • If something crashes, Kubernetes can restart it automatically.

4. Scalability :

  • Easily increase or decrease the number of containers running your app based on demand.

  • For example, if you get more users, Kubernetes can launch more containers to handle the load.

  • Vertical Scaling & Horizontal Scaling

5. Rolling Out and Rolling Back :

  • Update your applications safely, one step at a time (rolling updates), without any downtime.

  • If something goes wrong, you can quickly go back (rollback) to the previous working version.

  1. Ramped

  2. Recreate

  3. Canary

  4. Blue-Green

6. Resource Scheduling :

  • Kubernetes automatically decides which server (node) should run each container, making the best use of your hardware.

  • This keeps everything efficient and avoids overloading any single server.

Kubernetes Architecture Explained

Kubernetes architecture works like a team, where every member has a specific job to keep your applications running smoothly. It is mainly divided into two major parts:

1. Control Plane (Master Nodes)

  • Acts as the "brain" of Kubernetes

  • Responsible for making decisions: what to run, where to run it, and how to fix problems.

Main Components of the Control Plane

  • Kube-API Server:
    The main entry point for all commands and requests (from users, tools, or other parts of Kubernetes). It checks, processes, and forwards requests to the right component in the cluster. Think of it as the communication center or front desk of Kubernetes.

  • Kube-ETCD:
    The database or storage locker of Kubernetes. It stores important info about the cluster—what apps are running, their settings, and the current state of everything. This is where Kubernetes remembers everything about your cluster.

  • Kube-Scheduler:
    When a new workload (Pod) needs to run, the scheduler picks the best worker node for it based on available resources. It’s the decider or traffic controller.

  • Kube-Controller:
    Constantly monitors the cluster to ensure everything runs as desired. If something fails, it takes action—like restarting containers or creating new ones. It’s the cluster’s manager and monitor.

Note: There are additional components, but these four are the main ones in the control plane.

2. Worker Nodes (Data Plane / Docker Hosts)

  • These are the "workers" that run your application containers, following the master node’s directions.

Main Components of Worker Nodes

  • Container Runtime (CRI-O / containerd):
    These are the tools that actually run your containers. Kubernetes commands them to start, stop, or manage containers, and they handle it. Think of them as the engines that keep your containers running.

  • Kubelet:
    An agent running on every worker node. Its job is to make sure containers run the way the control plane wants. If a container fails, kubelet helps restart it. It keeps your containers healthy and running.

  • Kubeproxy:
    A network helper for each worker node. It manages network connections so your apps (Pods) can talk within the cluster or with the outside world. It’s like the traffic manager connecting your apps inside Kubernetes.

How It All Works Together

With both these planes (control plane and worker nodes) in place, Kubernetes automatically starts, stops, and manages your applications across many computers, always making sure everything runs smoothly and without interruptions.

For more tutorials and insights, follow me on YouTube: https://www.youtube.com/@DCR-Tech

2
Subscribe to my newsletter

Read articles from CHIRANJEEVI DRONAMRAJU directly inside your inbox. Subscribe to the newsletter, and don't miss out.

Written by

CHIRANJEEVI DRONAMRAJU
CHIRANJEEVI DRONAMRAJU