HP-UX Reference (11i v2 04/09) - 1M System Administration Commands A-M (vol 3)
a
automount(1M) automount(1M)
immediately.
Included Maps
The contents of another map can be included within a map with an entry of the form:
+mapname
If mapname begins with a slash then it is assumed to be the pathname of a local file. Otherwise the loca-
tion of the map is determined by the policy of the name service switch according to the entry for the auto-
mounter in
/etc/nsswitch.conf
, such as
automount: nis files
If the name service is files then the name is assumed to be that of a local file in
/etc. If the key being
searched for is not found in the included map, the search continues with the next entry.
Special Maps
There are two special maps available:
-hosts
and -null. The -hosts map is used with the /net
directory and assumes that the map key is the hostname of an NFS server. The
automountd daemon
dynamically constructs a map entry from the server’s list of exported filesystems. References to a direc-
tory under
/net/hermes will refer to the corresponding directory relative to
hermes root.
The
-null map, when indicated on the command line, cancels a previous map for the directory indi-
cated. This is most useful in the /etc/auto_master
map for cancelling entries that would otherwise
be inherited from the
+auto_master include entry. To be effective, the -null
entries must be inserted
before the included map entry.
Executable Maps
Local maps that have the execute bit set in their file permissions will be executed by the automounter and
provided with a key to be looked up as an argument. The executable map is expected to return the con-
tent of an automounter map entry on its standard output or no output if the entry cannot be determined.
A direct map cannot be made executable.
Configuration and the auto_master Map
When initiated without arguments,
automount consults the master map for a list of autofs mount
points and their maps. It mounts any autofs mounts that are not already mounted, and unmounts
autofs mounts that have been removed from the master map or direct map.
The master map is assumed to be called
auto_master and its location is determined by the name ser-
vice switch policy. Normally the master map is located initially as a local file, /etc/auto_master
.
Browsing
Browsing of indirect maps allows all of the potential mount points to be visible for that map regardless of
whether they are mounted or not. The
-nobrowse option can be added to any indirect autofs
map to
disable browsing. For example:
/net -hosts -nosuid,soft,nobrowse
In this case, any host names would only be visible in /net after they are mounted. The -browse option
enables browsing of autofs file systems. This is the default for all indirect maps, although it is sug-
gested that the -hosts entry contain the -nobrowse option.
Note that, although a listing of the
autofs directory associated with an indirect map shows all potential
mountable entries, the attributes associated with those entries are temporary until the real filesystem
attributes can shown once the filesystem has been mounted.
Network Information Service (NIS) and Yellow Pages (YP)
The Network Information Service (NIS) was formerly known as Sun Yellow Pages (YP). The functionality
of the two remains the same.
RETURN VALUE
automount returns:
0 Success
1 Failure
3 Map not found
HP-UX 11i Version 2: September 2004 − 4 − Hewlett-Packard Company Section 1M−−61