Re: Zoned block device support for fio (was: [PATCH 0/2] null_blk: zone support)

From: Bart Van Assche
Date: Thu Aug 09 2018 - 16:51:55 EST


On Tue, 2018-07-10 at 12:51 -0600, Jens Axboe wrote:
+AD4- On 7/10/18 12:49 PM, Bart Van Assche wrote:
+AD4- +AD4- On Tue, 2018-07-10 at 12:45 -0600, Jens Axboe wrote:
+AD4- +AD4- +AD4- The difference between the job file and the
+AD4- +AD4- +AD4- workload run can be huge. Consider something really basic:
+AD4- +AD4- +AD4-
+AD4- +AD4- +AD4- +AFs-randwrites+AF0-
+AD4- +AD4- +AD4- bs+AD0-4k
+AD4- +AD4- +AD4- rw+AD0-randwrite
+AD4- +AD4- +AD4-
+AD4- +AD4- +AD4- which would be 100+ACU- random 4k writes. If I run this on a zoned device,
+AD4- +AD4- +AD4- then that'd turn into 100+ACU- sequential writes.
+AD4- +AD4-
+AD4- +AD4- That's not correct. The ZBD code in the github pull request serializes writes
+AD4- +AD4- per zone, not globally.
+AD4-
+AD4- That's a totally minor detail. If all my random writes fall within a single
+AD4- zone, then they'd be 100+ACU- sequential. For N open zones, you'd be 100+ACU-
+AD4- sequential within the zone. The point is that the workload as defined and
+AD4- the workload as run are two totally different things, and THAT is the
+AD4- problem.

Hello Jens,

What you proposed in a previous e-mail, namely to use the existing fio zone
concept for zoned block devices sounds interesting to me. This is something I
will definitely look further into. This will help to make a given workload
that is suited for zoned block devices to behave (almost) identical when run
against a regular block device. Since fio users expect that no zones are
reset before e.g. a random write test is started, there will always be a small
difference in behavior between a workload run against a zoned block device and
a workload run against a regular device if some zones already contain data.

It's not clear to me how close you want the behavior of fio to be for zoned
and regular block devices. Do you e.g. want me to introduce a new I/O pattern
(--rw+AD0-...) that causes fio to write sequentially inside a zone and for which
zones are selected randomly? I don't see any other approach that allows to
make sure that the same workload definition behaves identically against zoned
and regular block devices.

Thanks,

Bart.