azurehpc icon indicating copy to clipboard operation
azurehpc copied to clipboard

Potential issue with parsing fio output in parser_fio.sh

Open vermagit opened this issue 5 years ago • 4 comments

Not sure if the format of the output produced by fio has changed, but parser_fio.sh does not seem to be picking up the right fields for the jq parsing.

To Reproduce Steps to reproduce the behavior:

  1. sudo yum install fio (fio-3.19, HC, CentOS-HPC 8.1)
  2. See sample output file produced by a variation of fio.pbs. Line of interest is as follows: READ: bw=611MiB/s (641MB/s), 611MiB/s-611MiB/s (641MB/s-641MB/s), io=512MiB (537MB), run=838-838msec
  3. Parser fails when run as-is. Remove the '|tonumber' from the parser to see that the fields being picked up appear incorrectly

vermagit avatar Dec 16 '20 01:12 vermagit

@vermagit is this specific to CentOS 8.1 ?

xpillons avatar Dec 16 '20 08:12 xpillons

This should not be specific to 8.1, but I'd guess specific to the fio-3.19 version maybe. I can share sample output files being written since that is the source of the discrepancy as the parser seems to be expecting a different format.

vermagit avatar Dec 16 '20 16:12 vermagit

I think if may be easier to use the fio --output-format=json to specify you want fio output in json format directly and then parse that file. e.g to extract fio File size, Block size, numjobs and read BW

jq '.jobs[]."job options".size,.jobs[]."job options".bs,.jobs[]."job options".numjobs,.jobs[].read.bw' fio_output.json "2G" "4M" "4" 2616533

garvct avatar Dec 16 '20 23:12 garvct

good suggestion @garvct , @vermagit please feel free to contribute via a PR

xpillons avatar Dec 17 '20 08:12 xpillons