Posts

Showing posts from September, 2025

K8S Services

Service is used to expose PODS We have 3 types of services in K8S Cluster IP Node port Load Balancer Cluster IP:  If we want to expose PODs with in the Cluster, then Cluster IP is used POD is short lived object If POD is damanged/deleted/creashed then K8S will replace that with a new POD(self healing) when pod is re-created IP will be changing(It is not recommented to access pods using POD IP) Cluster IP service is used to link all PODS in Single IP Cluser IP is a static IP to access PODS Node port:  If we want to expose PODs outside the Cluster, then Node port service is used Using node port we can access our app with worker node public  When we use worker node IP to access our POD then all requests will go to same worker node (Burden will be increased on the node) To distribute load to miultiple worker nodes we will use Load Balancer service Load Balance:  It is used to expose our PODS outside cluster AWS Load balancer When we access load balancer url, requests wil...

K8S installation in Linux VM(Ubuntu)

Image
 -> Create a linux VM (Ubuntu) EC@ instance for host machine Step 1: -> Install Kubectl using below command  # Download the latest stable release curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl" # Download specific version (example: v1.28.0)  # curl -LO https://dl.k8s.io/release/v1.28.0/bin/linux/amd64/kubectl   -- NA # Make the binary executable sudo install -o root -g root -m 0755 kubectl /usr/local/bin/kubectl # Verify installation kubectl version --client Step 2: Install AWS CLI # Download the AWS CLI installer curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip" # Install unzip if not available sudo apt update && sudo apt install -y unzip  # Ubuntu/Debian # sudo yum install -y unzip    # CentOS/RHEL/Amazon Linux # Extract the installer unzip awscliv2.zip # Run the installer sudo ./aws/install # Clean up rm -rf awscliv2.zip aws/ # Verify i...

Kubernetes architecture

Image
Kubernetes architecture: Kubernetes is mostly used for Orchestration of the container. It is open source. s/w developed by Google -> GO programing language is used to develop K8S -> It is used to manage containers (create/start/stop/delete/scale-up/scale-down) -> It provides framework for managing the complex task of deploying, scaling and operating applications in containers. Advantages: 1) Self healing: If any container gets crashed then it will be replaced with new container. 2) Auto scaling: Based on demand containers count will be increased or decreased. 3) Load balancing: Load will be distrubuted all containers which are up and running. Control node: API Server: Scheduler: It will identify the pending requests in ETCD. with the help of kubelet, It will schedule the task.  Controller manager: It will verify all the task which have been scheduled are working as expected or not etcd: etcd is the distributed configuration store for the entire cluster. It holds the s...