From: Alexey Dobriyan <adobriyan@gmail.com>
To: Dmitry Fomichev <Dmitry.Fomichev@wdc.com>
Cc: "fio@vger.kernel.org" <fio@vger.kernel.org>
Subject: Re: [PATCH] zbd: remove reset_zone flag from fio_zone_info
Date: Wed, 2 Sep 2020 15:49:08 +0300 [thread overview]
Message-ID: <20200902124908.GA884094@localhost.localdomain> (raw)
In-Reply-To: <MN2PR04MB5951A6A974917E280DF3E262E1550@MN2PR04MB5951.namprd04.prod.outlook.com>
On Thu, Aug 27, 2020 at 07:18:07PM +0000, Dmitry Fomichev wrote:
>
>
> > -----Original Message-----
> > From: Alexey Dobriyan <adobriyan@gmail.com>
> > Sent: Friday, August 21, 2020 1:07 PM
> > To: Dmitry Fomichev <Dmitry.Fomichev@wdc.com>
> > Cc: fio@vger.kernel.org
> > Subject: Re: [PATCH] zbd: remove reset_zone flag from fio_zone_info
> >
> > On Wed, Aug 19, 2020 at 07:35:03PM +0000, Dmitry Fomichev wrote:
> > >
> > >
> > > > -----Original Message-----
> > > > From: Alexey Dobriyan <adobriyan@gmail.com>
> > > > Sent: Wednesday, August 19, 2020 8:56 AM
> > > > To: Dmitry Fomichev <Dmitry.Fomichev@wdc.com>
> > > > Cc: fio@vger.kernel.org
> > > > Subject: Re: [PATCH] zbd: remove reset_zone flag from fio_zone_info
> > > >
> > > > > The reset_zone flag that is defined in fio_zone_info structure is
> > > > > only referenced in zbd_adjust_block() function. Convert this flag
> > > > > to a local variable and save some room in zbd_info array which can
> > > > > be pretty large when running fio against high capacity zoned devices.
> > > >
> > > > This flag should be kept.
> > > >
> > > > Test can crash or be interrupted leaving hw in indeterminate state,
> > > > it must be restarted from clean state. Or test can be precondition and
> > > > zone should not be reset.
> > >
> > > This is beyond the scope of fio. Any preconditioning of zones is done
> > > by external scripts that have no access to this flag. Tools like blkzone,
> > > libzbc or nvme-cli are typically used to precondition zones before
> > > testing and to analyze zone state after test runs.
> >
> > If it is a matter of policy that fio doesn't do preconditioning,
> > then the patch is OK.
> >
> > We do preconditioning in fio, it is neat:
> > * don't need external programs
> > * everything inside one job file
> > * not a lot of code to add
> >
> > But to do this, flag must live in "struct fio_zone_info".
> >
> > [zra]
> > zone_reset_all=1
>
> The way I understand this, this option makes ZBD code to set the reset_zone
> flag for all zones during init. This will force zone reset before the first write
> to a zone. This indeed is a neat idea and this feature looks to be pretty
> lightweight as you said.
>
> > zone_finish_all=1
>
> How does this option work? Seems like you have added a new
> finish_zone flag and you finish every zone for which the flag is set
> instead of performing the first write to the zone...
Sorry for delay.
ZRA marks every zone in [->min_zone, ->max_zone) for reset,
forcing Zone Reset before first write.
ZFA sends Finish Zone with "all" flag set synchronously.
Some job orchestration is required but once it is done, jobs run reliably.
> > rw=write
> >
> > [pre]
> > stonewall
> > zone_reset_all=0
> > zone_finish_all=0
> > job_max_open_zones=...
> > rw=write
> > ...
> >
> > [j]
> > stonewall
> > zone_reset_all=0
> > zone_finish_all=0
> > rw=randread
> > ...
>
> I guess we can hold off with removing the reset_zone flag if you are planning
> to send the patch for this.
Thanks, I'll try to extract something mainlineable.
next prev parent reply other threads:[~2020-09-02 12:49 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-08-19 12:56 [PATCH] zbd: remove reset_zone flag from fio_zone_info Alexey Dobriyan
2020-08-19 19:35 ` Dmitry Fomichev
2020-08-21 17:07 ` Alexey Dobriyan
2020-08-27 19:18 ` Dmitry Fomichev
2020-09-02 12:49 ` Alexey Dobriyan [this message]
-- strict thread matches above, loose matches on Subject: below --
2020-08-18 0:02 Dmitry Fomichev
2020-08-19 4:59 ` Damien Le Moal
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200902124908.GA884094@localhost.localdomain \
--to=adobriyan@gmail.com \
--cc=Dmitry.Fomichev@wdc.com \
--cc=fio@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox