Blame README.amd-maps

Packit 8480eb
Packit 8480eb
amd map parser
Packit 8480eb
==============
Packit 8480eb
Packit 8480eb
The ability to parse amd format maps has been added to autofs.
Packit 8480eb
Packit 8480eb
How to use amd maps in autofs
Packit 8480eb
-----------------------------
Packit 8480eb
Packit 8480eb
To add amd map parsing to autofs a new "format" module has been added.
Packit 8480eb
Packit 8480eb
There are two ways to use this new map format module. First, the existing
Packit 8480eb
master map syntax can be used as described below, and second, sections that
Packit 8480eb
use the top level mount path may be added to the autofs configuration below
Packit 8480eb
the "amd" section in much the same way as is done with amd.
Packit 8480eb
Packit 8480eb
The master map entry syntax is:
Packit 8480eb
Packit 8480eb
mount-point [map-type[,format]:]map [options]
Packit 8480eb
Packit 8480eb
For amd format maps this becomes:
Packit 8480eb
Packit 8480eb
/amd/mp   file,amd:amd.mp
Packit 8480eb
Packit 8480eb
which will use file as the map source and the amd format parser for
Packit 8480eb
the map.
Packit 8480eb
Packit 8480eb
In order to use nsswitch to specify the map source an amd per-mount
Packit 8480eb
section needs to be added to the autofs configuration so autofs
Packit 8480eb
knows the master map entry is an amd format mount.
Packit 8480eb
Packit 8480eb
If an amd-per-mount section is added to the autofs configuration a
Packit 8480eb
corresponding master map entry is optional. If both are present the
Packit 8480eb
map name given in the master map entry will override a "map_name"
Packit 8480eb
option in the amd per-mount section.
Packit 8480eb
Packit 8480eb
If an amd per-mount section is used alone then not giving the "map_type"
Packit 8480eb
option will alow the use of nsswicth for map selection.
Packit 8480eb
Packit 8480eb
See below for an example of an amd per-mount configuration entry.
Packit 8480eb
Packit 8480eb
Packit 8480eb
Configuration sub-system changes
Packit 8480eb
--------------------------------
Packit 8480eb
Packit 8480eb
The configuration sub-system has changed to accommodate the amd parser.
Packit 8480eb
See autofs.conf(5) for more information on format changes.
Packit 8480eb
Packit 8480eb
The configuration is now split into system initialization only
Packit 8480eb
configuration and the daemon configuration. Previously everything was
Packit 8480eb
located in the system initialization configuration file, but now the
Packit 8480eb
configuration is located in autofs.conf in the directory the distribution
Packit 8480eb
uses for the autofs configuration.
Packit 8480eb
Packit 8480eb
There is information about what amd configuration entries can be used
Packit 8480eb
in comments of the installed configuration so that's worth a look.
Packit 8480eb
Packit 8480eb
All that's needed to add an existing amd configuration to autofs is to
Packit 8480eb
add it below the autofs configuration. Apart from changing the amd
Packit 8480eb
"[ global ]" section name to "[ amd ]" nothing else should need to be
Packit 8480eb
changed. However, quite a few amd configuration options don't have
Packit 8480eb
meaning within autofs. When these options are seen they are logged.
Packit 8480eb
Packit 8480eb
Be aware that, if the an old configuration exists and the configuration
Packit 8480eb
hasn't been updated after the installation, changes to the the old
Packit 8480eb
configuration will override changes to the new configuration because
Packit 8480eb
backward compatibility takes priority over the new implementation.
Packit 8480eb
Packit 8480eb
The amd per-mount sections have two functions, to allow per-mount
Packit 8480eb
configuration, as it does in amd, and to allow master map entries to
Packit 8480eb
avoid the need to specify the "type,format" part of the master map
Packit 8480eb
entry. This allows them to use the nsswitch map source functionality
Packit 8480eb
in the same way autofs master map entries do.
Packit 8480eb
Packit 8480eb
If amd per-mount sections are present in the autofs configuration
Packit 8480eb
their corresponding master map entries are optional. This allows
Packit 8480eb
amd maps to be used without adding incompatible entries to the autofs
Packit 8480eb
master map in shared infrastructure environments.
Packit 8480eb
Packit 8480eb
If a section for an amd mount is added below the global amd section
Packit 8480eb
using the mount point path (as is done in amd.conf) then autofs will
Packit 8480eb
know the map format is amd (it doesn't matter if there are no other
Packit 8480eb
configuration options in the mount point section).
Packit 8480eb
Packit 8480eb
If there is a corresponding master map entry the map given in the
Packit 8480eb
master map entry will be used over the map_name option if it is
Packit 8480eb
present in an amd per-mount section.
Packit 8480eb
Packit 8480eb
If a mount point is present in the master map and the source of the
Packit 8480eb
map is nis then it is sufficient to use (for example):
Packit 8480eb
Packit 8480eb
/amd/mp           amd.mp
Packit 8480eb
Packit 8480eb
in the master map and
Packit 8480eb
Packit 8480eb
automount: nis
Packit 8480eb
Packit 8480eb
in /etc/nsswitch.conf or
Packit 8480eb
Packit 8480eb
[ amd ]
Packit 8480eb
map_type = nis
Packit 8480eb
Packit 8480eb
in the configuration along with
Packit 8480eb
Packit 8480eb
[ /amd/mp ]
Packit 8480eb
Packit 8480eb
or
Packit 8480eb
Packit 8480eb
[ /amd/mp ]
Packit 8480eb
map_type = nis
Packit 8480eb
Packit 8480eb
An example of an amd per-mount configuration entry is:
Packit 8480eb
Packit 8480eb
[ amd ]
Packit 8480eb
...
Packit 8480eb
Packit 8480eb
[ /test ]
Packit 8480eb
map_name = /etc/amd.test
Packit 8480eb
#map_type = file
Packit 8480eb
#search_path =			/etc
Packit 8480eb
#browsable_dirs =		yes | no
Packit 8480eb
browsable_dirs =		yes
Packit 8480eb
Packit 8480eb
Packit 8480eb
amd map options that can be used
Packit 8480eb
--------------------------------
Packit 8480eb
Packit 8480eb
In an attempt to describe the usable amd map options, many of the amd
Packit 8480eb
map options have been added to autofs(5).
Packit 8480eb
Packit 8480eb
Not all the amd functionality has been implemented. The autofs(5) man
Packit 8480eb
page usually mentions if something hasn't been implemented so that's
Packit 8480eb
worth checking.
Packit 8480eb
Packit 8480eb
What hasn't been implemented
Packit 8480eb
----------------------------
Packit 8480eb
Packit 8480eb
The configuration options fully_qualified_hosts, unmount_on_exit and
Packit 8480eb
browsable_dirs = full (and a couple of others) aren't implemented.
Packit 8480eb
Packit 8480eb
Map types (sources) ndbm, passwd are not implemented.
Packit 8480eb
The map source "sss" can't be used for amd format maps.
Packit 8480eb
Packit 8480eb
Map caching options aren't used, the existing autofs map caching is
Packit 8480eb
always used for available map sources.
Packit 8480eb
Packit 8480eb
The regex map key matching feature is not implemented.
Packit 8480eb
Packit 8480eb
Mount types lustre, nfsx, jfs and direct haven't been implemented
Packit 8480eb
and other mount types that aren't implemented in amd are also not
Packit 8480eb
available.
Packit 8480eb
Packit 8480eb
How to find out more
Packit 8480eb
--------------------
Packit 8480eb
Packit 8480eb
Have a look at the man pages autofs.conf(5), autofs(5) and to a
Packit 8480eb
lesser extent auto.master(5). These may help.
Packit 8480eb
Packit 8480eb
But the best way to get more information is to ask on the
Packit 8480eb
autofs mailing list as described in the README file.
Packit 8480eb
Packit 8480eb
Ian