[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: kern/52056: mount -u / causes a kernel assertion
The following reply was made to PR kern/52056; it has been noted by GNATS.
From: Matt Sporleder <msporleder%gmail.com@localhost>
To: Robert Elz <kre%munnari.OZ.AU@localhost>
Cc: =?utf-8?Q?Jarom=C3=ADr_Dole=C4=8Dek?= <jaromir.dolecek%gmail.com@localhost>,
gnats-bugs%netbsd.org@localhost, kern-bug-people%netbsd.org@localhost, current-users%netbsd.org@localhost,
netbsd-bugs%netbsd.org@localhost, Martin Husemann <martin%netbsd.org@localhost>
Subject: Re: kern/52056: mount -u / causes a kernel assertion
Date: Fri, 10 Mar 2017 18:39:11 -0500
> On Mar 10, 2017, at 6:00 PM, Robert Elz <kre%munnari.OZ.AU@localhost> wrote:
> In messages related to PR kern/52056 (in gnats) and on firstname.lastname@example.org
> (I am adding current-users as this needs opinions from a wider community).=
> The PR is mostly about kernel issues, this issue with mount -u is only
> relevant because that happened to trigger the kernel, if -u worked
> differently, the actual problem from the PR might not have been noticed.
> Date: Fri, 10 Mar 2017 15:00:13 +0100
> From: =3D?UTF-8?B?SmFyb23DrXIgRG9sZcSNZWs=3D?=3D <jaromir.dolece=
> Message-ID: <CAMnsW54zJHN1Kj_-bg8HJ11WSfFzcy9XT0Ebap52GJCRL3fMQQ@mail.=
> | Some volunteer for checking why the -u doesn't work as advertized?
> The issue is that the man page (mount(8)) says that -u takes options from
> fstab, then the command line -o options, and then -r or -w - but the code
> does not do that, fstab options are ignored with -u, only options from the=
> command line are used.
> It kind of seems to be deliberate - though I have no idea why.
> Back in the early days (until mid 1994) it seems to have worked as the
> man page states - the relevant text in the man page has been essentially
> unchanged since version 1.1. When 4.4-lite was incorporated in June 199=
> the code changed, and the following lines appeared ...
> /* If it's an update, ignore the fstab file options. */
> fs->fs_mntops =3D NULL;
> (in the code processing the -u case). The code was restructured in 1998,=
> but this was not altered in substance - the comment was deleted though.
> It has remained essentially unchanged ever since.
> So, it appears that 4.4-lite made this change, and apparently intentionall=
> but I have no idea why.
> Changing it is trivial, if that is desired. The question now is, which
> should be fixed, the man page, or the code?
> One last thing that's interesting, back in Nov 1997, a correction to the
> man page has this as its commit log message ...
> Add a clarification how the missing data are looked up if either
> mount source or target are omitted. Adresses PR 3240.
> XXX This is not the complete truth. Things change with the -u
> option. Should be fixed in "mount.c".
> The actual change that commit made is not relevant here, but the XXX
> note indicates that way back then this issue was known, and at least one
> developer thought it should be fixed in the source.
> So, does anyone believe that we should change the man page, and note that
> options from fstab are ignored with -u, or should the code be changed so
> that it works as the man page has (always) advertised (but which it hasn't=
> done for the past (almost) 23 years.)
What do the other BSDs do in this case?=
Main Index |
Thread Index |