ext4dist(8)
π ext4dist(8) π (System Manager's Manual)
β¨ NAME β¨
okay so ext4dist is the tool that summarizes ext4 operation latency π It uses Linux eBPF/bcc to do it, and it's giving precise. π₯
π SYNOPSIS π
ext4dist [-h] [-T] [-m] [-p PID] [interval] [count]
π¦ DESCRIPTION π¦
bestie, this tool tracks how long common ext4 file operations take π«Ά That means reads, writes, opens, and syncs. It shows the results as a power-of-2 histogram, which is so clean to look at π It stores that histogram in an in-kernel eBPF map, so it stays efficient. β¨
Since this works by tracing the ext4_file_operations interface functions, it will need updating to match any changes to these functions. not me forgetting to update it π
Since this uses BPF, only the root user can use this tool. π
π§ REQUIREMENTS π§
You'll need CONFIG_BPF and bcc. no cap, these are the must-haves π
πΈ OPTIONS πΈ
-hβ prints the usage message π-Tβ skips the timestamps on the interval output π¦-mβ shows the output in milliseconds instead of microseconds π-p PIDβ only traces this PID. main character energy for one process π
π EXAMPLES π
Trace the ext4 operation time, then print a summary when you hit Ctrl-C π
# ext4dist
Trace PID 181 only π
# ext4dist -p 181
Print 1 second summaries, 10 times β¨
# ext4dist 1 10
1 second summaries, printed in milliseconds π
# ext4dist -m 1
π FIELDS π
msecsβ the range of milliseconds for this bucket β±οΈusecsβ the range of microseconds for this bucket β±οΈcountβ how many operations landed in this time range π₯- distribution β an ASCII picture of the distribution, based on the count column π
π OVERHEAD π
β οΈ ngl this one matters: the tool adds low-overhead instrumentation to these ext4 operations, including reads and writes from the file system cache. Those reads and writes can be super frequent (it depends on the workload, eg, 1M/sec), and at that point the overhead of this tool may become noticeable. Measure and quantify before use. π
π SOURCE π
This is from bcc, bestie π«Ά
https://github.com/iovisor/bcc
Also look in the bcc distribution for a companion _examples.txt file. It has example usage, output, and commentary for this tool, and it's iconic π§
π¦ OS π¦
Linux π§
π«§ STABILITY π«§
Unstable - in development. so expect things to shift π
π AUTHOR π
Brendan Gregg π
β SEE ALSO β
Check out ext4snoop(8) next, it's the perfect bestie for this one π
Okay that's the whole tea! π«Ά This page came from the USER COMMANDS crew and was last updated on 2016-02-12. Love you, mwah! πβ¨
π¦ where this page comes from
- debian bookworm: bpfcc-tools 0.26.0+ds-1 Β· Apache-2.0
- debian trixie: bpfcc-tools 0.31.0+ds-7 Β· Apache-2.0
- ubuntu jammy: bpfcc-tools 0.18.0+ds-2 Β· Apache-2.0
- ubuntu noble: bpfcc-tools 0.29.1+ds-1ubuntu7 Β· Apache-2.0
- ubuntu questing: bpfcc-tools 0.31.0+ds-7ubuntu2 Β· Apache-2.0
- ubuntu resolute: bpfcc-tools 0.35.0+ds-1ubuntu2 Β· Apache-2.0
- ubuntu stonking: bpfcc-tools 0.35.0+ds-1ubuntu4 Β· Apache-2.0
- π girlified by anthropic/claude-haiku-5.5 on : a language model's rewrite of the original, under its terms