svn commit: r365643 - head/bin/cp

Ian Lepore ian at freebsd.org
Fri Sep 25 18:12:33 UTC 2020


On Fri, 2020-09-25 at 10:55 -0700, Rodney W. Grimes wrote:
> > I was under the impression from previous reading and kib's response
> > that this is a complete non-issue, there's no way you can go
> > multi-user without a mounted /dev and we go to somewhat great
> > lengths to make sure we're good.
> 
> Though kib can assert that, it does not change the fact that I
> frequently find /dev/null FILES on unmounted root file systems.
> 
> But lets not mix the 2 separate things of boot time /dev dependency
> and build time /dev dependency.

If you look in sys/kern/vfs_mountroot.c you can see that the code to
mount /dev is invoked unconditionally as the first step of mounting
root, and that all the calls it makes to get devfs mounted have their
results checked with KASSERTs.

That's pretty strong evidence that devfs is mounted before rc scripts
run.  That creates a situation where you are making an extraordinary
claim, so you need to provide extraordinary evidence to support it.  A
sequence of actions that allows others to recreate the situation would
do the trick.

(A question that occurs to me:  could it be that the files you've seen
got created at shutdown after devfs was unmounted, rather than at
startup?  I don't know enough about the shutdown sequence to know
whether that's possible.)

-- Ian




More information about the svn-src-head mailing list