Using Python to make sense of system traces
summary
Shows how LTTng traces capture both Python user‑space events and Linux kernel syscalls, using a simple HTTP server instrumented with the LTTng UST Python agent. Demonstrates building analyses with Babeltrace 2 Python bindings, assembling a plugin that correlates function entry/return, bytecode events and syscalls on one timeline, and extracting timing/error metrics. Covers live mode, CTF traces, a flight‑recorder snapshot workflow for production capture, and an example of compiling CPython with function instrumentation; the tools work and reveal where time and errors occur.
AI-written summary · about
chapters (19)
- 0:00Introduction
- 0:40Overview
- 1:00Tracers vs Loggers
- 2:10Lowlevel events
- 3:01Binary formats
- 3:21LTT Network
- 4:47unify tracers
- 5:21userspace tracing
- 6:07Python to entry
- 6:42Python simple HTTP request handler
- 10:37Python bindings
- 11:15Python benefits
- 12:08Kernelspace tools
- 12:58Starting a new tool
- 13:30What is babeltrace
- 14:11Using babeltrace in Python
- 14:55Implementing babeltrace
- 20:31Viewing the code
- 23:07Debugging the code
