Mounting NFSv4 as root fs

Chris Telting christopher-ml at telting.org
Sun Apr 3 22:13:29 UTC 2011


On 02/18/2011 13:38, Rick Macklem wrote:
> Yep. I didn't see an easy way to set up the diskless root so that it would
> work for both clients concurrently, so I was planning on switching it if/when
> "newnfs" becomes the default client. (You can switch fairly easily. Just
> crib the code across, as it sounds like you have and then make sure the
> xxx_mountroot() in "newnfs" gets called instead of nfs_mountroot() in the
> other one.
>
> However, that will just get a "newnfs" NFSv3 root mount to work.
>
Sounds like it should be a kernel option as to which NFS implementation 
is default on a pxeboot.

> I have never intended to try and make an NFSv4 root mount work.
> (Someone said NFSv4 is NFS in name only:-)
>

That's a shame.  It seems logical to me that that's a critical feature 
to it's acceptance.

I'm still new to nfsv4 so please forgive  what I don't understand.  The 
kernel boots the a normal disk filesystem only knowing uid/gid numbers.  
It only understands what is root accessible or suid and what isn't.  
Once the filesystem is mounted it can consult whatever database is used 
for further information.  Why can't we make nfsv4 tolerant of running 
without nfsuserd information at least initially?  Have a special 
filesystem option to run it in crippled mode.  And once we have 
networking and nfsuserd loaded we can remount the filesystem..?


Chris




More information about the freebsd-fs mailing list