go-benchmarks icon indicating copy to clipboard operation
go-benchmarks copied to clipboard

R scripts to visualize sysbench storage benchmarks

Open kellabyte opened this issue 6 years ago • 0 comments

I've been measuring cloud instances and I currently don't have a way to easily visualize the results. I have done this over and over and over in my career and I would love to have R scripts to visualize the results like I do in other areas of this repo.

For example like here

The first set of hardware measurements I would love R graphs for is storage benchmarks. sysbench allows us to run benchmarks of varying workloads and you can even get p99 and throughput results periodically every second so that you can see how consistent performance is.

Potential graphs

  1. Read/write throughput over time comparing multiple machine results.
  2. p99 over time comparing multiple machine results.
  3. Latency distribution comparing multiple machine results.

Keep in mind there's multiple thread counts that can be run and compared as well.

Example output

This output is an example of a storage benchmark running on a single machine that reports results every 1 second and outputs total results along with a latency distribution histogram.

sysbench fileio --file-total-size=128G --max-requests=0 --histogram --percentile=99 --report-interval=1 --file-test-mode=seqrewr --time=10 --threads=4 run
sysbench 1.0.11 (using system LuaJIT 2.1.0-beta3)

Running the test with following options:
Number of threads: 4
Report intermediate results every 1 second(s)
Initializing random number generator from current time


Extra file open flags: 0
128 files, 1GiB each
128GiB total file size
Block size 16KiB
Periodic FSYNC enabled, calling fsync() each 100 requests.
Calling fsync() at the end of test, Enabled.
Using synchronous I/O mode
Doing sequential rewrite test
Initializing worker threads...

Threads started!

