Test SSD random read / write speeds on AlmaLinux using FIO

To test disk random write speed use the following command:

Which will run a test with the following parameters:

Block Size16KiB
IO Depth / Queue Depth64
Number of Jobs / Threads1
Test TypeRandom Writes
fsync()Enabled

While you may get much higher speeds with fsync() being disabled, it is important to enable it for this test. Enabled fsync() allows to correctly benchmark random write speeds for database operations which is important factor for a web server.

On a server with a problematic drive you’ll see something like this (less than 1000 IOPS):

On a reasonably ok server you’ll see around 10-15k IOPS:

On a ultra-fast high end server you’ll not even see the test running – result is usually more than 100k IOPS:

WordPress Hosting Benchmark comparsion – good vs bad write speeds with fsync()

These tests have been performed with WordPress Hosting Benchmark Tool on two similar systems where one has a consumer grade SSD, while the other one has two enterprise grade SSDs in a raid array. The test results prove that a random write speed with fsync() being on is an important factor in choosing the right NVME SSD for a web hosting.

Test results with a non-suitable consumer grade NVME SSD which gives out poor write speeds (800 – 900 IOPS) with fsync() being on.
Test results with an enterprise grade NVME SSD which gives out super high write speeds (150k IOPS) with fsync() being on.

Useful resources for testing SSDs

IOPS to MB/s Calculator by wintelguy.com – will help you to easily convert between IOPS and MB/s for better understanding of benchmark results. Block size is important in this calculation. In this article I’m using 16KiB of block size for my measurements.

SSD Specs Database by techpowerup.com – large database of datasheets for SSD drives, containing very detailed technical information about each SSD drive, such as performance metrics, controller data, features, etc.

Quick overview of FIO utility parameters by linux.die.net – will help you to gain better understanding what’s happening “under the hood” when running the FIO commands

Test disk performance by using dd command – by cyberciti.biz – alternate way of testing disk performance by using “dd” command (server throughput and latency).

Plesk for Linux server is running slow: too much IO interactivity – More commands from PLESK to test the disk speed by using “dd” and “iotop” utilities

About the author
I'm a full-stack WordPress developer with a 10+ years of solid experience in the core web development languages, development processes / techniques, web security, Linux server management and with pretty good understanding about proper semantics, UX/UI, technical SEO, good design and basic knowledge of company leadership. On top of that - a distant 5+ years experience as a computer and electronics repair technician which often enables me to understand also how the things work at the hardware level.