System Administration Guide, Volume 3

How to Set Up Automatic File-System Sharing

  1. Become superuser.

  2. Add entries for each file system to be shared.

    Edit /etc/dfs/dfstab and add one entry to the file for each file system that you want to be automatically shared. Each entry must be on a line by itself in the file and uses this syntax:


    share [-F nfs] [-o specific-options] [-d description] pathname

    See the share_nfs(1M) man page for a complete list of options.

  3. Check that the NFS service is running on the server.

    If this is the first share command or set of share commands that you have initiated, it is likely that the NFS daemons are not running. The following commands kill the daemons and restart them.


    # /etc/init.d/nfs.server stop
    # /etc/init.d/nfs.server start
    

    This ensures that NFS service is now running on the servers and will restart automatically when the server is at run level 3 during boot.

Where to Go From Here

The next step is to set up your autofs maps so that clients can access the file systems you have shared on the server. See "Autofs Administration Task Overview".