zfsdist(8)
π¦ zfsdist(8) π¦
System Manager's Manual π
β¨ NAME β¨
zfsdist β summarize ZFS operation latency π It uses Linux eBPF/bcc, so it's a Linux thing π§
π SYNOPSIS π
zfsdist [-h] [-T] [-m] [-p PID] [interval] [count]
π DESCRIPTION π
okay so zfsdist is literally the tool that tells you how long your ZFS file ops take π It tracks the time (latency) spent in the common ones: reads, writes, opens, and syncs. Then it shows you the whole thing as a power-of-2 histogram π It keeps that histogram in an in-kernel eBPF map, which is how it stays efficient β¨
It works by kernel dynamic tracing of the ZPL interface (ZFS POSIX Layer) π Heads up though: if that interface changes, the tool needs updates to match π
This is meant for the ZFS on Linux project, which lives at http://zfsonlinux.org πΈ
Since this uses BPF, only the root user can use this tool. No root, no zfsdist, no cap π
π§ REQUIREMENTS π§
You need CONFIG_BPF and bcc. Those are the must-haves π«Ά
π OPTIONS π
-hβ the bestie move: prints the usage message π-Tβ skips the timestamps on the interval output ππ«-mβ shows everything in milliseconds instead of microseconds π-p PIDβ only traces the one PID you name, so you can main-character a single process π
π¦ EXAMPLES π¦
Trace ZFS operation time, and print a summary when you hit Ctrl-C β
# zfsdist
Trace PID 181 only π―
# zfsdist -p 181
Print 1 second summaries, 10 times π
# zfsdist 1 10
1 second summaries, printed in milliseconds β±οΈ
# zfsdist -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 that time range π’distributionβ the ASCII picture of the distribution, drawn from the count column π
π OVERHEAD π
Real talk: this adds low-overhead instrumentation to these ZFS operations, and that includes reads and writes from the file system cache. Those can be super frequent (it totally depends on the workload, like 1M/sec π³), and at that point the tool's overhead can start to show. So measure and quantify before you use it, bestie π§
πΈ SOURCE πΈ
This comes from bcc π
https://github.com/iovisor/bcc
Also check out the bcc distribution for a companion _examples.txt file, which has example usage, output, and commentary for this tool π
π§ OS π§
Linux, obviously π
π§ͺ STABILITY π§ͺ
Unstable, still in development. Use with a little caution π
π AUTHOR π
Brendan Gregg π
π SEE ALSO π
zfssnoop(8)π¦
ok that's the whole tea π«Ά Manual page: zfsdist(8) from the USER COMMANDS section, dated 2016-02-12 π Stay iconic, bestie πβ¨
π¦ where this page comes from
- alpine 3.24: bcc-doc 0.36.1-r1 Β· Apache-2.0
- nixpkgs unstable: bcc 0.37.0
- opensuse-leap 16.0: bcc-tools 0.35.0-160000.2.2 Β· Apache-2.0
- opensuse-leap 16.0: bcc-tools 0.35.0-160000.2.2 Β· Apache-2.0
- opensuse-leap 16.0: bcc-tools 0.35.0-160000.2.2 Β· Apache-2.0
- opensuse-leap 16.0: bcc-tools 0.35.0-160000.2.2 Β· Apache-2.0
- π girlified by anthropic/claude-haiku-5.5 on : a language model's rewrite of the original, under its terms