RousselTMLEARNING

Article · Observability with eBPF: from discovery to expertise

eBPF in production

1. Privileges #

An eBPF agent is a sensitive component.

What to grant #

Loading an eBPF program requires elevated capabilities. Since Linux 5.8, you can avoid privileged: true by granting only the capabilities needed:

securityContext:
  capabilities:
    add: [BPF, PERFMON, SYS_PTRACE, NET_RAW, CHECKPOINT_RESTORE, DAC_READ_SEARCH, SYS_RESOURCE]
  # la liste exacte dépend de l'outil : voir sa documentation
Common mistake: An eBPF agent can read other processes' memory. Treat its image, configuration and updates with the same care as a security component: signed image, pinned version, dedicated namespace.

2. Prerequisites and environments #

Not all kernels are equal.

Checks #

PointRecommendation
Kernel version5.8 minimum, 5.15+ recommended
BTF/sys/kernel/btf/vmlinux present (CO-RE)
Managed KubernetesEKS, GKE, AKS: recent kernels are fine; GKE Autopilot and Fargate restrict privileged DaemonSets
ContainersDocker Desktop on macOS or Windows runs a Linux VM: tools see the VM, not the host

Overhead #

Overhead depends on event frequency: a few percent of CPU for profiling or network flows, more for tracing every system call of a heavily loaded service. Measure on one node before rolling out.

3. TLS and security observability #

Two special use cases.

Encrypted traffic #

A TLS packet is unreadable to a network probe. Tools like Beyla work around this with uprobes on encryption libraries (OpenSSL, Go crypto/tls) to read the data before encryption or after decryption.

Tetragon and Falco #

ToolUsage
Tetragon (Cilium)Observe and block in real time: executions, file access, connections, with TracingPolicy policies
Falco (CNCF)Rule-based intrusion detection: shell in a container, reading /etc/shadow...
Good practice: These tools produce events to send to Loki or Elasticsearch: they complement operational observability with security observability.

📄 eBPF in production: security, prerequisites and limits →

My progress

  • ⏱ Estimated time : ≈ 3 min

Sign in to track your progress and take notes. Sign in

⭐ Rate this lesson

5.0 initial rating from the teaching team

Sign in to rate this lesson →

💬 Questions about this lesson

No questions yet: be the first to ask for help or share your configuration.

Ask a question about this lesson →

Recommended Articles

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 best practices for observability

Checklist for adopting eBPF in observability: choosing tools, gradual rollout, agent security, co...

Observing the Kubernetes network with Cilium Hubble

Make a Kubernetes cluster's network flows visible with Cilium Hubble: architecture, the hubble ob...

Continuous profiling with eBPF: Parca, Pyroscope and the OpenTelemetry profiler

Continuously profile every process on a host with eBPF: principle, Parca and parca-agent, Pyrosco...

Diagnosing with bpftrace and the bcc tools

Everyday eBPF diagnostic tools: bpftrace one-liners (system calls, files, latencies), bcc tools (...

Deploying and operating Pyroscope on Kubernetes

Install Pyroscope with Helm, collect cluster profiles with Alloy (annotations and eBPF), size, se...

Grafana Pyroscope best practices: collection, labels, analysis and costs

Production checklist for continuous profiling with Pyroscope: choosing the collection mode, label...

Beyla and Alloy: zero-code RED metrics and traces with beyla.ebpf

Enable Beyla eBPF instrumentation in Alloy: service discovery, RED metrics to Mimir, traces to Te...

Support us

♥ SUPPORT US

Support RousselTM Learning

Courses, articles, labs and certificates stay free with no intrusive ads. A voluntary contribution, of any amount you choose, pays for hosting, lab environments and new content.

Contribute with PayPal Any amount · card or PayPal accountLearn more
QR code PayPal
Or scan this QR code with your phone

Thank you, every contribution counts!