From: "Darrick J. Wong" <djwong@us.ibm.com>
To: Andreas Dilger <adilger@dilger.ca>
Cc: "Theodore Ts'o" <tytso@mit.edu>,
Andreas Dilger <adilger.kernel@dilger.ca>,
linux-fsdevel <linux-fsdevel@vger.kernel.org>,
linux-ext4 <linux-ext4@vger.kernel.org>,
linux-kernel <linux-kernel@vger.kernel.org>,
Sunil Mushran <sunil.mushran@oracle.com>,
Joel Becker <jlbec@evilplan.org>, Mingming Cao <cmm@us.ibm.com>,
Amir Goldstein <amir73il@gmail.com>, Coly Li <colyli@gmail.com>,
Andi Kleen <andi@firstfloor.org>
Subject: Re: [RFC] ext4 metadata checksumming design
Date: Thu, 18 Aug 2011 11:14:23 -0700 [thread overview]
Message-ID: <20110818181423.GR20655@tux1.beaverton.ibm.com> (raw)
In-Reply-To: <EB5DDA28-421A-4C67-817C-74F9B9643351@dilger.ca>
On Thu, Aug 18, 2011 at 12:16:00AM -0600, Andreas Dilger wrote:
> On 2011-08-16, at 9:25 PM, "Darrick J. Wong" <djwong@us.ibm.com> wrote:
> > - Extended attribute blocks that are stored in the inode table -- the h_magic
> > field is written by the kernel, but neither the kernel nor e2fsprogs ever
> > actually read this field. The field could be reused to checksum the extra
> > space since (as far as I can tell) EAs are the only user of that empty space.
>
> I haven't had a chance to read the document you wrote, but wanted to comment
> on xattrs. There is a hash field for each xattr (including internal xattrs),
> and one for the external xattr blocks that can be used to validate the xattr
> value.
>
> In addition to the hash for the in-inode xattrs, the inode hash itself would
> serve to validate the xattr values.
>
> I have a patch for e2fsprogs that checks the xattr hash for in-inode xattrs
> (currently it is always 0).
I surveyed the h_hash/e_hash calculation code; it only covers the name and
value fields. Do we care about checksum protection for the extra fields in
struct ext4_xattr_header and struct ext4_xattr_entry? I think it would be
useful to be able to check the sanity of h_refcount and h_blocks. Possibly
that extends to e_value_* as well, though the hash probably covers it. Also,
there's no hardware acceleration available for the xattr hash, though I doubt
xattrs are especially performance sensitive.
--D
>
> > Please have a look at the design document and please feel free to suggest any
> > changes.
>
> Hopefully soon.
>
> Cheers, Andreas--
> To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2011-08-18 18:14 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-08-17 3:25 [RFC] ext4 metadata checksumming design Darrick J. Wong
2011-08-17 13:57 ` Andi Kleen
2011-08-17 17:09 ` Darrick J. Wong
2011-08-18 6:16 ` Andreas Dilger
2011-08-18 18:14 ` Darrick J. Wong [this message]
2011-08-18 21:53 ` Andreas Dilger
2011-08-18 23:00 ` Darrick J. Wong
2011-08-19 17:46 ` Coly Li
2011-08-22 18:11 ` Andreas Dilger
2011-08-23 2:35 ` Darrick J. Wong
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=20110818181423.GR20655@tux1.beaverton.ibm.com \
--to=djwong@us.ibm.com \
--cc=adilger.kernel@dilger.ca \
--cc=adilger@dilger.ca \
--cc=amir73il@gmail.com \
--cc=andi@firstfloor.org \
--cc=cmm@us.ibm.com \
--cc=colyli@gmail.com \
--cc=jlbec@evilplan.org \
--cc=linux-ext4@vger.kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=sunil.mushran@oracle.com \
--cc=tytso@mit.edu \
/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).