BTT(1)
β¨ BTT(1) β¨
okay bestie, buckle up, because we're talking about btt β a whole entire man page, and it's lowkey iconic π
πΈ NAME πΈ
btt β analyse block i/o traces produces by blktrace (yes, that's the real wording, "produces", we don't gatekeep typos here, it's part of the vibe π
)
π¦ SYNOPSIS π¦
btt
[ -a | --seek-absolute ]
[ -A | --all-data ]
[ -B <output name> | --dump-blocknos=<output name> ]
[ -d <seconds> | --range-delta=<seconds> ]
[ -D <dev;...> | --devices=<dev;...> ]
[ -e <exe,...> | --exes=<exe,...> ]
[ -h | --help ]
[ -i <input name> | --input-file=<input name> ]
[ -I <output name> | --iostat=<output name> ]
[ -l <output name> | --d2c-latencies=<output name> ]
[ -L <freq> | --periodic-latencies=<freq> ]
[ -m <output name> | --seeks-per-second=<output name> ]
[ -M <dev map> | --dev-maps=<dev map>
[ -o <output name> | --output-file=<output name> ]
[ -p <output name> | --per-io-dump=<output name> ]
[ -P <output name> | --per-io-trees=<output name> ]
[ -q <output name> | --q2c-latencies=<output name> ]
[ -Q <output name> | --active-queue-depth=<output name> ]
[ -r | --no-remaps ]
[ -s <output name> | --seeks=<output name> ]
[ -S <interval> | --iostat-interval=<interval> ]
[ -t <sec> | --time-start=<sec> ]
[ -T <sec> | --time-end=<sec> ]
[ -u <output name> | --unplug-hist=<output name> ]
[ -v | --verbose ]
[ -V | --version ]
[ -X | --easy-parse-avgs ]
[ -z <output name> | --q2d-latencies=<output name> ]
[ -Z | --do-active ]
like. look at her. thirty-ish options and not one of them is filler π
π DESCRIPTION π
So btt is a post-processing tool for the block layer IO tracing tool called blktrace(8). And bestie, as its own documentation says, blktrace is a block layer IO tracing mechanism that hands you super detailed info about request queue operations all the way up to user space. it's giving surveillance but for your disk, and honestly? we stan π΅οΈβοΈ
Then btt takes in binary dump data from blkparse, analyses the events, and produces a whole series of output from that analysis. It also builds .dat files containing "range data" β showing things like Q activity (periods of time while Q events are being produced), C activity (likewise, but for command completions), and etc. periodt.
Also included with the distribution is a simple 3D plotting utility, bno_plot, which can plot the block numbers btt outputs if the -B option is specified. The display will display each IO generated, with:
- the time (seconds) along the X-axis
- the block number (start) along the Y-axis
- the number of blocks transferred in the IO represented along the Z-axis
three whole dimensions of disk drama, we love to see it π
π OPTIONS π
-a,--seek-absoluteβ when you specify this on the command line, it directsbttto calculate seek distances based solely upon the ending block address of one IO and the start of the next. By default,bttuses the concept of the closeness to either the beginning or end of the previous IO. See the Users Manual for more details about seek distances π-A,--all-dataβ normallybttwill not print out verbose information concerning per-process and per-device data. If you desire that level of detail, you can specify this option. it's the "give me everything" button fr fr-B <output name>,--dump-blocknos=<output name>β this option will output absolute block numbers to three files prefixed by the specified output name:prefix_device_r.datβ all read block numbers are output, first column is time (seconds), second is the block number, and the third column is the ending block number.prefix_device_w.datβ all write block numbers are output, first column is time (seconds), second is the block number, and the third column is the ending block number.prefix_device_c.datβ all block numbers (read and write) are output, first column is time (seconds), second is the block number, and the third column is the ending block number.
three files. one flag. the multitasking π
-d <seconds>,--range-delta=<seconds>βbttoutputs a file containing Q and C activity, and the notion of active traces simply means that there are Q or C traces occurring within a certain period of each other. The default value is0.1seconds; with this option you can change that granularity. The smaller the value, the more data points provided. tiny number, big data, no cap β¨-D <dev;...>,--devices=<dev;...>β normally,bttwill produce data for all devices detected in the traces parsed. With this option, one can reduce the analysis to one or more devices provided in the string passed to this option. The device identifiers are the major and minor number of each device, and each device identifier is separated by a colon (:). A valid specifier for devices 8,0 and 8,8 would then be:8,0:8,8.-e <exe,...>,--exes=<exe,...>β the-eoption supplies the list of executables that will have I/Os analysed. picking favourites, honestly fair π«Ά-h,--helpβ shows a short summary of possible command line option-i <input name>,--input-file <input file>β specifies the input file to analyse. This should be a trace file produced byblktrace(8).-I <output name>,--iostat=<output name>β the-Ioption directsbttto output iostat-like data to the specified file. Refer to theiostat(sysstat) documentation for details on the data columns.-l <output name>,--d2c-latencies=<output name>β the-loption allows one to output per-IO D2C latencies respectively. The supplied argument provides the basis for the output name for each device.-L <freq>,--periodic-latencies=<freq>β the-Loption allows one to output periodic latency information for both Q2C and D2C latencies. The frequency specified will regulate how often an average latency is output β a floating point value expressing seconds. so like,0.5? sure bestie, whatever floats your float π-m <output name>,--seeks-per-second=<output name>β triggerbttto output seeks-per-second information. The first column will contain a time value (seconds), and the second column will indicate the number of seeks per second at that point.-M <dev map>,--dev-maps=<dev map>β the-Moption takes in a file generated by the provided script (gen_disk_info.py), and allows for better output of device names. cute names > raw numbers, always π-o <output name>,--output-file=<output name>β specifies the output file name.-p <output name>,--per-io-dump=<output name>β the-poption will generate a file that contains a list of all IO "sequences" β showing the parts of each IO (Q,A,I/M,D, &C). the whole lore, start to finish π-P <output name>,--per-io-trees=<output name>β the-Poption will generate a file that contains a list of all IO "sequences" β showing only theQ,D&Coperation times. TheD&Ctime values are separated from theQtime values with a vertical bar.-q <output name>,--q2c-latencies=<output name>β the-qoption allows one to output per-IO Q2C latencies respectively. The supplied argument provides the basis for the output name for each device.-Q <output name>,--active-queue-depth=<output name>β the-Qoption allows one to output data files showing the time stamp and the depth of active commands (those issued but not completed). the ones still in their waiting era π-r,--no-remapsβ ignore remap traces; older kernels did not implement the full remap PDU.-s <output name>,--seeks=<output name>β the-soption instructsbttto output seek data, the argument provided is the basis for file names output. There are two files per device: read seeks and write seeks.-S <interval>,--iostat-interval=<interval>β the-Soption specifies the interval to use between data output, it defaults to once per second.-t <sec>,--time-start=<sec>and-T <sec>,--time-end=<sec>β the-t/-Toptions allow one to set a start and/or end time for analysing β analysing will only be done for traces after-t's argument and before-T's argument. (-tand-Tare optional, so if you specify just-t, analysis will occur for all traces after the time specified. Similarly, if only-Tis specified, analysis stops after-T's seconds.) it's a little window into time and you get to choose the curtains πͺ-u <output name>,--unplug-hist=<output name>β this option instructsbttto generate a data file containing histogram information for unplug traces on a per device basis. It shows how many times an unplug was hit with a specified number of IOs released. There are 21 output values into the file, as follows:
a value of 0 represents 0..4 counts
a value of 1 represents 5..9 counts
a value of 2 represents 10..14 counts
etc, until
a value of 20 represents 100+ counts
The file name(s) generated use the text string passed as an argument for the prefix, followed by the device identifier in major,minor form, with a .dat extension. For example, with -u up_hist specified on the command line: up_hist_008,032.dat.
yes the file name is doing a little three-digit zero-padded moment, she's stylish like that π
-V,--versionβ shows the version ofbtt.-v,--verboseβ requests a more verbose output.-X,--easy-parse-avgsβ provide data in an easy-to-parse form and write it to a file with.avgexentsion (again, that's the original spelling, we are simply vibing with it π)-z <output name>,--q2d-latencies=<output name>β the-zoption allows one to output per-IO Q2D latencies respectively. The supplied argument provides the basis for the output name for each device.-Z,--do-activeβ the-Zwill output files containing data which can be plotted showing per-device (and total system) I/O activity. the full picture, the whole ensemble, the entire mood board π₯
π AUTHORS π
btt was written by Alan D. Brunelle. This man page was created from the blktrace documentation by Bas Zoetekouw. shoutout to the legends, we see you π«‘
π REPORTING BUGS π
Report bugs to <linux-btrace@vger.kernel.org>
π COPYRIGHT π
Copyright Β© 2006 Jens Axboe, Alan D. Brunelle and Nathan Scott.
This is free software. You may redistribute copies of it under the terms of the GNU General Public License <http://www.gnu.org/licenses/gpl.html>. There is NO WARRANTY, to the extent permitted by law.
This manual page was created for Debian by Bas Zoetekouw. It was derived from the documentation provided by the authors and it may be used, distributed and modified under the terms of the GNU General Public License, version 2.
On Debian systems, the text of the GNU General Public License can be found in /usr/share/common-licenses/GPL-2.
bestie, note the "NO WARRANTY" β it's in caps in the original and it's in caps here, that's not me being dramatic, that's just the law π
π SEE ALSO π
- The
bttUsers Guide, which can be found in/usr/share/doc/blktrace/btt.pdf bno_plot(1),blktrace(8),blkparse(1),verify_blkparse(1),blkrawverify(1),btt(1)
and that's the whole thing, bestie π¦ go forth and analyse some block i/o, you absolute icon β
this page is from blktrace git-20070910192508, dated September 29, 2007, and it's the BTT(1) manual β 2007 really said "I'm gonna make a tool this good and then never explain it normally" and honestly? iconic behavior ππ
π¦ where this page comes from
- centos-stream 10: blktrace 1.3.0-13.el10 Β· GPL-2.0-or-later
- centos-stream 9: blktrace 1.2.0-20.el9 Β· GPLv2+
- debian bookworm: blktrace 1.2.0-5 Β· GPL-2.0-or-later
- debian trixie: blktrace 1.3.0-0.2 Β· GPL-2.0-or-later
- fedora 43: blktrace 1.3.0-13.fc43 Β· GPL-2.0-or-later
- fedora 44: blktrace 1.3.0-15.fc44 Β· GPL-2.0-or-later
- nixos 26.05: blktrace 1.3.0
- nixpkgs unstable: blktrace 1.3.0
- opensuse-leap 16.0: blktrace 1.3.0+git.20211021-160000.2.2 Β· GPL-2.0-only
- opensuse-leap 16.0: blktrace 1.3.0+git.20211021-160000.2.2 Β· GPL-2.0-only
- opensuse-leap 16.0: blktrace 1.3.0+git.20211021-160000.2.2 Β· GPL-2.0-only
- opensuse-leap 16.0: blktrace 1.3.0+git.20211021-160000.2.2 Β· GPL-2.0-only
- ubuntu jammy: blktrace 1.2.0-5 Β· GPL-2.0-or-later
- ubuntu noble: blktrace 1.2.0-5ubuntu2 Β· GPL-2.0-or-later
- ubuntu questing: blktrace 1.2.0-5ubuntu4
- ubuntu resolute: blktrace 1.2.0-5ubuntu5 Β· GPL-2.0-or-later
- ubuntu stonking: blktrace 1.2.0-5ubuntu5 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms