example: add a zoned block device write example with GC by zone resets
authorShin'ichiro Kawasaki <shinichiro.kawasaki@wdc.com>
Thu, 15 Dec 2022 01:56:05 +0000 (10:56 +0900)
committerJens Axboe <axboe@kernel.dk>
Thu, 15 Dec 2022 19:42:12 +0000 (12:42 -0700)
Add an example job file which shows how to simulate garbage collection
of zoned block devices using options zone_reset_threshold and
zone_reset_frequency.

Signed-off-by: Shin'ichiro Kawasaki <shinichiro.kawasaki@wdc.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
examples/zbd-rand-write-zone-reset-gc.fio [new file with mode: 0644]
examples/zbd-rand-write-zone-reset-gc.png [new file with mode: 0644]

diff --git a/examples/zbd-rand-write-zone-reset-gc.fio b/examples/zbd-rand-write-zone-reset-gc.fio
new file mode 100644 (file)
index 0000000..8f77baf
--- /dev/null
@@ -0,0 +1,27 @@
+; Using the psync ioengine, random write to a (zoned) block device. Write
+; target zones are chosen randomly among the first 8 zones starting from device
+; offset corresponding to the 524th zone of the device (524 x 256 MB). Simulate
+; garbage collection operation using zone_reset_threshold and
+; zone_reset_frequency options. The zone resets happen when total written data
+; bytes is beyond 70% of 8 zones, and 8 = 1 / 0.125 blocks are written. This
+; example does not specify max_open_zones. The limit of maximum open zones is
+; obtained from the target block device.
+
+[global]
+name=zbd-rand-write-gc
+group_reporting
+rw=randwrite
+zonemode=zbd
+zonesize=256M
+bs=32M
+direct=1
+time_based
+runtime=40
+
+[dev1]
+filename=/dev/sdb
+size=8z
+offset=524z
+ioengine=psync
+zone_reset_threshold=0.7
+zone_reset_frequency=0.125
diff --git a/examples/zbd-rand-write-zone-reset-gc.png b/examples/zbd-rand-write-zone-reset-gc.png
new file mode 100644 (file)
index 0000000..b10acc8
Binary files /dev/null and b/examples/zbd-rand-write-zone-reset-gc.png differ