HP-UX Reference (11i v1 05/09) - 1M System Administration Commands A-M (vol 3)
a
automount(1M) automount(1M)
DESCRIPTION — Automounter
The automount command is a daemon that automatically and transparently mounts NFS file systems as
needed. It monitors attempts to access directories that are associated with an
automount map, along
with any directories or files that reside under them. When a file is to be accessed, the daemon mounts the
appropriate NFS file system. Maps can be assigned to a directory by using an entry in a direct
auto-
mount
map, or by specifying an indirect map on the command line.
automount interacts with the kernel in a manner closely resembling an NFS server:
• automount uses the map to locate an appropriate NFS file server, exported file system, and mount
options.
• Then it mounts the file system in a temporary location, and replaces the file system entry for the
directory or subdirectory with a symbolic link to the temporary location.
• If the file system is not accessed within an appropriate interval (five minutes by default), the daemon
unmounts the file system and removes the symbolic link.
• If the specified directory has not already been created, the daemon creates it, and then removes it
upon exiting.
Since name-to-location binding is dynamic, updates to an
automount map are transparent to the user.
This obviates the need to mount shared file systems prior to running applications that contain internally
hard-coded references to files.
If the dummy directory (
/-) is specified, automount treats the map argument that follows as the name
of a direct map. In a direct map, each entry associates the full path name of a mount point with a remote
file system to mount.
If the directory argument is a path name, the map argument points to an indirect map. An indirect map,
contains a list of the subdirectories contained within the indicated directory. With an indirect map, it is
these subdirectories that are mounted automatically.
A map can be a file or a NIS/NIS+ map; if a file, the map argument must be a full path name.
The
-mount-options argument, when supplied, is a comma-separated list of options to the
mount com-
mand (see mount(1M)) preceded by a
-. However, any conflicting mount options specified in the indicated
map take precedence.
Options
automount recognizes the following options:
-m Option not supported.
-n Disable dynamic mounts. With this option, references through the automount dae-
mon succeed only when the target 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 log it in /var/adm/automount.log
file.
-v Verbose. Log status messages to the system log file (see syslogd(1M)).
-D envar = value
Assign value to the indicated automount (environment) variable envar.
-f master-file Read the local master_file before reading auto_master map.
-M mount-directory
Mount temporary file systems in the named directory instead of in /tmp_mnt.
-tl duration Specify a duration (in seconds) that a file system is to remain mounted when not in
use. The default is 300 (5 minutes).
-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 unmount filesystems that have
exceeded their cached times. The default is 60 (1 minute).
Map Entry Format
A simple map entry (mapping) takes the form:
Section 1M−−94 Hewlett-Packard Company − 6 − HP-UX 11i Version 1: September 2005