Thursday, August 2, 2018

Azure VM SSD Performance is 2.5x Slower than Expected

... and random write speeds are way below what's expected form SSD.

NOTE: the speeds were measured with all kinds of caching and buffering disabled. See updates below for clarifications.

VM Size: Standard DS11 v2 Promo (2 vcpus, 14 GB memory)
Disk attached to the VM is Premium SSD with 150 MB/s max speed:

Test results:

Summary:

  • Sequential operations' speeds at ~60Mbs are 2.5 times slower than declared limit of 150MB/s
  • Random write speeds are at the level of 5400 rpm HDD, not even close to SSD
  • Interesting fact, if you test against temp drive (D), random writes speed rises to ~20MB/s
  • No difference/increase in performance after upgrading from P10 level drive (100 MB/s limit) to P20 (current 150 MB/s) - https://azure.microsoft.com/en-us/pricing/details/managed-disks/

Update #1

After I upgraded VM size from Standard DS11 v2 Promo to a meatier Standard DS4 v2 Promo (8 vcpus, 28 GB memory) with corresponding VM's MAX IOPS growing from 16000 to 32000 (no changes to SSD disk and it's IOPS) , there's significant growth in read speeds, no significant changes to writes though:

1/5 Sequential write [4MB] block        Avg: 64.7MB/s    Min÷Max: 39.3 ÷ 78.2
2/5 Sequential read [4MB] block         Avg: 265.5MB/s   Min÷Max: 86.5 ÷ 3126.2
3/5 Random write [4KB] block            Avg: 1.2MB/s     Min÷Max: 0.7 ÷ 1.4
4/5 Random read [4KB] block             Avg: 31.1MB/s    Min÷Max: 7.2 ÷ 56.7

Update #2

Enabling write buffering (disabling FileOptions.WriteThrough) skyrockets write speeds. Though  these writes are not as resilient as those not using buffering (program failure may lead to file writes not being committed), besides, it's questionable whether this speeds can be considered device performance (and not cache), and yet most apps use write caches and this results are closer to real-life.

1/5 Sequential write [4MB] block        Avg: 2291.7MB/s  Min÷Max: 1699.2 ÷ 2768.0
2/5 Sequential read [4MB] block         Avg: 82.4MB/s    Min÷Max: 26.6 ÷ 3800.8
3/5 Random write [4KB] block            Avg: 434.7MB/s   Min÷Max: 85.5 ÷ 952.7
4/5 Random read [4KB] block             Avg: 13.2MB/s    Min÷Max: 12.8 ÷ 59.5

Update #3

Below you can find results with memory cache enabled. This speeds are in no way related to performance of storage, that's a combination of RAM and SSD writes. Though it shows the magnitude of read improvements provided by OS's file caching subsystem for files already accessed/read.

1/5 Sequential write [4MB] block        Avg: 2291.6MB/s  Min÷Max: 1436.8 ÷ 2824.3
2/5 Sequential read [4MB] block         Avg: 2419.0MB/s  Min÷Max: 1273.9 ÷ 3161.8
3/5 Random write [4KB] block            Avg: 464.6MB/s   Min÷Max: 96.5 ÷ 952.7
4/5 Random read [4KB] block             Avg: 530.0MB/s   Min÷Max: 108.8 ÷ 1148.9

1 comment: