From: "Theodore Y. Ts'o" <tytso@mit.edu>
To: "Darrick J. Wong" <darrick.wong@oracle.com>
Cc: harshad shirwadkar <harshadshirwadkar@gmail.com>,
Andreas Dilger <adilger@dilger.ca>,
Ext4 Developers List <linux-ext4@vger.kernel.org>
Subject: Re: [PATCH 01/11] ext4: add handling for extended mount options
Date: Wed, 24 Jul 2019 12:07:49 -0400 [thread overview]
Message-ID: <20190724160749.GF4565@mit.edu> (raw)
In-Reply-To: <20190724061231.GA7074@magnolia>
On Tue, Jul 23, 2019 at 11:12:31PM -0700, Darrick J. Wong wrote:
> On Tue, Jul 23, 2019 at 11:03:54PM -0700, harshad shirwadkar wrote:
> > Before I respond to your questions, I would like to explain how fast
> > commits differ from ijournal in a few key aspects (I will make sure to
> > explain it in detail in patch 00/11 and documentation):
>
> Please do; I hadn't realized there were also journal ondisk format
> changes, and these must be recorded in the ext4 disk format
> documentation.
Actually, the changes are almost entirely in the on-disk journal
layer. The addition of the feature flag is really a UI issue, and
worth some discussion.
One of the goals was to make it easy to allow kernels which didn't
understand fast commit to be able to mount a file system which had
been cleanly unmounted --- but of course, if the file system needs
recovery, and fast commits are in the journal, we can't allow a fast
commit oblivious kernel (or e2fsck) from trying to replay the journal.
One way to do this would be with a mount option, but that's a bit ugly
--- and a mount option in /etc/fstab will cause a failure if a kernel
which doesn't understand that mount option is booted.
So the basic idea is to have a compat feature which means, "please use
fast commits if present", and then when the file system is mounted on
a fast-commit capable kernel, the incompat feature meaning "we're
using the fast commit feature". (This is same design pattern used
with the HAS_JOURNAL compat feature and the NEEDS_RECOVERY incompat
feature.)
The next question is whether to use the compat and incompat feature
flags in the jbd2 superblock, or ext4-specific compat flags. For the
incompat flag, there's no reason not to use the journal incompat flag.
But for the compat flag, we have better infrastructure for setting and
clearing ext4-level compat feature flags. Aside from that, though,
there's no reason why we couldn't use the s_feature_compat field in
the journal superblock --- in which case, *all* of the on-diks format
changes would purely be on the jbd2 side of the ledger.
> Every feature flag you add doubles the size of the testing matrix.
> If I were you I'd only want to test the (fastcommit) and (!fastcommit)
> scenarios.
Sure, absolutely. On the other hand, as the saying goes, "there comes
a time in any project where it's time to shoot the engineers and put
the d*mned thing into production". One of the reasons why we're super
interested in this feature is to claw back the performance hit of
fde872682e17 ("ext4: force inode writes when nfsd calls
commit_metadata"). I fully expect that this feature is going to make
big difference to a number of customer workloads, so there is some
urgency to getting this feature into production.
On the flip side, if we leave some performance wins on the table, it's
absolutely true that it makes it harder to add those optimizations
later, and it increases the testing load, not to mention the forwards
and backwards compatibility issues. It's an engineering trade-off.
- Ted
next prev parent reply other threads:[~2019-07-24 16:08 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-07-22 4:00 [PATCH 01/11] ext4: add handling for extended mount options Harshad Shirwadkar
2019-07-22 4:00 ` [PATCH 02/11] jbd2: add fast commit fields to journal_s structure Harshad Shirwadkar
2019-07-22 4:00 ` [PATCH 03/11] jbd2: fast commit setup and enable Harshad Shirwadkar
2019-07-22 4:00 ` [PATCH 04/11] jbd2: fast-commit commit path changes Harshad Shirwadkar
2019-07-22 4:00 ` [PATCH 05/11] jbd2: fast-commit commit path new APIs Harshad Shirwadkar
2019-07-22 17:45 ` kbuild test robot
2019-07-22 21:02 ` kbuild test robot
2019-07-22 4:00 ` [PATCH 06/11] jbd2: fast-commit recovery path changes Harshad Shirwadkar
2019-07-22 4:00 ` [PATCH 07/11] ext4: add fields that are needed to track changed files Harshad Shirwadkar
2019-07-22 4:00 ` [PATCH 08/11] ext4: track changed files for fast commit Harshad Shirwadkar
2019-07-22 4:00 ` [PATCH 09/11] ext4: fast-commit commit range tracking Harshad Shirwadkar
2019-07-22 4:00 ` [PATCH 10/11] ext4: fast-commit commit path changes Harshad Shirwadkar
2019-07-22 4:00 ` [PATCH 11/11] ext4: fast-commit recovery " Harshad Shirwadkar
2019-07-22 21:34 ` kbuild test robot
2019-07-22 18:15 ` [PATCH 01/11] ext4: add handling for extended mount options Andreas Dilger
2019-07-22 21:02 ` Theodore Y. Ts'o
2019-07-22 21:36 ` harshad shirwadkar
2019-07-23 21:59 ` Andreas Dilger
2019-07-24 6:03 ` harshad shirwadkar
2019-07-24 6:12 ` Darrick J. Wong
2019-07-24 16:07 ` Theodore Y. Ts'o [this message]
2019-07-24 16:56 ` Darrick J. Wong
2019-07-24 18:14 ` harshad shirwadkar
2019-07-25 3:46 ` Theodore Y. Ts'o
2019-07-25 20:03 ` Andreas Dilger
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=20190724160749.GF4565@mit.edu \
--to=tytso@mit.edu \
--cc=adilger@dilger.ca \
--cc=darrick.wong@oracle.com \
--cc=harshadshirwadkar@gmail.com \
--cc=linux-ext4@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;
as well as URLs for NNTP newsgroup(s).