summaryrefslogtreecommitdiff
path: root/HOWTO
diff options
context:
space:
mode:
authorDennis Zhou <dennis@kernel.org>2018-09-20 14:08:10 -0400
committerJens Axboe <axboe@kernel.dk>2018-09-20 13:07:40 -0600
commit55bfd8c81c25d7953b4d6f9320e46af5cb790b0c (patch)
tree5baf8933d695fe911dd13839b09f9a9f6fd83be0 /HOWTO
parent87a48ada9768d3eec522a9f022aaa669c7582285 (diff)
downloadfio-55bfd8c81c25d7953b4d6f9320e46af5cb790b0c.tar.gz
fio-55bfd8c81c25d7953b4d6f9320e46af5cb790b0c.tar.bz2
blktrace: add option to iterate over a trace multiple times
Scaling a particular trace may result in different runtimes among the merging traces. By knowing the approximate length of each trace as a user, the overall runtime of each can be tuned to line up by letting certain traces loop multiple times. First, the last timestamp of a trace is recorded at the end of the first iteration to denote the length of a trace. This value is then used to offset subsequent iterations of a trace. Next, the "--merge_blktrace_iters" option is introduced to let the user specify the number of times to loop over each specific trace. This is done by passing a comma separated list that index-wise pairs with the passed files in "--read_iolog". Iteration counts are introduced as well as keeping track of the length of each trace. In an example, given two traces, A and B, each 60s long. If we want to see the impact of trace A issuing IOs twice as fast, the --merge_blktrace_scalars="50:100" can be set and then --merge_blktrace_iters="2:1". This runs trace A at 2x the speed twice for approximately the same runtime as a single run of trace B. Signed-off-by: Dennis Zhou <dennis@kernel.org> Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'HOWTO')
-rw-r--r--HOWTO21
1 files changed, 21 insertions, 0 deletions
diff --git a/HOWTO b/HOWTO
index f94264b3..45cf0bdf 100644
--- a/HOWTO
+++ b/HOWTO
@@ -2514,6 +2514,14 @@ I/O replay
:option:`replay_time_scale` which scales the trace during runtime and
does not change the output of the merge unlike this option.
+.. option:: merge_blktrace_iters=float_list
+
+ This is a whole number option that is index paired with the list of files
+ passed to :option:`read_iolog`. When merging is performed, run each trace
+ for the specified number of iterations. For example,
+ ``--merge_blktrace_iters="2:1"`` runs the first trace for two iterations
+ and the second trace for one iteration.
+
.. option:: replay_no_stall=bool
When replaying I/O with :option:`read_iolog` the default behavior is to
@@ -3888,6 +3896,19 @@ being slowed down or sped up. :option:`merge_blktrace_scalars` takes in a colon
separated list of percentage scalars. It is index paired with the files passed
to :option:`read_iolog`.
+With scaling, it may be desirable to match the running time of all traces.
+This can be done with :option:`merge_blktrace_iters`. It is index paired with
+:option:`read_iolog` just like :option:`merge_blktrace_scalars`.
+
+In an example, given two traces, A and B, each 60s long. If we want to see
+the impact of trace A issuing IOs twice as fast and repeat trace A over the
+runtime of trace B, the following can be done::
+
+ $ fio --read_iolog="<trace_a>:"<trace_b>" --merge_blktrace_file"<output_file>" --merge_blktrace_scalars="50:100" --merge_blktrace_iters="2:1"
+
+This runs trace A at 2x the speed twice for approximately the same runtime as
+a single run of trace B.
+
CPU idleness profiling
----------------------