Re: newnfs user setup

From: Rick Macklem <rmacklem_at_uoguelph.ca>
Date: Thu, 26 May 2011 09:14:01 -0400 (EDT)
> Rick,
> 
> maybe I've just not looked hard enough, but I am a little bit confused
> about how
> to setup properly newnfs server and client via rc.conf.
> That is, I am not sure which exactly daemons I need and what variables
> to set.
> 
Well, for head/current, I don't think you'll need anything different unless
you want to run NFSv4. If you want to force use of the old nfs server, you
can do that with:
oldnfs_server_enable="YES"

As for the client side, I have up to date scripts for /etc/rc.d in
http://people.freebsd.org/~rmacklem/rc.conf
- I am waiting for a review on those, before they go into head.

> The reason I am asking is that I see some things than seems unexpected
> to me.
> For example, rc.d/nfsserver tries to load nfsserver.ko, but that fails
> in my
> environment:
> root: /etc/rc: WARNING: Unable to load kernel module nfsserver
Hmm, I have no idea why the old server module won't load for you, but
if you want to run the new/default one, you don't need it anyhow.
(If you replace /etc/rc.d/nfsd with the one in ~rmacklem/rc.conf you
 should delete /etc/rc.d/nfsserver. All it does is make the old nfs
 server module load and my modified /etc/rc.d/nfsd does that, as required.)

> And these modules come built into my kernel:
> $ kldstat -v | fgrep nfs
> 171 nfssvc
> 126 nfsd
> 123 nfscommon
> 172 nfslockd
> 124 nfs
> 130 unionfs
> 125 nfscl
> 170 nfslock
> 
So you have the new client (nfscl) and new server (nfsd) already loaded
and should be good to go.

> Also, I see that rc.d/nfsclient has
> required_modules="nfsclient:oldnfs"
> which is also a little bit surprising.
> 
This would just force loading of the old client. Harmless, but unnecessary
unless you are using it.
This is because the rc.d scripts haven`t been updated for the client yet.
(See above w.r.t. ones for review. The 3 that change are mountcritremote,
 nfsclient, plus a one line change to rc.conf in defaults.)
However, I think everything should work for your case. 

> So I would appreciate an example here.
> 
I don`t think any changes are necessary, although it would be nice if you
grabbed the new rc.d scripts and tested them.

> Also, for my future tests, I would like to get some pointers on
> getting started
> with NFSv4 in FreeBSD.
> 
For the NFSv4 client, you need to:
nfsuserd_enable=``YES``

for the server
nfsv4_server_enable=``YES``
nfs_server_enable=``YES``
- you`ll also need to add a ``V4: ...`` line to your exports file. See
  man exports or man nfsv4

rick
Received on Thu May 26 2011 - 11:14:17 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:40:14 UTC