Behind the Scenes of OpenTelemetry eBPF Instrumentation
This is the companion book to my Go Conference 2026 talk “Behind the Scenes of OpenTelemetry eBPF Instrumentation”. Zero-code instrumentation with eBPF is often described as working “regardless of language”, but function-level instrumentation of Go binaries faces four hurdles that no other language has. This book builds up from the basics of how CPUs and memory work to explain why it is hard, with runnable code for every step and a guided tour of the actual OBI implementation.
- Introduction
- How Computers Run Programs
- The OS and the Kernel
- From Source Code to Executable
- How Function Calls Work
- What the Go Runtime Manages
- What Is eBPF?
- What Is OBI?
- Hurdle 1: uretprobe Doesn't Work
- Hurdle 2: The Register-Based Calling Convention
- Hurdle 3: Version-Dependent Field Offsets
- Hurdle 4: Context Propagation Across Processes
- What Go Developers Should Know About Being Observed
- Upstream Go and Closing Thoughts
- Appendix: Glossary and References