How to Setup NFS Service on Mac Lion Server

Starting from the 10.7 Lion server, Apple has removed the GUI interface for setting up the NFS service. You’ll have to set up the NFS service via command line. Here is the KB article about how to set it up.

http://support.apple.com/kb/HT4695

Basically, you need to use a text editor to edit /etc/exports to define the folders you want to share. If you have an old server set up for NFS, you can check the exports file on the old server to give you an idea on how to set them up. Once this is done, you can then use the nfsd command to manage the service. For example, to start NFS service, type

sudo nfsd start

To check the staus, type

nfsd status

One thing that’s not mentioned in the KB article is that you can adjust nfsd options in this file /etc/nfs.conf . Type

man nfs.conf

to see all the options available.

If you don’t need to set up NFS to host the user’s home directories, you can stop reading here. However, if you do need to set up NFS for home directories, read on. Apple has another KB for this issue.

http://support.apple.com/kb/ts3889

You will need to use the Directory Utility to configure it. What is missing in this KB is how to use the Directory Utility. Here are the steps:

  1. Use Finder and browse to /System/Library/CoreServices and double click on Directory Utility.
  2. Click on Directory Editor.
  3. Select Mounts from the Viewing combo box.
  4. If you have not authenticated yet, click on the padlock icon to authenticate.
  5. Click on the + icon in the lower left corner to add a mount point. You can use the other mounts in your OD as examples or refer to the KB.

When you are done editing, the record is similar to this:

RecordName: server.example.com:/Volumes/Data/Homes
RecordType: dsRecTypeStandard:Mounts
VFSLinkDir: /Network/Servers
VFSOpts: net
VFSType: nfs

Save the record and you’ll find the new server available when you re-assign the user’s home directory.

 

 


This post may contain affiliated links. When you click on the link and purchase a product, we receive a small commision to keep us running. Thanks.


Be the first to comment

Leave a Reply