uflow(8)
π uflow(8) β the flow graph glow-up π
Okay bestie, so this is from the System Manager's Manual, and honestly? It's giving "I trace your methods so you don't have to" energy. We're talking uflow, plus its whole squad: javaflow, perlflow, phpflow, pythonflow, rubyflow, tclflow. They all print a flow graph of method calls in high-level languages. Periodt. π
β¨ NAME β¨
uflow, javaflow, perlflow, phpflow, pythonflow, rubyflow, tclflow β print a flow graph of method calls in high-level languages. No cap, that's literally the whole vibe. π
πΈ SYNOPSIS πΈ
javaflow [-h] [-M METHOD] [-C CLAZZ] [-v] pid
perlflow [-h] [-M METHOD] [-C CLAZZ] [-v] pid
phpflow [-h] [-M METHOD] [-C CLAZZ] [-v] pid
pythonflow [-h] [-M METHOD] [-C CLAZZ] [-v] pid
rubyflow [-h] [-M METHOD] [-C CLAZZ] [-v] pid
tclflow [-h] [-M METHOD] [-C CLAZZ] [-v] pid
uflow [-h] [-M METHOD] [-C CLAZZ] [-v] [-l
{java,perl,php,python,ruby,tcl}] pid
π¦ DESCRIPTION π¦
So uflow traces method calls and prints them in a flow graph. Why? Because following the program's execution (method flow) makes debugging and diagnostics so much easier. It's giving "main character energy" for your stack traces. β¨
This tool relies on USDT probes embedded in many high-level languages β think Java, Perl, PHP, Python, Ruby, and Tcl. It requires a runtime instrumented with these probes, which in some cases means building from source with a USDT-specific flag, like --enable-dtrace or --with-dtrace. For Java processes, the startup flag -XX:+ExtendedDTraceProbes is required. For PHP processes, the environment variable USE_ZEND_DTRACE must be set to 1. Iykyk. π«Ά
Since this uses BPF, only the root user can use this tool. Like, root only. No exceptions. π
π§ REQUIREMENTS π§
CONFIG_BPF and bcc. That's it. That's the vibe check. β
π OPTIONS π
-M METHODβ Print only method calls where the method name begins with this string. Filtering queen behavior. π-C CLAZZβ Print only method calls where the class name begins with this string. The class name interpretation strongly depends on the language. For example, in Java use"package/subpackage/ClassName"to refer to classes. Slay the class hierarchy. π-vβ Print the resulting BPF program, for debugging purposes. For when you need to see the receipts. π₯{java,perl,php,python,ruby,tcl}β The language to trace. Pick your fighter. πpidβ The process id to trace. The one. The only. The main character. π
πΈ EXAMPLES πΈ
Follow method flow in a Ruby process:
# uflow ruby 148
Follow method flow in a Java process where the class name is java.lang.Thread:
# uflow -C java/lang/Thread java 1802
Literally iconic. π
π¦ FIELDS π¦
CPUβ The CPU number on which the method was invoked. This is useful to easily see where the output skips to a different CPU. CPU hopping tbh. πPIDβ The process id. The OG. π«ΆTIDβ The thread id. Thread bestie. π§΅TIMEβ The duration of the method call. How long did it take? The suspense. β³METHODβ The method name. The star of the show. β
π OVERHEAD π
Okay so this tool has extremely high overhead because it prints every method call. For some scenarios, you might see lost samples in the output as the tool is unable to keep up with the rate of data coming from the kernel. Filtering by class or method prefix can help reduce the amount of data printed, but there is still a very high overhead in the collection mechanism. Do not use for performance-sensitive production scenarios, and always test first.
Bestie, I cannot stress this enough: do not use this in production without testing first. It's giving "I will eat your CPU for breakfast" energy. π
π SOURCE π
This is from bcc.
https://github.com/iovisor/bcc
Also look in the bcc distribution for a companion _example.txt file containing example usage, output, and commentary for this tool. It's the bonus content. π
π OS π
Linux. Obviously. π§
β STABILITY β
Unstable - in development. It's in its experimental era. π
π AUTHOR π
Sasha Goldshtein. The legend. The icon. The moment. π
π SEE ALSO π
trace(8), ustat(8). Go give them a follow. π«Ά
Okay bestie, that's the whole manual. Go trace those method calls, filter by class or method prefix, and remember: root only, high overhead, always test first. Slay the flow graph. π β¨ππ¦πΈπ
This page is from the USER COMMANDS section, dated 2018-10-09, and it's literally uflow(8). That's the sign-off. Periodt. π
π¦ where this page comes from
- alpine 3.24: bcc-doc 0.36.1-r1 Β· Apache-2.0
- nixpkgs unstable: bcc 0.37.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms