What you will learn in this TP
- Install Cilium and Hubble
- Observe the flows
- Troubleshoot a drop
All steps and instructions are shown. Recommended for this lab: autonomous
Introduction #
Context. After a NetworkPolicy was deployed, the front end can no longer reach the API and nobody understands why. You make the cluster network observable.
Prerequisites: kind, kubectl, cilium and hubble CLIs · Estimated time: 50 min
See every flow and every drop in the cluster.Hands-on #
Guided steps, with their solutions.
1. Create the cluster without a CNI
Why? Cilium replaces kind's default CNI.
Create a kind cluster withdisableDefaultCNI: trueand install Cilium.2. Enable Hubble
Why? Relay aggregates the flows from every node for the CLI and the UI.
Enable Hubble with the UI and open the tunnel to Relay.3. Deploy an application
Why? Two services talking to each other are enough to produce interesting flows.
Deploy anapiserver and afrontclient that queries it in a loop, then observe the flows.4. Break it with a NetworkPolicy
Why? You reproduce the incident: a policy that only allows
role=frontendpods.Apply the policy, then look for the dropped flows.5. Fix and visualise
Why? The fix can be verified immediately in the flows.
Add the expected label to the pod, check that the flows areFORWARDEDagain, then open the Hubble UI.6. Clean up
Why? Free up resources.
Delete the cluster.
Validate your work
Check that each goal above is reached and that you get the result described in the introduction.
Difficulty level : ●●●●○ (4/5)
My progress
Sign in to track your progress and take notes. Sign in
💬 Questions about this lesson
No questions yet: be the first to ask for help or share your configuration.
Recommended Articles
Observing the Kubernetes network with Cilium Hubble
Make a Kubernetes cluster's network flows visible with Cilium Hubble: architecture, the hubble ob...
Container network security and Kubernetes networking
Secure the container network: how Docker and Kubernetes networking works, CNI, default-deny Netwo...
Kubernetes CNI: Flannel, Calico and Cilium compared
Kubernetes CNI: understand network plugins (Container Network Interface) and compare Flannel, Cal...
Securing Kubernetes: RBAC, NetworkPolicies, container network security and Pod Security
Securing Kubernetes: RBAC (Role, ClusterRole, bindings), ServiceAccounts, NetworkPolicies, Pod Se...
eBPF best practices for observability
Checklist for adopting eBPF in observability: choosing tools, gradual rollout, agent security, co...
eBPF explained: programs in the Linux kernel to observe without instrumenting
What eBPF is, how a program is verified and then run in the kernel, hook points (kprobes, uprobes...
Zero-code instrumentation with Grafana Beyla (OpenTelemetry eBPF Instrumentation)
Get RED metrics and HTTP/gRPC traces from any application without changing it: Grafana Beyla and ...
eBPF in production: security, prerequisites and limits
What to know before deploying eBPF agents: privileges and capabilities, kernel versions, managed ...
Deploying and operating Pyroscope on Kubernetes
Install Pyroscope with Helm, collect cluster profiles with Alloy (annotations and eBPF), size, se...