To include the contents of an AutoFS map in another AutoFS
map, add a plus (+) sign before the map name, as in the following
example:
# /etc/auto_home file # local mount point mount options remote server:directory basil -nosuid basil:/export/home/basil +auto_home |
Suppose /etc/auto_home map is listed in the master map with the following
line:
If a user logs in whose home directory is in /home/basil, AutoFS mounts the directory, /export/home/basil from the host, basil.
If a user logs in whose home directory is in /home/sage, /home/thyme, or any subdirectory of /home other than basil, AutoFS consults the auto_home map for information on mounting the user’s
home directory.
The plus (+) sign instructs AutoFS to look up a different
map for the information it needs to mount the directory. If the
map name following the plus sign begins with a slash, AutoFS assumes
that it is a local file. If the map name contains no slashes, AutoFS
uses the Name Service Switch to determine whether it is a file,
NIS map, or an LDAP map.
You can include an AutoFS map inside a local file, but not
inside an NIS or LDAP map.
For more information, see automount (1M) or nsswitch.conf (4).