World map

 

BM: Baca dalam Bahasa Melayu

World K3: Counters & Doors

Every pod gets an IP

You will learn: how pods reach each other, and why their addresses change.

Checked with Kubernetes 1.37 on 31 Oct 2026

The problem

You are here: cluster kind-dev namespace default
Four trays on two stalls. The IP column gives each tray its own number: three shop trays and one client tray. Terminal output: $ kubectl get pods -o wide NAME READY STATUS RESTARTS AGE IP NODE NOMINATED NODE READINESS GATES client 1/1 Running 0 22s 10.244.2.3 dev-worker2 <none> <none> shop-94c9756fd-8tghh 1/1 Running 0 22s 10.244.1.3 dev-worker <none> <none> shop-94c9756fd-hjttw 1/1 Running 0 22s 10.244.2.4 dev-worker2 <none> <none> shop-94c9756fd-pklq2 1/1 Running 0 22s 10.244.1.4 dev-worker <none> <none>

The client tray is hungry. Three shop trays can cook. How does the client reach one of them?

Watch

Tap each point on the timeline.

Every pod gets its own pod IP: A tray's own table number: every pod gets an IP. A replaced pod gets a new one.. Think of a table number for each tray. Tap each step.

Watch

You are here: cluster kind-dev namespace default
From inside the client pod, wget asks 10.244.1.4 for a page. A shop tray on another stall answers: Kedai Kancil. Terminal output: $ kubectl exec client -- wget -qO- -T 5 http://10.244.1.4 <h1>Kedai Kancil</h1>

kubectl exec client -- wget … runs wget inside the client tray. It calls one shop tray straight by its IP. The page comes back.

Try it

Delete one shop tray. Then look at the IP column again.

You are here: cluster kind-dev namespace default
Stalls: 3. Trays: 4 (4 ready). Waiting for a stall: 0.
dev-control-planeOpenManager

No trays here.

dev-workerOpen
  • shop·8tghh
  • shop·pklq2
dev-worker2Open
  • client
  • shop·hjttw
Time: +0s (sped up)

Predict

The new tray got a new IP. The client saved the old one. What happens to its next order?

Pick one answer.

Check

Pod IPs change. Judge each habit.

Swipe right for good, left for needs work. Or use the buttons.

1 / 4

Expect a new IP when a pod is replaced.

Expect a new IP when a pod is replaced.

You did it!

You can now explain pod IPs, and why they change.

Go deeper (optional)

Each stall hands out IPs from its own range, like 10.244.1.0/24 on dev-worker. A network plugin (CNI) does this work. You meet it in lesson 11.

Real rep (optional), on a throwaway kind cluster:

Real mission

  1. kubectl config current-context
  2. kubectl create deployment shop --image=nginx:1.29-alpine --replicas=3
  3. kubectl get pods -o wide

0 of 4 steps done · Your ticks are saved.