[ 1s ] reads: 0.00 MiB/s writes: 202.56 MiB/s fsyncs: 16465.08/s latency (ms,99%): 1.417
[ 2s ] reads: 0.00 MiB/s writes: 226.63 MiB/s fsyncs: 18565.27/s latency (ms,99%): 1.319
[ 3s ] reads: 0.00 MiB/s writes: 270.33 MiB/s fsyncs: 22214.34/s latency (ms,99%): 0.920
[ 4s ] reads: 0.00 MiB/s writes: 270.30 MiB/s fsyncs: 22075.98/s latency (ms,99%): 1.082
[ 5s ] reads: 0.00 MiB/s writes: 240.60 MiB/s fsyncs: 19775.80/s latency (ms,99%): 1.227
[ 6s ] reads: 0.00 MiB/s writes: 181.25 MiB/s fsyncs: 14813.76/s latency (ms,99%): 2.223
[ 7s ] reads: 0.00 MiB/s writes: 253.13 MiB/s fsyncs: 20746.12/s latency (ms,99%): 1.044
[ 8s ] reads: 0.00 MiB/s writes: 263.79 MiB/s fsyncs: 21587.83/s latency (ms,99%): 1.007
[ 9s ] reads: 0.00 MiB/s writes: 214.36 MiB/s fsyncs: 17600.73/s latency (ms,99%): 1.227
Latency histogram (values are in milliseconds)
       value  ------------- distribution ------------- count
       0.004 |                                         4
       0.004 |                                         4
       0.004 |                                         21
       0.004 |                                         25
       0.004 |                                         41
       0.004 |                                         51
       0.004 |                                         61
       0.004 |*                                        133
       0.004 |*                                        154
       0.004 |*                                        196
       0.004 |**                                       225
       0.004 |**                                       312
       0.004 |***                                      361
       0.005 |***                                      435
       0.005 |****                                     521
       0.005 |****                                     547
       0.005 |*****                                    678
       0.005 |******                                   765
       0.005 |******                                   820
       0.005 |******                                   838
       0.005 |*******                                  867
       0.005 |******                                   856
       0.005 |*******                                  955
       0.005 |*******                                  925
       0.006 |*******                                  867
       0.006 |******                                   776
       0.006 |*****                                    697
       0.006 |*****                                    686
       0.006 |****                                     559
       0.006 |****                                     541
       0.006 |***                                      453
       0.006 |***                                      450
       0.006 |***                                      365
       0.007 |***                                      375
       0.007 |**                                       307
       0.007 |**                                       320
       0.007 |**                                       256
       0.007 |**                                       257
       0.007 |**                                       274
       0.007 |**                                       220
       0.007 |**                                       206
       0.008 |**                                       198
       0.008 |*                                        175
       0.008 |*                                        191
       0.008 |**                                       198
       0.008 |**                                       208
       0.008 |**                                       243
       0.008 |**                                       300
       0.009 |***                                      410
       0.009 |***                                      450
       0.009 |*****                                    699
       0.009 |*******                                  893
       0.009 |**********                               1262
       0.009 |************                             1526
       0.009 |***************                          1996
       0.010 |******************                       2405
       0.010 |***********************                  2973
       0.010 |*************************                3254
       0.010 |**************************               3466
       0.010 |*************************                3347
       0.011 |*************************                3288
       0.011 |**********************                   2950
       0.011 |**********************                   2937
       0.011 |*******************                      2512
       0.011 |*****************                        2231
       0.012 |*************                            1738
       0.012 |***********                              1446
       0.012 |*********                                1218
       0.012 |*********                                1127
       0.012 |*********                                1249
       0.013 |**********                               1322
       0.013 |************                             1615
       0.013 |*************                            1668
       0.013 |**************                           1849
       0.014 |***************                          1912
       0.014 |**************                           1884
       0.014 |***************                          2034
       0.014 |******************                       2423
       0.015 |**********************                   2888
       0.015 |************************                 3225
       0.015 |******************************           3971
       0.015 |*******************************          4121
       0.016 |*******************************          4037
       0.016 |******************************           3927
       0.016 |****************************             3743
       0.017 |*************************                3352
       0.017 |**********************                   2925
       0.017 |********************                     2595
       0.018 |*****************                        2255
       0.018 |***************                          1945
       0.018 |**************                           1908
       0.018 |*************                            1688
       0.019 |************                             1643
       0.019 |***********                              1511
       0.020 |**********                               1316
       0.020 |**********                               1334
       0.020 |*********                                1242
       0.021 |********                                 1021
       0.021 |*******                                  933
       0.021 |******                                   851
       0.022 |******                                   771
       0.022 |*****                                    716
       0.023 |*****                                    674
       0.023 |*****                                    656
       0.023 |*****                                    708
       0.024 |******                                   848
       0.024 |********                                 1001
       0.025 |*********                                1163
       0.025 |*********                                1189
       0.026 |*********                                1217
       0.026 |*********                                1214
       0.027 |*********                                1181
       0.027 |********                                 1076
       0.027 |*******                                  932
       0.028 |******                                   767
       0.028 |*****                                    721
       0.029 |*****                                    638
       0.030 |****                                     482
       0.030 |***                                      436
       0.031 |***                                      347
       0.031 |***                                      359
       0.032 |***                                      358
       0.032 |***                                      358
       0.033 |***                                      359
       0.033 |**                                       288
       0.034 |**                                       211
       0.035 |*                                        189
       0.035 |*                                        155
       0.036 |*                                        172
       0.037 |*                                        132
       0.037 |*                                        133
       0.038 |*                                        131
       0.039 |*                                        127
       0.039 |*                                        112
       0.040 |*                                        111
       0.041 |*                                        120
       0.042 |*                                        108
       0.042 |*                                        114
       0.043 |*                                        115
       0.044 |*                                        135
       0.045 |*                                        150
       0.045 |*                                        157
       0.046 |*                                        143
       0.047 |*                                        99
       0.048 |*                                        109
       0.049 |*                                        107
       0.050 |*                                        134
       0.051 |*                                        145
       0.052 |*                                        137
       0.053 |*                                        188
       0.053 |**                                       199
       0.054 |**                                       289
       0.055 |****                                     516
       0.056 |*******                                  888
       0.057 |****************                         2092
       0.059 |**********************                   2941
       0.060 |******************************           3963
       0.061 |*************************                3237
       0.062 |************************                 3207
       0.063 |****************************             3713
       0.064 |**************************************   5019
       0.065 |**************************************   4996
       0.066 |*********************************        4342
       0.068 |****************************             3745
       0.069 |****************************             3752
       0.070 |*********************************        4345
       0.071 |**************************************** 5269
       0.073 |**************************************   5056
       0.074 |*******************************          4054
       0.075 |****************************             3631
       0.077 |**************************               3400
       0.078 |*************************                3246
       0.079 |************************                 3114
       0.081 |**********************                   2960
       0.082 |************************                 3134
       0.084 |************************                 3096
       0.085 |************************                 3208
       0.087 |**************************               3472
       0.089 |**************************               3442
       0.090 |***********************                  3072
       0.092 |**********************                   2856
       0.093 |********************                     2572
       0.095 |*****************                        2290
       0.097 |******************                       2394
       0.099 |*****************                        2199
       0.100 |****************                         2168
       0.102 |****************                         2124
       0.104 |***************                          1944
       0.106 |**************                           1827
       0.108 |*************                            1682
       0.110 |************                             1556
       0.112 |***********                              1479
       0.114 |***********                              1461
       0.116 |**********                               1313
       0.118 |**********                               1358
       0.120 |**********                               1258
       0.122 |*********                                1232
       0.125 |**********                               1300
       0.127 |*********                                1240
       0.129 |**********                               1256
       0.132 |**********                               1302
       0.134 |*********                                1245
       0.136 |*********                                1213
       0.139 |********                                 1118
       0.141 |*********                                1140
       0.144 |********                                 1109
       0.147 |********                                 1075
       0.149 |********                                 1036
       0.152 |********                                 1030
       0.155 |********                                 1004
       0.158 |*******                                  932
       0.160 |*******                                  955
       0.163 |******                                   839
       0.166 |*******                                  857
       0.169 |*******                                  885
       0.172 |*******                                  894
       0.176 |*******                                  883
       0.179 |******                                   835
       0.182 |******                                   811
       0.185 |******                                   853
       0.189 |******                                   822
       0.192 |******                                   777
       0.196 |******                                   794
       0.199 |*******                                  868
       0.203 |*******                                  881
       0.206 |*******                                  870
       0.210 |*******                                  929
       0.214 |*******                                  960
       0.218 |********                                 1034
       0.222 |********                                 1057
       0.226 |********                                 1085
       0.230 |********                                 1014
       0.234 |********                                 1016
       0.238 |*******                                  982
       0.243 |********                                 1026
       0.247 |********                                 1074
       0.252 |********                                 1078
       0.256 |********                                 988
       0.261 |*******                                  944
       0.266 |*******                                  936
       0.270 |******                                   847
       0.275 |******                                   761
       0.280 |*****                                    704
       0.285 |*****                                    657
       0.291 |*****                                    672
       0.296 |****                                     592
       0.301 |****                                     551
       0.307 |****                                     567
       0.312 |****                                     533
       0.318 |****                                     500
       0.324 |****                                     490
       0.330 |***                                      448
       0.336 |***                                      376
       0.342 |***                                      435
       0.348 |***                                      424
       0.354 |***                                      366
       0.361 |***                                      432
       0.367 |***                                      405
       0.374 |***                                      378
       0.381 |***                                      355
       0.388 |***                                      380
       0.395 |***                                      340
       0.402 |***                                      336
       0.409 |**                                       315
       0.417 |**                                       317
       0.424 |**                                       317
       0.432 |**                                       277
       0.440 |**                                       289
       0.448 |**                                       299
       0.456 |**                                       240
       0.464 |**                                       242
       0.473 |**                                       248
       0.481 |**                                       210
       0.490 |**                                       242
       0.499 |*                                        186
       0.508 |**                                       204
       0.517 |**                                       204
       0.527 |*                                        163
       0.536 |*                                        169
       0.546 |*                                        194
       0.556 |*                                        182
       0.566 |*                                        155
       0.576 |*                                        165
       0.587 |*                                        170
       0.597 |*                                        167
       0.608 |*                                        152
       0.619 |*                                        156
       0.630 |*                                        154
       0.642 |*                                        148
       0.654 |*                                        151
       0.665 |*                                        164
       0.677 |*                                        156
       0.690 |*                                        193
       0.702 |*                                        147
       0.715 |*                                        148
       0.728 |*                                        144
       0.741 |*                                        146
       0.755 |*                                        146
       0.768 |*                                        157
       0.782 |*                                        155
       0.797 |*                                        149
       0.811 |*                                        157
       0.826 |*                                        155
       0.841 |*                                        161
       0.856 |*                                        126
       0.872 |*                                        120
       0.888 |*                                        115
       0.904 |*                                        108
       0.920 |*                                        114
       0.937 |*                                        114
       0.954 |*                                        123
       0.971 |*                                        124
       0.989 |*                                        115
       1.007 |*                                        117
       1.025 |*                                        101
       1.044 |*                                        112
       1.063 |*                                        96
       1.082 |                                         58
       1.102 |                                         63
       1.122 |*                                        80
       1.142 |                                         64
       1.163 |                                         62
       1.184 |                                         61
       1.205 |                                         46
       1.227 |                                         60
       1.250 |                                         62
       1.272 |                                         51
       1.295 |                                         44
       1.319 |                                         44
       1.343 |                                         58
       1.367 |                                         50
       1.392 |                                         41
       1.417 |                                         44
       1.443 |                                         29
       1.469 |                                         39
       1.496 |                                         43
       1.523 |                                         54
       1.551 |                                         45
       1.579 |                                         65
       1.608 |                                         54
       1.637 |                                         55
       1.667 |*                                        81
       1.697 |                                         56
       1.728 |                                         55
       1.759 |*                                        72
       1.791 |*                                        70
       1.824 |*                                        66
       1.857 |*                                        69
       1.891 |*                                        81
       1.925 |                                         64
       1.960 |                                         53
       1.996 |                                         60
       2.032 |                                         63
       2.069 |                                         42
       2.106 |                                         49
       2.145 |                                         41
       2.184 |                                         38
       2.223 |                                         39
       2.264 |                                         39
       2.305 |                                         63
       2.347 |                                         43
       2.389 |                                         39
       2.433 |                                         62
       2.477 |                                         61
       2.522 |                                         65
       2.568 |                                         60
       2.615 |                                         60
       2.662 |                                         57
       2.710 |*                                        72
       2.760 |*                                        75
       2.810 |                                         56
       2.861 |                                         56
       2.913 |                                         54
       2.966 |                                         42
       3.020 |                                         40
       3.075 |                                         38
       3.130 |                                         29
       3.187 |                                         37
       3.245 |                                         25
       3.304 |                                         25
       3.364 |                                         23
       3.425 |                                         33
       3.488 |                                         21
       3.551 |                                         24
       3.615 |                                         21
       3.681 |                                         26
       3.748 |                                         23
       3.816 |                                         17
       3.885 |                                         18
       3.956 |                                         28
       4.028 |                                         11
       4.101 |                                         17
       4.176 |                                         13
       4.252 |                                         12
       4.329 |                                         13
       4.407 |                                         16
       4.487 |                                         14
       4.569 |                                         14
       4.652 |                                         13
       4.737 |                                         7
       4.823 |                                         8
       4.910 |                                         9
       4.999 |                                         10
       5.090 |                                         8
       5.183 |                                         8
       5.277 |                                         4
       5.373 |                                         5
       5.470 |                                         4
       5.570 |                                         7
       5.671 |                                         4
       5.774 |                                         12
       5.879 |                                         2
       5.986 |                                         6
       6.095 |                                         5
       6.205 |                                         7
       6.318 |                                         5
       6.433 |                                         12
       6.550 |                                         4
       6.669 |                                         7
       6.790 |                                         9
       6.913 |                                         3
       7.039 |                                         5
       7.167 |                                         5
       7.297 |                                         9
       7.430 |                                         6
       7.565 |                                         3
       7.702 |                                         6
       7.985 |                                         4
       8.130 |                                         2
       8.277 |                                         4
       8.428 |                                         2
       8.581 |                                         1
       8.737 |                                         2
       8.895 |                                         2
       9.057 |                                         3
       9.222 |                                         1
       9.389 |                                         4
       9.560 |                                         2
       9.910 |                                         3
      10.090 |                                         1
      10.274 |                                         1
      10.460 |                                         1
      10.651 |                                         1
      10.844 |                                         3
      11.242 |                                         4
      11.446 |                                         2
      11.866 |                                         2
      12.081 |                                         2
      12.524 |                                         2
      12.752 |                                         1
      12.984 |                                         5
      13.219 |                                         2
      13.704 |                                         2
      14.207 |                                         1
      16.408 |                                         1


File operations:
    reads/s:                      0.00
    writes/s:                     15273.00
    fsyncs/s:                     19538.85

Throughput:
    read, MiB/s:                  0.00
    written, MiB/s:               238.64

General statistics:
    total time:                          10.0030s
    total number of events:              348278

Latency (ms):
         min:                                  0.00
         avg:                                  0.11
         max:                                 16.29
         99th percentile:                      1.23
         sum:                              39811.91

Threads fairness:
    events (avg/stddev):           87069.5000/3018.50
    execution time (avg/stddev):   9.9530/0.00

kellabyte avatar Apr 14 '19 20:04 kellabyte