Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ automount(1M) — sysv — mips UMIPS RISC/os 4.52

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

mount(1M)



AUTOMOUNT(1M-SysV)  RISC/os Reference Manual   AUTOMOUNT(1M-SysV)



NAME
     automount - automatically mount NFS file systems

SYNOPSIS
     automount [ -mnTv ] [ -D name=value ] [ -f master-file ]
          [ -M mount-directory ] [ -R root ] [ -S ] [ -t sub-
     options ]
          [ directory mapname [ -mount-options ] ] ...

DESCRIPTION
     automount is a daemon that will automatically and tran-
     sparently mount an NFS file system whenever a file or direc-
     tory within in that system is opened.  automount forks a
     daemon, which appears to be an NFS server to the kernel;
     lookups on the specified directory are intercepted by this
     daemon, which uses the map contained in mapname to determine
     a server, exported file system, and appropriate mount
     options for a given file system.  The named map can either
     be a file on the local system, or a Network Information Ser-
     vice map.  directory is a full pathname starting with a `/'.

     When supplied, -mount-options consists of the leading - and
     a comma-separated list of mount(1M) options; if mount
     options are specified in the map, however, those in the map
     take precedence.

     Once mounted, members of the directory are made available
     using a symbolic link to the real mount point within a tem-
     porary directory.

     If directory does not exist, the daemon creates it, and then
     removes it automatically when the daemon exits.

     Since the name-to-location binding is dynamic, updates to a
     Network Information Service map are transparent to the user.
     This obviates the need to ``pre-mount'' shared file systems
     for applications that have ``hard coded'' references to
     files.  It also obviates the need to maintain records of
     which hosts must be mounted for what applications.

   Maps
     automount looks first for the indicated mapname in a file by
     that name. If there is no such file, it looks for a NIS map
     by that name.

     An automount map is composed of a list of mappings, with one
     mapping per line.  Each mapping is composed of the following
     fields:

          basename   [-mount-options]   location   [...]





                         Printed 1/15/91                   Page 1





AUTOMOUNT(1M-SysV)  RISC/os Reference Manual   AUTOMOUNT(1M-SysV)



     where basename is the name of a subdirectory within the
     directory specified in the automount command line (not a
     relative pathname).  The location field consists of an entry
     of the form:

          host:directory[:subdir]

     where host is the name of the host from which to mount the
     file system, directory is the pathname of the directory to
     mount, and subdir, when supplied, is the name of a subdirec-
     tory to which the symbolic link is made.  This can be used
     to prevent duplicate mounts in cases where multiple direc-
     tories in the same remote file system are accessed.

     The contents of a NIS map can be included within a map by
     adding an entry of the form:

          +mapname

     A mapping can be continued across line breaks using a \ as
     the last character before the NEWLINE. Comments begin with a
     # and end at the subsequent NEWLINE.

     If more than one location is supplied, there is no guarantee
     as to which location will be used; the first location to
     respond to the mount request gets mounted.  The mount-
     options field can be used to supply options to the mount(1M)
     command for the mounted file system.

   Special Maps
     There are two special maps currently available.  The -hosts
     map uses the Network Information Service hosts.byname map to
     locate a remote host when the hostname is specified as a
     subdirectory of directory.  This map specifies mounts of all
     exported file systems from any host.  For instance, if the
     following automount command is already in effect:

           automount /net -hosts

     then a reference to /net/hermes/usr would initiate an
     automatic mount of all file systems from hermes that auto-
     mount can mount; references to a directory under /net/hermes
     will refer to the corresponding directory on hermes.  The
     -passwd map uses the passwd(4) database to attempt to locate
     the home directory of a user.  For instance, if the follow-
     ing automount command is already in effect:

          automount /homes -passwd

     then if the home directory shown in the passwd entry for the
     user username has the form /dir/server/username, and server
     matches the host system on which that directory resides,



 Page 2                  Printed 1/15/91





AUTOMOUNT(1M-SysV)  RISC/os Reference Manual   AUTOMOUNT(1M-SysV)



     references to files in /homes/username result in the file
     system containing that directory being mounted if necessary,
     and all such references will refer to that user's home
     directory.

   Configuration
     automount normally consults the auto.master Network Informa-
     tion Service configuration database for a list of initial
     directory to mapname pairs, and sets up automatic mounts for
     them in addition to those given on the command line; if
     there are duplications, the command-line arguments take pre-
     cedence.  (Note that this database contains arguments to the
     automount command, rather than mappings, and that automount
     does not look for an auto.master file on the local host.)

     At system boot, the automounter gets started if the sentinel
     file /etc/automount.conf is present.  The first line of this
     file should contain any parameters which are to be passed at
     boottime.  /etc/automount.conf.sample contains an example.

   Killing the Automounter
     In order to kill automount, type:

           kill <automount pid>

     Before exiting, automount attempts to unmount all non-busy
     filesystems, subject to the constraint that all of a
     machine's filesystems are non-busy before any of that
     machine's filesystems are unmounted.  Do not use umount(1M)
     to unmount any NFS filesystems if you plan on starting
     another automount process soon.  Inconsistencies will result
     when all of a specific machine's filesystems can not be
     unmounted at the same time.

OPTIONS
     -m   Suppress initialization of directory-mapname pairs
          listed in the auto.master Network Information Service
          database.

     -n   Disable dynamic mounts.  With this option, references
          through the automount daemon only succeed when the tar-
          get filesystem has been previously mounted.  This can
          be used to prevent NFS servers from cross-mounting each
          other.

     -T   Trace.  Expand each NFS call and display it on the
          standard output.

     -v   Enable verbose error messages.

     -D name=value
          Set environment variables.  See automount document in



                         Printed 1/15/91                   Page 3





AUTOMOUNT(1M-SysV)  RISC/os Reference Manual   AUTOMOUNT(1M-SysV)



          the system administrator's guide for examples.

     -f master-file
          Specify the master map.  See automount document in the
          system administrator's guid for examples.

     -M mount-directory
          Rename the temporary directory used by the automounter.
          The default is /tmp_dir

     -R root
          This option is recommended when a machine may have many
          NFS filesystems mounted at once.  Instead of mounting a
          host's filesystems on
          /tmp_dir/access_point/hostname/..., automount mounts
          them on /tmp_dir/access_point/hostname/<root>/...,

     -S   Instead of mounting a host's filesystems on
          /tmp_dir/access_point/hostname/..., automount mounts
          them on /tmp_dir/hostname/...

     -tl duration
          Specify a duration, in seconds, that a looked up name
          remains cached when not in use.  The default is 60
          minutes.  NOTE: This was changed from 5 minutes because
          it would do more damage to attempt this too often.

     -tm interval
          Specify an interval, in seconds, between attempts to
          mount a filesystem. The default is 30 seconds.

     -tw interval
          Specify an interval, in seconds, between attempts to
          dismount filesystems that have exceeded their cached
          times.  The default is 60 minutes.  NOTE: This was
          changed from 1 minute because it would do more damage
          to attempt this too often.

EXAMPLES
   file example
     Mount the root file system of the machine oddjob to
     /n/oddjob. The map file is /etc/map and contains

          oddjob oddjob:/

     Access as follows:

          tutorial# automount /n /etc/map

          tutorial# cd /n/oddjob





 Page 4                  Printed 1/15/91





AUTOMOUNT(1M-SysV)  RISC/os Reference Manual   AUTOMOUNT(1M-SysV)



     NOTE: This example is inadequate for most purposes and is
     placed here just to clarify syntax.  Please read the auto-
     mounter document in the System Administrator's Guide for
     more complete examples.

   Host-to-host example
          tutorial# automount -M /NET -R root -S /n -hosts
          -rw,bg,soft,intr,timeo=3,retry=3

     Access by:

          tutorial# cd /n/jaws

     This setup will mount all mountable NFS file systems from
     jaws onto /NET/jaws/root/... . /n/jaws becomes a shorthand
     to access /NET/jaws/root.

   NIS example
          tutorial# automount -m /net -hosts

     Provide automount access to the exported file systems of any
     host in the Network Information Service hosts.byname data-
     base, by prefixing the pathname with /net/hostname/ :

          tutorial% ls /net/hermes/usr/src ...

FILES
     /tmp_mnt            directory under which filesystems are
                         dynamically mounted

     /etc/automount.conf Configuration file which causes auto-
                         mount to start at boottime

     /etc/automount.conf.sample
                         A sample configuration file

SEE ALSO
     mount(1M).

     System Administrator's Guide.

BUGS
     Shell filename expansion does not apply to objects not
     currently mounted or cached.  For instance, in the above
     example, the command ls /net/* might not list hermes as a
     subdirectory of /net.

ORIGIN
     Sun Microsystems, NFS 4.0






                         Printed 1/15/91                   Page 5



Typewritten Software • bear@typewritten.org • Edmonds, WA 98026