공유

최종 업데이트 September 11, 2023

기사

How Do I Measure Solid State Drive IOPS (Input/Output Operations Per Second)?

Provides Basic Instructions For Measurements By Using FIO Tool

Summary
This article provides steps on how to get the Input/Output Operations Per Second (IOPS) consistency SSD with FIO Visualizer tool
1. Prepare the drive with SSD Preconditioning
Before running the benchmark, you need to prepare the drive. This usually calls “SSD Preconditioning”, i.e. achieving sustained performance state on "fresh" drive. Here are basic steps to follow to get reliable results at the end. Secure erase SSD:

Fill SSD with sequential data twice of its capacity. This will guarantee all available memory is filled with a data including factory provisioned area. DD (Data duplicator) is the easiest way to do so:
dd if=/dev/zero bs=1024k of=/dev/"devicename"
2. Decide on workloads: If you're running sequential workload to estimate the read or write throughput then skip the next step.
Fill the drive with 4k random data. The same rule, total amount of data is twice drive's capacity.
Use FIO for this purpose. Here is an example script for NVMe SSD:

[global]

name=4k random write 4 ios in the queue in 32 queues
filename=/dev/nvme0n1
ioengine=libaio
direct=1
bs=4k
rw=randwrite
iodepth=4
numjobs=32
size=100%
loops=2
[job1]

You are now ready to run your workload. Usually, measurements start after 5 minutes of runtime in order to let the SSD FW adapting to the workload. It will enter the drive into sustained performance state.

3. Run the script below. It can be modified based on the desired result. ie., randrw to randread.

name= 4corners.csv
filename=/dev/nvme0n1
ioengine=libaio
direct=1
bs=4k
rw=randrw
#rw=randread
iodepth=32
numjobs=4
buffered=0
size=100%
runtime=400
rwmixread=70
rwmixwrite=30
time_based
randrepeat=0
norandommap
refill_buffers
log_avg_msec=1000
log_max_value=1
group_reporting
percentile_list=1:25:50:75:90:99.0:99.9:99.99:99.999:99.9999:99.99999:99.999999:100.0
stonewall

For more information how to test the drive using FIO, visit How to benchmark SSDs with FIO Visualizer

How Do I Measure Solid State Drive IOPS (Input/Output Operations Per Second)?