From owner-freebsd-current@FreeBSD.ORG Thu May 26 13:14:17 2011 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E294D106567A; Thu, 26 May 2011 13:14:17 +0000 (UTC) (envelope-from rmacklem@uoguelph.ca) Received: from esa-jnhn.mail.uoguelph.ca (esa-jnhn.mail.uoguelph.ca [131.104.91.44]) by mx1.freebsd.org (Postfix) with ESMTP id 61C8D8FC14; Thu, 26 May 2011 13:14:16 +0000 (UTC) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Ap4EAPtR3k2DaFvO/2dsb2JhbABUG4QuolyIcKxmkGKBK4NqgQcEkDmPLA X-IronPort-AV: E=Sophos;i="4.65,273,1304308800"; d="scan'208";a="125900025" Received: from erie.cs.uoguelph.ca (HELO zcs3.mail.uoguelph.ca) ([131.104.91.206]) by esa-jnhn-pri.mail.uoguelph.ca with ESMTP; 26 May 2011 09:14:01 -0400 Received: from zcs3.mail.uoguelph.ca (localhost.localdomain [127.0.0.1]) by zcs3.mail.uoguelph.ca (Postfix) with ESMTP id 094DEB3E95; Thu, 26 May 2011 09:14:01 -0400 (EDT) Date: Thu, 26 May 2011 09:14:01 -0400 (EDT) From: Rick Macklem To: Andriy Gapon Message-ID: <2055538246.835079.1306415640980.JavaMail.root@erie.cs.uoguelph.ca> In-Reply-To: <4DDE1D05.5030109@FreeBSD.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Originating-IP: [172.17.91.201] X-Mailer: Zimbra 6.0.10_GA_2692 (ZimbraWebClient - IE7 (Win)/6.0.10_GA_2692) Cc: Rick Macklem , FreeBSD-Current Subject: Re: newnfs user setup X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 26 May 2011 13:14:18 -0000 > 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