[PATCH] README: update to say it needs 2.6.14-rc1 or newer
[blktrace.git] / README
CommitLineData
d0ca268b
JA
1Block IO Tracing
2----------------
3
e7c9f3ff
NS
4Written by Jens Axboe <axboe@suse.de> (initial version and kernel support),
5Alan D. Brunelle (threading and splitup into two seperate programs),
6Nathan Scott <nathans@sgi.com> (bug fixes, process names, multiple devices)
d0ca268b
JA
7
8
c1bd9d09
JA
9Requirements
10------------
11
6d1b9657 12You need to be running a 2.6.14-rc1 kernel or newer, with the blk-trace patch
56c7d54d 13included in this repository. If you forgot where you got it, the url is:
c1bd9d09
JA
14
15rsync://rsync.kernel.org/pub/scm/linux/kernel/git/axboe/blktrace.git
16
6432fd98
JA
17If you don't have git, you can get hourly snapshots from:
18
19http://www.kernel.org/pub/linux/kernel/people/axboe/blktrace/
20
21The snapshots include the full git object database as well.
22
c1bd9d09
JA
23
24Usage
25-----
26
152f6476 27% blktrace -d <dev> [-o <output> -a <trace> [-a <trace>] -k]
d0009925
JA
28 -a <trace> is one of: (use multiple -a options to get more)
29 READ
30 WRITE
31 BARRIER
32 SYNC
33 QUEUE
34 REQUEUE
35 ISSUE
36 COMPLETE
37 FS
38 PC
152f6476 39 -k Kill a currently running trace.
d0ca268b
JA
40 --- run task to generate load to be traced ---
41 <SIGINT to kill>
42 --- Generates:
d0009925 43 <output>_out.[0..ncpus] : Contains binary trace data
d0ca268b 44
32fb90fe 45 % blkparse -i <input> [-o <output> -s -t]
d0ca268b 46 --- Generates:
152f6476
JA
47 <output>.log : Contains formatted trace data, if
48 output logging is added with the -o option. Otherwise, the
49 output is sent to stdout. If the -s option is used, in
50 addition to per-CPU stats, per process stats are shown as well.
32fb90fe
JA
51 The -t option will provide individual io statistics, displaying
52 things like completion time, queueing time, etc.
c1bd9d09
JA
53
54
d0009925
JA
55If you want to do live tracing, you can pipe the data between blktrace
56and blkparse:
57
58% blktrace -d <device> -o - | blkparse -i -
59
60This has a small risk of displaying some traces a little out of sync, since
61it will do batch sorts of input events. Similarly, you can do traces over
62the network with eg netcat:
63
64% blktrace -d /dev/sda -o - | netcat parsehost portno
ebc37a0b 65% netcat -l -p portno tracehost | blkparse -i -
d0009925
JA
66
67Which will send the traces from tracehost to parsehost over the network on
68the defined port number.
69
70
7120050906, Jens Axboe <axboe@suse.de>
c1bd9d09 72