Adding NFS disk to the mount table

The MacOS X uses the directory services for maintaing the mount database. To add a nfs disk to the mac automount table. You
edit the /etc/fstab file and create a typical UNIX nfs mount entry to the file.

    saturn:/etc root# vi fstab
    saturn:/etc root# more fstab
    perkins:/perkins/home   /perkins/home   nfs     rw,hard,intr,auto 0 0
    perkins:/perkins/data   /perkins/data   nfs     rw,hard,intr,auto 0 0
    blick:/blick/home       /blick/home     nfs     rw,hard,intr,auto 0 0

Once the fstab is either created or changed you add the entries to the directory services with a niload command. The niload
uses a set of formats to read a standard input.

niload <options> <format> <directory> < file to add to services

Soi in the following example using the verbose option(-v) I write the file /etc/fstab to in a fstab format to the local directory service(.)

    saturn:/etc root# niload -v fstab . < /etc/fstab
    3 items read from input
    Netinfo /mounts contains 4 items

    Processing input item:
    dir: /perkins/home
    dump_freq: 0
    name: perkins:/perkins/home
    opts: rw hard intr auto
    passno: 0
    vfstype: nfs

    writing directory /mounts/perkins:\/perkins\/home

    Processing input item:
    dir: /perkins/data
    dump_freq: 0
    name: perkins:/perkins/data
    opts: rw hard intr auto
    passno: 0
    vfstype: nfs

    writing directory /mounts/perkins:\/perkins\/data

    Processing input item:
    dir: /blick/home
    dump_freq: 0
    name: blick:/blick/home
    opts: rw hard intr auto 
    passno: 0
    vfstype: nfs

   writing directory /mounts/blick:\/blick\/home
   saturn:/etc root#

-- Main.BrianWTaylor - 19 May 2006

  • No labels