xfsdist(8)

πŸ“¦ version 0.36.1, in centos-stream 10, centos-stream 9, fedora 43, fedora 44

✨ xfsdist(8) ✨

System Manager's Manual, but make it cute πŸŽ€

πŸ’– NAME πŸ’–

xfsdist - Summarize XFS operation latency. Uses Linux eBPF/bcc. πŸ¦‹

🧚 SYNOPSIS 🧚

xfsdist [-h] [-T] [-m] [-p PID] [interval] [count]

🌸 DESCRIPTION 🌸

okay so this tool measures how long common XFS file operations take 😭 bestie, we're talking reads, writes, opens, and syncs. It shows the results as a power-of-2 histogram πŸ“Š and it stores that histogram in an in-kernel eBPF map, which keeps things efficient ✨

Heads up: this works by tracing the xfs_file_operations interface functions, so it's going to need updating if those functions ever change πŸ™ˆ

⚠️ Since this uses BPF, only the root user can run this tool. Sorry, not sorry πŸ’…

πŸŽ€ REQUIREMENTS πŸŽ€

You'll need CONFIG_BPF and bcc. No cap, nothing else πŸ’œ

πŸ’… OPTIONS πŸ’…

  • -h β€” Pulls up the usage message πŸ“–
  • -T β€” Skips the timestamps on interval output πŸ•°οΈ
  • -m β€” Shows the output in milliseconds instead of microseconds πŸ“
  • -p PID β€” Only traces this PID, main character energy πŸ‘‘

πŸ¦‹ EXAMPLES πŸ¦‹

Trace XFS operation time, then get a summary when you hit Ctrl-C πŸ’«:

# xfsdist

Trace PID 181 only 🎯:

# xfsdist -p 181

Print 1 second summaries, 10 times πŸ”₯:

# xfsdist 1 10

1 second summaries, printed in milliseconds 🌈:

# xfsdist -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 adds low-overhead instrumentation to these XFS operations, and that includes reads and writes served from the file system cache πŸ₯Ί Those reads and writes can be super frequent depending on the workload (like 1M/sec), and at that point the overhead of this tool can start to show up 😬 Measure and quantify before use so you're not caught off guard 🫢

🌷 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 🐧

πŸ§ͺ STABILITY πŸ§ͺ

Unstable, still in development 🚧

πŸ‘©β€πŸ’» AUTHOR πŸ‘©β€πŸ’»

Brendan Gregg πŸ‘‘

πŸ”— SEE ALSO πŸ”—

  • xfssnoop(8) ✨

Bestie, that's the whole page πŸ’– Source is bcc, the manual lives under USER COMMANDS, and it was dated 2016-02-12, so go be iconic with your XFS latency data πŸ¦‹βœ¨

πŸ“¦ where this page comes from