From: "Bill O'Donnell" <billodo@redhat.com>
To: Dave Chinner <david@fromorbit.com>
Cc: xfs@oss.sgi.com
Subject: Re: [PATCH] xfsprogs: don't populate fs table with foreign fs paths unless foreign_allowed
Date: Mon, 29 Aug 2016 19:53:38 -0500 [thread overview]
Message-ID: <20160830005338.GA21506@redhat.com> (raw)
In-Reply-To: <20160830002513.GT19025@dastard>
On Tue, Aug 30, 2016 at 10:25:13AM +1000, Dave Chinner wrote:
> On Mon, Aug 29, 2016 at 06:47:04PM -0500, Bill O'Donnell wrote:
> > On Tue, Aug 30, 2016 at 09:40:44AM +1000, Dave Chinner wrote:
> > > On Mon, Aug 29, 2016 at 06:26:15PM -0500, Bill O'Donnell wrote:
> > > > On Tue, Aug 30, 2016 at 09:12:06AM +1000, Dave Chinner wrote:
> > > > > On Mon, Aug 29, 2016 at 08:40:12AM -0500, Bill O'Donnell wrote:
> > > > > > Commits b20b6c2 and 29647c8 modified xfs_quota for use on
> > > > > > non-XFS filesystems. One modification in fs_initialise_mounts
> > > > > > (paths.c) resulted in an xfstest fail (xfs/261), due to foreign
> > > > > > fs paths entering the fs table.
> > > > >
> > > > > What's the failure? I'm not seeing it here on any of my test
> > > > > machines...
> > > >
> > > > On my box, there are a few ext4 mounts, and test xfs/261
> > > > populates the fs table with those paths.
> > >
> > > I have ext2 and ext3 mounts on these machines as well, and they
> > > don't throw any errors.
> > >
> > > > So when xfs_quota commands
> > > > in 261 are executed, a "foreign filesystem" message is thrown.
> > >
> > > What is the output that is causing the failure? When someone
> > > asks you to describe the error that is occurring, please quote the
> > > /exact error/ that is occurring - describing it via paraphrasing
> > > does not tell anything useful about the error as I cannot correlate
> > > that description to the code that is throwing it.
> >
> > Ahh, ok, I'm sorry about that.
> > [root@dell-pesc440-01 xfstests-dev]# ./check -d tests/xfs/261
> > FSTYP -- xfs (debug)
> > PLATFORM -- Linux/x86_64 dell-pesc440-01 4.7.0-rc108052016bill02+
> > MKFS_OPTIONS -- -f -bsize=4096 /dev/mapper/fedora_dell--pesc440--01-csdf
> > MOUNT_OPTIONS -- -o context=system_u:object_r:nfs_t:s0 /dev/mapper/fedora_dell--pesc440--01-csdf /mnt/scratch
> >
> > xfs/261 2s ...QA output created by 261
> > Silence is golden.
> > print command is for XFS filesystems only
> > print command is for XFS filesystems only
> > print command is for XFS filesystems only
> > print command is for XFS filesystems only
> > print command is for XFS filesystems only
> > print command is for XFS filesystems only
> > print command is for XFS filesystems only
> > print command is for XFS filesystems only
>
> Bill, slow down and work through the code from first principles. I
> don't care about getting a fix quickly - I care about the process
> you use to find the problem and whether you end up fully
> understanding the problem. Walk through the code in the debugger if
> you have to - it will show you the flow and how the pieces connect
> together.
>
> The question that needs to be answered is this: what set of initial
> conditions is causing this error to occur? We don't really care
> about what previous changes caused the issue at this point - working
> that out comes /after/ diagnosing the problem when we are trying to
> work out a fix.
>
> So, yes, the issue occurs because there are foreign fs types in the
> fstable, but that's not the underlying problem nor the problem that
> needs to be solved.
>
> Use the debugger and cssope to connect the dots between the fstable
> initialisation, the fs_path initialisation, and the function that
> prints that error. That should give you a good idea of why the error
> is being printed.
>
> Then have a look at print_f() and see what it does with the fstable.
> Then tell me whether we should even care about checking for foreign
> filesystems before we run the print_f command. At this point, the
> fix should be obvious.
>
> And then have a look at printpath() and tell me what the foriegn
> filesystem handling bug it contains.
>
> And, yes, I could have written and tested the patch to fix all this
> in the time it took to write this email, but then you don't have the
> opportunity to learn from doing it....
OK, will do. Thanks Dave.
-Bill
>
> Cheers,
>
> Dave.
> --
> Dave Chinner
> david@fromorbit.com
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
next prev parent reply other threads:[~2016-08-30 0:53 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-08-29 13:40 [PATCH] xfsprogs: don't populate fs table with foreign fs paths unless foreign_allowed Bill O'Donnell
2016-08-29 15:13 ` Darrick J. Wong
2016-08-29 15:43 ` Bill O'Donnell
2016-08-29 23:16 ` Dave Chinner
2016-08-29 23:28 ` Bill O'Donnell
2016-08-29 23:12 ` Dave Chinner
2016-08-29 23:26 ` Bill O'Donnell
2016-08-29 23:40 ` Dave Chinner
2016-08-29 23:47 ` Bill O'Donnell
2016-08-30 0:25 ` Dave Chinner
2016-08-30 0:53 ` Bill O'Donnell [this message]
2016-09-01 22:07 ` Bill O'Donnell
2016-09-02 21:22 ` [PATCH v2] xfsprogs: (xfs_quota) foreign fs path handling changes Bill O'Donnell
2016-09-02 22:57 ` Eric Sandeen
2016-09-02 23:10 ` Bill O'Donnell
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=20160830005338.GA21506@redhat.com \
--to=billodo@redhat.com \
--cc=david@fromorbit.com \
--cc=xfs@oss.sgi.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).