Skip to main content

Hardware Benchmarks

Benchmarks help us in testing and quantification of our hardware infrastructure. Consistently performant hardware infrastructure forms the base of a high performance data structure. A cloud deployment or an on-prem high density virtualisation platform shares its compute and storage across multiple hosts. This typically causes hot and cold patches in performance.

This document discusses standard hardware testing and benchmarking tools that can be used to benchmark hardware before a deployment.

Testing Process

When to test, how to ensure consistent performance.

  1. Repeat tests if you find performance related issues while in operations and compare the results with the initial benchmarking.
Benchmarking

This section will cover in detail the tools and the commands used to benchmark hardware.

Testing tool
sudo apt install sysbench
CPU Benchmarking

CPU Benchmarking using a single thread

sysbench --test=cpu --num-threads=1 --cpu-max-prime=20000 run

CPU Benchmarking using multiple (we will use 8) threads

sysbench --test=cpu --num-threads=8 --cpu-max-prime=20000 run

The test metric to be measured are

  • Total run time in seconds
  • Total number of events executed
  • CPU events executed
Memory Benchmarking

Benchmarking memory using a single thread

sysbench --test=memory --num-threads=1 run

Benchmarking memory using multiple (we will use 8) threads

sysbench --test=memory --num-threads=8 run

The test metric to be measured are

  • Operations per second
  • Throughput
File IO Benchmarking

Benchmarking file IO is done in three parts – create a test file for a specific size, conduct your test on the file and finally delete the file to return the used disk space back to operations.
Preparing for benchmarking

sysbench --test=fileio --file-total-size=150G prepare

Conducting the test

sysbench --test=fileio --file-total-size=150G --file-test-mode=rndrw --max-requests=0 run

Cleaning up after the test

sysbench --test=fileio --file-total-size=150G cleanup

The test metric to be measured are

  • Write speed during test prepare
  • Read and write operations per second
  • Read and write throughput
Benchmark samples

We have collected some samples to indicate what the results of these tests look like on available cloud infrastructures.

The samples have been generated from the following test setups

TestMetricDO REF 16vCPUDO REF 32vCPUAWS NetmonAzure Netmon(SSD)Azure Netmon (Standard SSD)DO 4 shared vCPUDO 8 shared vCPUAzure Cloud Internal16(B-series)Azure Cloud Internal 32(F-seriesv2)
CPU Single ThreadTotal time (s)10.0014 ✅10.0016 ✅10.000210.000410.0009s10.002410.001110.0012s10.0011s
 Total events4658 ✅4607 ✅4612323633162580250030624347
 CPU Events / sec465.65 ✅460.56 ✅461.13323.53331.49257.87249.91306.08434.59
CPU Multi ThreadTotal time (s)10.0012 ✅10.0019 ✅10.002910.003210.002210.006110.00410.0029s10.0021s
 Total events35158 ✅36426 ✅25634245932520910498188482451834156
 CPU Events / sec3514.82 ✅3641.14 ✅2562.182457.932519.771048.931883.612450.513414.22
Memory Single ThreadThroughput (MB/s)4969.27 ✅5298.52 ✅5772.99608.494082.952816.152889.84013.925196.55
 Operations / sec5088537.19 ✅5425685.2 ✅591227939839093.854180224.62288452192959155.464110249.095321272.09
Memory Multi ThreadThroughput (MB/s)7217.27 ✅7791.13 ✅7435.388192.928338.355893.938673.998422.647045.25
 Operations / sec7390489.56 ✅7978120.44 ✅761495048389545.668538467.966035383.238882162.088624780.27214336.11
File IO Operations (Random Read Write)Read / sec2745.78 ✅5252.33 ✅1468.034065.71324.99449.06760.13365.45310.50
 Write / sec1830.52 ✅3501.56 ✅978.692710.47216.59299.37506.76243.63207.00
 fsyncs / sec5868.46 ✅11205.08 ✅3138.098684.41702.03970.571627.41788.41664.59
File IO Throughput (Random Read Write)Read MB / sec42.90 ✅82.07✅22.9463.535.08 ❌7.02❌11.88 ❌5.71❌4.85 ❌
 Write MiB / sec28.60✅54.71✅15.2942.353.38 ❌4.68 ❌7.92 ❌3.81 ❌3.23 ❌
Disk Write SpeedWrite MB/sec836.41 ✅847.68 ✅     46.67233.23