From: Anand Jain <anand.jain@oracle.com>
To: "Darrick J. Wong" <djwong@kernel.org>,
Qu Wenruo <quwenruo.btrfs@gmx.com>
Cc: fstests@vger.kernel.org, linux-btrfs@vger.kernel.org,
david@fromorbit.com
Subject: Re: [PATCH 2/2] fstests: add configuration option for executing post mkfs commands
Date: Mon, 9 Oct 2023 17:53:28 +0530 [thread overview]
Message-ID: <0d0bd43f-22e7-4ff7-8afb-5aeb3c9a37cf@oracle.com> (raw)
In-Reply-To: <20231006060932.GD21283@frogsfrogsfrogs>
>>>>> This patch introduces new configuration file parameters,
>>>>> POST_SCRATCH_MKFS_CMD and POST_SCRATCH_POOL_MKFS_CMD.
>>>>>
>>>>> Usage example:
>>>>>
>>>>> POST_SCRATCH_MKFS_CMD="btrfstune -m"
>>>>> POST_SCRATCH_POOL_MKFS_CMD="btrfstune -m"
>>>>
>>>> Can't we add extra options for mkfs.btrfs to support metadata uuid at
>>>> mkfs time?
>>>>
>>>> We already support quota and all other features, I think it would be
>>>> much easier to implement metadata_uuid inside mkfs.
>>>>
>>>> If this feature is only for metadata_uuid, then I really prefer to do it
>>>> inside mkfs.btrfs.
>>>
>>> Thanks for the comments.
>>>
>>> The use of btrfstune -m is just an example; any other command,
>>> function, or script can be assigned to the variable POST_SCRATCH_xx.
>>
>> The last time I tried something like this, I got strong objection from
>> some guy in the XFS community.
>>
>> Just good luck if you can have a better chance.
>
> As another guy in the XFS community, I also don't understand why this
> can't be accomplished with a _scratch_mkfs_btrfs helper that runs the
> real mkfs tool and then tunes the resulting fs. Is it significant for
> bug finding to be able to run an entire separate fstests config with
> this config? Versus writing a targeted exerciser for the -m case? >
> Is there some reason why the exact command needs to be injected via
> environment variables? Or, why can't mkfs.btrfs do whatever "btrfstune
> -m" does?
>
> I suppose the problem there is that mkfs.btrfs won't itself create a
> filesystem with the metadata_uuid field that doesn't match the other
> uuid?
Thanks for the feedback. mkfs.btrfs might also include an option for
btrfstune -m operations during file system creation. While this may
not be the primary use case for mkfs.btrfs, it can be useful for
running fstests. If these changes are integrated, we can use
MKFS_OPTIONS to run the entire fstests suite, potentially making
this patch unnecessary. Let's see how it unfolds.
I made POST_MKFS_CMD configurable in the config file because we
don't have to patch fstests if we need to test with a different
operation post mkfs.
Thanks, Anand
prev parent reply other threads:[~2023-10-09 12:24 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-28 4:23 [PATCH 0/2] fstests: add config option to run after mkfs Anand Jain
2023-09-28 4:23 ` [PATCH 1/2] fstests: btrfs streamlining mkfs command for post-mkfs operations Anand Jain
2023-09-28 4:23 ` [PATCH 2/2] fstests: add configuration option for executing post mkfs commands Anand Jain
2023-09-28 4:26 ` Qu Wenruo
2023-09-28 5:34 ` Anand Jain
2023-09-28 7:40 ` Qu Wenruo
2023-10-06 5:17 ` Dave Chinner
2023-10-09 12:18 ` Anand Jain
2023-10-06 6:09 ` Darrick J. Wong
2023-10-06 6:46 ` Qu Wenruo
2023-10-06 22:12 ` Dave Chinner
2023-10-07 2:45 ` Qu Wenruo
2023-10-09 12:23 ` Anand Jain [this message]
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=0d0bd43f-22e7-4ff7-8afb-5aeb3c9a37cf@oracle.com \
--to=anand.jain@oracle.com \
--cc=david@fromorbit.com \
--cc=djwong@kernel.org \
--cc=fstests@vger.kernel.org \
--cc=linux-btrfs@vger.kernel.org \
--cc=quwenruo.btrfs@gmx.com \
/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;
as well as URLs for NNTP newsgroup(s).