![]() |
XRootD
|
This XRootD Client Plugin can be used to record all user's actions on XrdCl::File object and store them into a csv file. Afterwards, using the xrdreplay utility the actions can be replayed preserving the original timing. The output file can be provided either using the XRD_RECORDERPATH
environment variable or the output
key in the plug-in configuration file (the enviroment variable takes precedence). If neither is provided the recorded actions will be stored at a default location: /tmp/xrdrecord.csv
.
Config file format:
recorder.conf:
In order to replay either do:
or
The xrdreplay application provides the following operation modes:
To display the IO statistics from a recorded file without playback do:
To further inspect details of the recording file (which files are accessed and IO per file) use the long format (-l) and optionally the summary option (-s):
All tags used in the output format are explained in the tags section.
To verify the availability of all input files one uses:
On success the shell returns 0, if there was a missing, too small or inaccessible file it returns -5 (251).
In creation mode xrdreplay will create the required input files. In this context it is worthwhile to explain the –replace option, which allows to modify the input and output path used by xrdreplay.
You can use the –replace option (multiple times) to rewrite the URLs of input and output data e.g.:
The option works in combination with all modes of xrdreplay e.g. you can create the required input files in a different location than given in the record file.
There are two ways to create input data:
The truncate option might be not good to produce useful results when the storage systems supports sparse files and/or compression.
Her is an example to create input data in create mode in a modified storage endpoint:
xrdreplay without print, verify or creation option will playback a recorded pattern file. By default xrdreplay will replay the IO trying to keep the original timing of each request. This might not be possible if responses are slower than in the original recording. It is possible to modify the playback speed using the -x speedval option. A value of 2 means to try to run the recorded pattern with double speed. A value of 0.5 means to replay the pattern at half speed. Increasing the playback speed can increase memory requirements significantly.
The playback mode creates some additional output lines:
Most of the output fields are self-explaining. Performance Mark puts the original run-time to the achieved run-time into relation. The <Gain Marks>
indicates if the IO could potentially be run faster than given by the recording (when > 100%). The Synchronicity measures the amount of IO requests within a given file are overlapping between request and response. A value of 100% indicates synchronous IO, a value towards 0 indicates asynchronous IO. This value does not measure parallelism between files.
In case of IO errors you will see a response error counter != 0 and a shell return code of -5 (251).
By default xrdreplay will reject to replay a recording file with error responses. By using the -f flag you can force the player to run. In this case unsuccessful IO events will be skipped in the replay.
The print and playback modes support json output of results.
Also the -l and -s options support json output.
Per file (-l) or aggregated statistics (-s):
tag | description |
---|---|
*::texec | playback execution time of * in sec |
*::tnomi | recorded execution time of * in sec |
*::tloss | time running after recording in sec |
*::tgain | time gained vs recording in sec |
*::n | number of IO calls to * |
*::b | sum of bytes for IO calls to * |
*::o | highest file offset accessed |
When * is listed, this can be any allowed operation like open,close,read,write,truncate,stat,sync,pgread,pgwrite,vectoread,vectorwrite.
General output:
tag | description | json tag |
---|---|---|
Total Runtime | runtime of the replayed recording | player::runtime |
Sampled Runtime | original run time of the recording | sampled::runtime |
Playback Speed | timestretch factor for the playback | player::speed |
IO Volume (R) | total data INGRESS (by read func) | volume::totalread,read,pgread,vectoread |
IO Volume (W) | total data EGRESS (by write func) | volume::totalwrite,write,pgwrite,vectorwrite |
IOPS (R) | total read IO ops (by read func) | iops::read,pgread,vectoread |
IOPS (W) | total write IO ops (by write func) | iops::write,pgwrite,vectorwrite |
Files (R) | sum files with reads | files::read |
Files (W) | sum files with writes | files::write |
Datasize (R) | sum of max file offsets in reads | datasetsize::read |
Datasize (W) | sum of max file offsets in writes | datasetsize::write |
IO BW (R) | bandwidth in MB/s from runtime for reading | bandwidth::mb::read |
IO BW (W) | bandwidth in MB/s from runtimg for writing | bandwidth::mb::write |
Performance Mark | 100 * (sampled runtime) / (total runtime) | performancemark |
Gain Mark (R) | 100 * (sampled read times) / (total rtime) | gain::read |
Gain Mark (W) | 100 * (sampled write times) / (total wtime) | gain::write |
Synchronicity (R) | 100=sync 1=async IO for reads | synchronicity::read |
Syncrhonicity (W) | 100=sync 1=async IO for writes | synchronicity::write |
Response Errors | number of IOs which were not successfull | response::error |
It is possible to limit the memory consumption of xrdreplay by setting the XRD_MAXBUFFERSIZE
environment variable, following sufixes are supported: kb, mb, gb (case insensitive).