projects techreports press lab location staff
citi top.2 top.3
citi mid.3
bot.1 bot.2 bot.3

Projects: NFS Version 4 Open Source Reference Implementation

NFSv4 Version 3.0 Distribution - feb_2002_rel

This work was done as part of the NFS Version 4 Open Source Reference Implementation project. This release is in the form of a patch against the Linux-2.4.4 kernel.

Code Level and Management

This is new code, and we expect bugs. We will be testing this code at Connectathon 2002 and will be releasing new versions of this patch with high frequency until Connectathon 2002 is over. Unlike past releases, we then intend for the general Linux community to participate in bug fixes and code development. The NFSv4 client code is ahead of the server code, which needs a code review and cleanup.


The main NFSv4 client and server patch for Linux-2.4.4 kernel comes in several versions.:
The latest version with Connectathon 2002 bug fixes. This patch is a stand-alone - it does not work with the rpcsec_gss patch: 3-18-2002: linux-2.4.4-nfsv4-3.1.patch
Old version - this patch does work with the rpcsec_gss patch: linux-2.4.4-nfsv4-3.0.patch
The NFSv4 utility source: nfsv4_utilities.tar.gz
For RPCSEC_GSS functionality, see the rpcsec_gss patch page.
For ACL functionaly, see the nfsv4_acl patch page. (NOTE: Coming soon!)


Note: the following instructions for the main patch apply to all main patch versions.

  1. Apply the linux-2.4.4-nfsv4-3.0.patch to the stock Linux-2.4.4 kernel. NOTE: some versions of the patch program will generate a spurious warning about a possible reverse hunk. Just answer "no" (the default) when asked if patch should assume -R, and answer "yes" (not the default) when asked if patch should apply the patch anyway.
    # cd /usr/src/linux
    # patch -p1 < linux-2.4.4-nfsv4-3.0.patch
  2. Run make xconfig.  Set "NFS file system support" to "n". Set "NFS server support" to "n".  Set "NFSv4 file system support" to "m".  Set "NFSv4 server support" to "m".  The linux-2.4.4-nfsv4-30.patch does not include the RPCSEC_GSS code - that is in the rpcsec_gss patch. Set "RPCSEC_GSS support" to "n". The resulting /usr/src/linux/.config should look like this:
            # CONFIG_NFS_FS is not set
            # CONFIG_NFSD is not set
            # CONFIG_LOCKD is not set
            # CONFIG_SUNRPC_GSS is not set
  3. Build the kernel.
            # cd /usr/src/linux
            # make dep
            # make bzImage
  4. Install the kernel.
            # cp /usr/src/linux/ /boot/
            # cp arch/i386/boot/bzImage /boot/vmlinux-nfsv4
  5. Add a stanza to /etc/lilo.conf with an image to match your kernel installation.
  6. Run lilo, and reboot.
  7. Build and install all kernel modules.
            # cd /usr/src/linux
            # make modules
            # make modules_install
  8. Unpack, build, and install the nfsv4 utilities in nfsv4_utilities.tar.gz. Note: The instructions below assume that Kerberos 5 is installed under /usr/kerberos, because so far we only build under RedHat 7.x. RedHat 7.2 only comes with kerberos5 "workstation," which is the binaries and shared libraries. To build and run GSSD you need krb5 "devel," which is include files and non-shared libs. It's krb5-devel-1.2.2-13.i386.rpm on the second RedHat CD. The RPCSEC_GSS patch will require our enhanced version of Mit's Kerberos v5-1.2.1. Also, we recommend installing the nfsv4-enabled mount under another filename such as mount4, so as not to replace the built-in mount on your system.
            # cd /usr/src
            # tar -zxvf nfsv4_utilities.tar.gz
            # cd nfsv4_utilities/export_parser
            # make
            # make install
            # cd nfsv4_utilities/rpcsec_gss
            # ./configure --with-krb5=/usr/kerberos
            # make
            # cd gssd
            # install -c -m 755 gssd /usr/sbin/gssd
            # cd /usr/src/nfsv4_utilities/mount-2.11n
            # make
            # install -c -m 755 mount /usr/sbin/mount4

Configuration and Operation


  1. Create an /etc/exports file, following the directions. NOTE that without RPCSEC_GSS, the /etc/exports sec:: options are not valid.
  2. Start the server.  This will load the modules, start gssd, and run /usr/sbin/exportfs4 to start the nfsv4 server(s). The nfs4 startup script is installed as part of the nfsv4_utilities/export_parser installation.
            # /etc/rc.d/init.d/nfs4 start


  1. Start the GSS daemon.  NOTE: the '-n' option is needed when RPCSEC_GSS is not enabled.
            # /usr/sbin/gssd -n &
  2. Load the necessary modules.
            # insmod sunrpc
            # insmod nfs4
            # insmod nfs4fs
  3. Use the NFSv4-enabled mount4 to mount a directory from the server. projects | techreports | press | lab | location | staff Email address
or call +1 734 763 2929
Copyright © 1996-2013
The Regents of the University of Michigan