An I/O workload automation and metric analysis tool used to gauge the performance of a device. It provides a means of
automating commonly run workloads with tools such as fio
and filebench
.
The goal of iobs
is to decrease the amount of manual work involved in running I/O experiments on devices.
Commonly used tools for running workloads, such as fio
and filebench
are well suited for providing a means of
benchmarking a device. However, when utilizing other tools or running multiple workloads with slight variations, the
number of configuration changes and formatting differences between tools makes for an inefficient amount of manual work
required to consolidate the results.
The biggest advantage of iobs
is the reduction in work required to run many experiments with different combinations
of configurations.
The latest version can be obtained from the releases.
The following steps are recommended in retrieving the package:
- Use
wget
to pull the latest tarball onto the machine. - Run
tar xvzf <file-name>.tar.gz
on the tarball to extract it. cd
into the directory.- Run
python setup.py install
to install the package and any dependencies.
Executing the script with the -h
flag shows the different arguments that can be used:
$ iobs -h
usage: iobs [-h] [--version] {execute, validate}
positional arguments:
{execute, validate}
optional arguments:
-h, --help show this help message and exit
--version show program's version number and exit
Executes one or more iobs
configuration files.
$ iobs execute -h
usage: iobs execute [-h] [-o OUTPUT_DIRECTORY] [-l LOG_FILE]
[--log-level {1,2,3}] [-s] [-r RETRY_COUNT] [-c] [-d]
input [input ...]
positional arguments:
input The configuration files to execute.
optional arguments:
-h, --help show this help message and exit
-o OUTPUT_DIRECTORY, --output-directory OUTPUT_DIRECTORY
The output directory for output files. Defaults to the
current working directory.
-l LOG_FILE, --log-file LOG_FILE
The file to log information to.
--log-level {1,2,3} The level of information to which to log: 1 (Debug), 2
(Info), 3 (Error). Defaults to 2.
-s, --silent Silences output to STDOUT.
-r RETRY_COUNT, --retry-count RETRY_COUNT
Number of times to retry a failed workload. Defaults
to 1.
-c, --continue-on-failure
If a input fails, continues executing other inputs;
otherwise exits the program.
-d, --reset-device Resets the device to original settings after
execution of each input.
-x, --cleanup-files Cleans up intermediate files generated by the program.
Validates one or more iobs
configuration files.
$ iobs validate -h
usage: iobs validate [-h] input [input ...]
positional arguments:
input The configuration files to validate.
Configuration files should be in INI format. Each section should be contained
in square brackets [...] with configuration settings below the section. Different section names are reserved for special
purposes; all others are considered a workload section. Depending on the workload_type
given under the global
section, additional settings may be permitted under a given section.
Settings which accept lists of values should be separated by a comma ,
.
Global settings for each of the workloads.
workload_type
(required) - The type of workloads to run:fio
.- ex:
workload_type=fio
- ex:
devices
(required) - The devices to execute on.- ex:
devices=/dev/nvme0n1/,/dev/nvme1n1
- NOTE: Should be valid block devices.
- ex:
schedulers
(required) - The schedulers to use on the device.- ex:
schedulers=none,kyber,bfq,mq-deadline
- NOTE: Should be available for each device specified.
- ex:
repetitions
(optional) - The number of times to repeat the workloads. Defaults to 1.- ex::
repetitions=5
- ex::
enable_blktrace
(optional) - Executes blktrace alongside workload and gathers relevant metrics. Defaults to False.- ex:
enable_blktrace=1
Output settings for what metrics to write in the output .csv
files. The output file will have the same name
as the input configuration file and the extension replaced with .csv
. Note that the last column in the output
file will always be END
.
format
(optional) - The metrics to write. Default and allowed format depend onworkload_type
(see below).append_template
(optional) - Whether to append thetemplate
combinations. Defaults to True.- ex:
append_template=1
- NOTE: This should be set to
False
if a custom format is given which includestemplate
information. Otherwise duplicate columns will be added to the output.
- ex:
append_environment
(optional) - Whether to append theenvironment
combinations. Defaults to True.- ex:
append_environment=1
- NOTE: This should be set to
False
if a custom format is given which includesenvironment
information. Otherwise duplicate columns will be added to the output.
- ex:
append_blktrace
(optional) - Whether to append theblktrace
metrics. Defaults to True.- ex:
append_blktrace=1
- NOTE: This will do nothing if
enable_blktrace
isn't set in theglobal
section. This should be set toFalse
if a custom format is given which includesblktrace
information. Otherwise duplicate columns will be added to the output.
- ex:
ignore_missing
(optional) - Whether to ignore missing metrics. Defaults to False.- ex:
ignore_missing=1
- NOTE: Missing metrics will use "NONE" as their value.
- ex:
The format
accepts a list of metric names which should be retrieved from the workload and written in the output files.
Each metric name can accept the full name or an abbreviated name (if there is one). Also, when using the template
section, the names of the template
settings can be specified as well. For example, if the template setting
rw=randread,randwrite
is specified, then the rw
name can be used in the format
to write the configuration used
in the workload.
The following format
metric names are used by any workload_type
:
workload
(orw
) - The name of the workload.device
(ord
) - The name of the device.scheduler
(ors
) - The name of the scheduler.
The following format
metric names are used if enable_blktrace
is set in the global
section:
xxx-avg
- The average xxx.xxx-min
- The minimum xxx.xxx-max
- The maximum xxx.xxx-n
- The number of IOs used in xxx.
where each xxx
is one of 'd2c', 'g2i', 'i2d', 'q2c', 'q2g', or 'q2q'.
filebench
include_flowops
(optional) - Whether to include flowops metrics. Defaults to False.- ex:
include_lat_percentiles=1
- NOTE: Each of the flowop metrics are added with the format of
flowopname-identifier
where identifier is one of the following:total-ops
,throughput-ops
,throughput-mb
,average-lat
,min-lat
,max-lat
.
- ex:
The following format
metric names are used by the filebench
workload_type
:
runtime
(orrun
) - The total runtime for the job in seconds.total-ops
(orops
) - The total number of operations performance.throughput-ops
(ortop
) - The average throughput in ops/s.read-throughput-ops
(orrto
) - The average read throughput in ops/s.write-throughput-ops
(orwto
) - The average write throughput in ops/s.throughput-mb
(ortmb
) - The average throughput in MB/s.average-lat
(oravl
) - The average latency in ms.flowops
- The flowops metrics.- NOTE: If
include_flowops=1
is not set, this is ignored. The number of columns depends on the number of flowops byfilebench
.
- NOTE: If
The default format
used if none is given is the following:
workload
device
scheduler
runtime
total-ops
throughput-ops
read-throughput-ops
write-throughput-ops
throughput-mb
average-lat
flowops
fio
include_lat_percentiles
(optional) - Whether to include lat percentile metrics. Defaults to False.- ex:
include_lat_percentiles=1
- NOTE: The
fio
workload file should havelat_percentiles=1
set.
- ex:
include_clat_percentiles
(optional) - Whether to include clat percentile metrics. Defaults to False.- ex:
include_clat_percentiles=1
- NOTE: The
fio
workload file should haveclat_percentiles=1
set (it is typically enabled by default).
- ex:
The following format
metric names are used by the fio
workload_type
:
job-runtime
(orrun
) - The total runtime for the job in ms.total-ios-read
(ortir
) - The total number of IOs read.total-ios-write
(ortiw
) - The total number of IOs written.io-kbytes-read
(oribr
) - The total KB read.io-kbytes-write
(oribw
) - The total KB written.bw-read
(orbwr
) - The average read bandwidth (throughput) in KB/s.bw-write
(orbww
) - The average write bandwidth (throughput) in KB/s.iops-read
(oropr
) - The average read IO/s.iops-write
(oripw
) - The average write IO/s.lat-min-read
(orlir
) - The minimum read latency in ns.lat-min-write
(orliw
) - The minimum write latency in ns.lat-max-read
(orlar
) - The maximum read latency in ns.lat-max-write
(orlaw
) - The maximum write latency in ns.lat-mean-read
(orlmr
) - The average read latency in ns.lat-mean-write
(orlmw
) - The average write latency in ns.lat-stddev-read
(orlsr
) - The standard deviation of the read latency in ns.lat-stddev-write
(orlsw
) - The standard deviation of the write latency in ns.slat-min-read
(orsir
) - The minimum read submission latency in ns.slat-min-write
(orsiw
) - The minimum write submission latency in ns.slat-max-read
(orsar
) - The maximum read submission latency in ns.slat-max-write
(orsaw
) - The maximum write submission latency in ns.slat-mean-read
(orsmr
) - The average read submission latency in ns.slat-mean-write
(orsmw
) - The average write submission latency in ns.slat-stddev-read
(orssr
) - The standard deviation of the read submission latency in ns.slat-stddev-write
(orssw
) - The standard deviation of the write submission latency in ns.clat-min-read
(orcir
) - The minimum read completion latency in ns.clat-min-write
(orciw
) - The minimum write completion latency in ns.clat-max-read
(orcar
) - The maximum read completion latency in ns.clat-max-write
(orcaw
) - The maximum write completion latency in ns.clat-mean-read
(orcmr
) - The average read completion latency in ns.clat-mean-write
(orcmw
) - The average write completion latency in ns.clat-stddev-read
(orcsr
) - The standard deviation of the read completion latency in ns.clat-stddev-writ
(orcsw
) - The standard deviation of the write completion latency in ns.clat-percentile-read
(orcpr
) - The read completion latency percentiles in ns.- NOTE: If
include_clat_percentile=1
is not set, this is ignored. The number of columns depends on the number of percentiles reported byfio
.
- NOTE: If
clat-percentile-write
(orcpw
) - The write completion latency percentiles in ns.- NOTE: If
include_clat_percentile=1
is not set, this is ignored. The number of columns depends on the number of percentiles reported byfio
.
- NOTE: If
lat-percentile-read
(orlpr
) - The read latency percentiles in ns.- NOTE: If
include_clat_percentile=1
is not set, this is ignored. The number of columns depends on the number of percentiles reported byfio
.
- NOTE: If
lat-percentile-write
(orlpw
) - The write latency percentiles in ns.- NOTE: If
include_clat_percentile=1
is not set, this is ignored. The number of columns depends on the number of percentiles reported byfio
.
- NOTE: If
The default format
used if none is given is the following:
workload
device
scheduler
job-runtime
total-ios-read
total-ios-write
io-kbytes-read
io-kbytes-write
bw-read
bw-write
iops-read
iops-write
lat-min-read
lat-min-write
lat-max-read
lat-max-write
lat-mean-read
lat-mean-write
lat-stddev-read
lat-stddev-write
slat-min-read
slat-min-write
slat-max-read
slat-max-write
slat-mean-read
slat-mean-write
slat-stddev-read
slat-stddev-write
clat-min-read
clat-min-write
clat-max-read
clat-max-write
clat-mean-read
clat-mean-write
clat-stddev-read
clat-stddev-write
clat-percentile-read
clat-percentile-write
Template settings for interpolating different setting combinations into workload
files.
enabled
(optional) - Whether to enable templating. Defaults to False.- ex:
enabled=1
- ex:
All other settings added under this section are used to interpolate the workload
files. When files are interpolated,
an interpolated copy is made with the name __temp__
appended to them. To provide settings to interpolate within a
workload
file, the following syntax should be used: <%setting-name%>
. By default, the following will always be
interpolated if templating is enabled: <%device%>
the device, <%device_name%>
the name of the device (i.e. no /dev/),
<%scheduler%>
the scheduler.
The following is an example template
section:
[template]
enabled=1
rw=randread,randwrite
iodepth=1,2,4,8,16
In this example, the combination of the settings is (rw=randread, iodepth=1), (rw=randread, iodepth=2), ... The following
will be interpolated in the file <%rw%>
and <%iodepth%>
and replaced with their combination values.
Environment settings for manipulating the environment for workloads.
enabled
(optional) - Whether to enable environment changes. Defaults to False.- ex:
enabled=1
- ex:
nomerges
(optional) - Sets device merging to one of the following: 0 (enabled), 1 (some merging), 2 (disabled).- ex:
nomerges=0,1,2
- NOTE: Setting is added as a workload setting combination.
- ex:
Environment settings can be added to the template format
by either specifying them in a custom format, or by enabling
them with the append_environment
setting under the output
section.
All other sections are considered a distinct workload that will be ran for each device
, scheduler
, and
template setting
combination for a given number of repetitions
. The name of the section is considered the name of
the workload.
file
(required) - The file to execute.- ex:
file=my-job.fio
- ex:
The file will be executed with the appropriate command given the workload_type
. For example, workload_type=fio
would
run fio <file> --output-format=json
. While workload_type=filebench
would run filebench -f <file>
.
Usage examples can be found under the examples folder.
All changes and versioning information can be found in the CHANGELOG.
Copyright (c) 2018 UofL Computer Systems Lab. See LICENSE for details.