Managing Network File Systems in Oracle® Solaris 11.2

Exit Print View

Updated: July 2014
 
 

How to Mount a File System at Boot Time

This procedure shows how to mount file systems at boot time instead of using the autofs maps. This procedure must be completed on every client that requires access to remote file systems.

  1. Become an administrator.

    For more information, see Using Your Assigned Administrative Rights in Securing Users and Processes in Oracle Solaris 11.2 .

  2. Add an entry for the file system to the /etc/vfstab file.

    Entries in the /etc/vfstab file have the following syntax:

    #device       device       mount      FS      fsck    mount     mount    
    #to mount     to fsck      point      type    pass    at boot   options

    For information about the /etc/vfstab file entries, see the vfstab (4) man page.


    Caution

    Caution  -  NFS servers that also have NFS client vfstab entries must always specify the –bg option to avoid a system hang during reboot. For more information, see the mount (1M) man page.


  3. Enable the NFS client service.
    # svcadm enable network/nfs/client
Example 3-1  Entry in the Client's /etc/vfstab File

Assume that you want a client system to mount the /var/mail directory from the server wasp. You want the file system to be mounted as /var/mail on the client, and you want the client to have read-write access. You would add the following entry to the client's vfstab file:

wasp:/var/mail - /var/mail nfs - yes rw