for configuration examples see reference.toml or the monad-specific example at config.toml.
after collecting traces, view them in perfetto ui.
to start collecting data:
sudo manytrace config.toml # run until ctrl-c
# or
sudo manytrace config.toml -d 10s # collect for 10 secondsthen open the generated trace.perfetto file at https://ui.perfetto.dev/
note: the ui runs a wasm extension locally - nothing is uploaded to servers
measures the average cpu time for each thread within sampling intervals. the frequency parameter controls how often metrics are computed, with a frequency of 10 hz meaning measurements every 100ms. distinguishes between userspace time and kernel time (syscalls). interrupt time is not subtracted from thread time, so measurements may include time spent handling interrupts.
[bpf.cpu_util]
frequency = 10 # sampling frequency in hz
filter_process = ["monad-rpc", "monad-node"]samples call stacks at regular intervals to identify where cpu time is spent.
captures both kernel and userspace stack traces similar to perf record.
the frequency parameter sets how many stack samples to collect per second.
profiled applications must be compiled with frame pointers as bpf doesn't support other stack walking methods yet. without frame pointers, profiles will contain unknown or incorrect samples.
[bpf.profiler]
frequency = 99 # samples per second
kernel_samples = true
user_samples = true
filter_process = ["monad-rpc", "monad-node"]provides detailed visibility into thread scheduling behavior by tracking when threads are running on cpu, when they become blocked and why, and when they are ready to run but waiting to be scheduled. warning: this extension has significant overhead due to the high frequency of scheduling events. only enable it for short durations (up to 5 seconds) when debugging specific performance issues.
each span represents a period of cpu execution and includes kernel function names where the thread was blocked. the cpu label indicates which core the thread was scheduled on, making it easy to track cpu migrations and identify scheduling delays.
[bpf.schedtrace]
filter_process = []collects hardware performance counter statistics like cpu cycles, instructions, cache misses, and branch predictions.
[bpf.perfcounter]
frequency = 100
counters = ["cpu-cycles", "instructions", "cache-misses", "ipc"]
# supported counters: cpu-cycles, instructions, branches, cache-misses,
# page-faults, context-switches, cpu-migrations, ipccaptures rust tracing spans including application-level trace data, structured span events, and log filtering.
log_filter uses rust's EnvFilter syntax, supporting more than simple levels (e.g., "module=debug,other=info"). random_process_id prevents overlapping process ids between different containers.
[[user]]
socket = "/path/to/node.sock"
log_filter = "TRACE"
random_process_id = true # prevents pid conflicts between containers
[[user]]
socket = "/path/to/rpc.sock"
log_filter = "TRACE"
random_process_id = trueLicensed under the GNU General Public License (LICENSE or https://www.gnu.org/licenses/gpl-3.0.html).


