Blame man/automount.8

Packit Service a4b2a9
.\" Linux man page by B. James Phillippe, 1997 <bryan@Terran.ORG>
Packit Service a4b2a9
.\"
Packit Service a4b2a9
.\" This page was written to contribute to the Linux kernel autofs
Packit Service a4b2a9
.\" implementation by H. Peter Anvin (1997).  It is loosly based on
Packit Service a4b2a9
.\" the documentation for mount(8) and amd(8) Linux manpages.
Packit Service a4b2a9
.\"
Packit Service a4b2a9
.\" This is free documentation.
Packit Service a4b2a9
.\"
Packit Service a4b2a9
.TH AUTOMOUNT 8 "12 Apr 2006"
Packit Service a4b2a9
.SH NAME
Packit Service a4b2a9
automount \- manage autofs mount points
Packit Service a4b2a9
.SH SYNOPSIS
Packit Service a4b2a9
\fBautomount\fP [\fIoptions\fP] [\fImaster_map\fP]
Packit Service a4b2a9
.SH DESCRIPTION
Packit Service a4b2a9
The \fBautomount\fP program is used to manage mount points for
Packit Service a4b2a9
autofs, the inlined Linux automounter.  \fBautomount\fP works by
Packit Service a4b2a9
reading the
Packit Service a4b2a9
.nh
Packit Service a4b2a9
.BR auto.master (5)
Packit Service a4b2a9
.hy
Packit Service a4b2a9
map and sets up mount points for each entry in the master map allowing
Packit Service a4b2a9
them to be automatically mounted when accessed. The file systems are
Packit Service a4b2a9
then automatically umounted after a period of inactivity.
Packit Service a4b2a9
.SH OPTIONS
Packit Service a4b2a9
.TP
Packit Service a4b2a9
.I "\-h, \-\-help"
Packit Service a4b2a9
Print brief help on program usage.
Packit Service a4b2a9
.TP
Packit Service a4b2a9
.I "\-p, \-\-pid-file"
Packit Service a4b2a9
Write the pid of the daemon to the specified file.
Packit Service a4b2a9
.TP
Packit Service a4b2a9
.I "\-t <seconds>, \-\-timeout <seconds>"
Packit Service a4b2a9
Set the global minimum timeout, in seconds, until directories
Packit Service a4b2a9
are unmounted. The default is 10 minutes. Setting the timeout
Packit Service a4b2a9
to zero disables umounts completely.
Packit Service a4b2a9
The internal program default is 10 minutes, but the default
Packit Service a4b2a9
installed configuration overrides this and sets the timeout
Packit Service a4b2a9
to 5 minutes to be consistent with earlier autofs releases.
Packit Service a4b2a9
.TP
Packit Service a4b2a9
.I "\-M <seconds>, \-\-master-wait <seconds>"
Packit Service a4b2a9
Set the maximum time to wait for the master map to become available
Packit Service a4b2a9
if it cannot be read at program start.
Packit Service a4b2a9
.TP
Packit Service a4b2a9
.I "\-n <seconds>, \-\-negative\-timeout <seconds>"
Packit Service a4b2a9
Set the default timeout for caching failed key lookups. The default is 60 seconds.
Packit Service a4b2a9
.TP
Packit Service a4b2a9
.I "\-v, \-\-verbose"
Packit Service a4b2a9
Enables logging of general status and progress messages for all
Packit Service a4b2a9
autofs managed mounts.
Packit Service a4b2a9
.TP
Packit Service a4b2a9
.I "\-d, \-\-debug"
Packit Service a4b2a9
Enables logging of general status and progress messages as well as
Packit Service a4b2a9
debugging messages for all autofs managed mounts.
Packit Service a4b2a9
.TP
Packit Service a4b2a9
.I "\-Dvariable=value, --define variable=value"
Packit Service a4b2a9
Define a global macro substitution variable. Global definitions
Packit Service a4b2a9
are over-ridden macro definitions of the same name specified in
Packit Service a4b2a9
mount entries.
Packit Service a4b2a9
.TP
Packit Service 59e6d5
.I \-S, \-\-systemd-service
Packit Service 59e6d5
Used when running the automounter as a systemd service to ensure log entry
Packit Service 59e6d5
format is consistent with the log entry format when running as a daemon.
Packit Service 59e6d5
.TP
Packit Service a4b2a9
.I "\-f, \-\-foreground"
Packit Service a4b2a9
Run the daemon in the foreground and log to stderr instead of syslog."
Packit Service a4b2a9
.TP
Packit Service a4b2a9
.I "\-r, \-\-random-multimount-selection"
Packit Service a4b2a9
Enables the use of random selection when choosing a host from a
Packit Service a4b2a9
list of replicated servers.
Packit Service a4b2a9
.TP
Packit Service a4b2a9
.I "\-m, \-\-dumpmaps [<map type> <map name>]"
Packit Service a4b2a9
With no parameters, list information about the configured automounter
Packit Service a4b2a9
maps, then exit.
Packit Service a4b2a9
Packit Service a4b2a9
If the dumpmaps option is given and is followed by two parameters,
Packit Service a4b2a9
"<map type> <map name>" then simple "<key, value>" pairs that would
Packit Service a4b2a9
be read in by a map read are printed to stdout if the given map type
Packit Service a4b2a9
and map name are found in the map configuration.
Packit Service a4b2a9
Packit Service a4b2a9
If the map is an LDAP map and there is more than one map of same name
Packit Service a4b2a9
in different base dns only the first map encountered by autofs will
Packit Service a4b2a9
be listed. Similarly, if the map is a file map and there is more than
Packit Service a4b2a9
one map of the same name in different directories, only the first map
Packit Service a4b2a9
encountered will be listed.
Packit Service a4b2a9
Packit Service a4b2a9
If the map type is an old style multi-map and any one of the map
Packit Service a4b2a9
names in the multi-map entry matches the given map name the entries
Packit Service a4b2a9
that would be used by autofs for the whole multi-map will be listed.
Packit Service a4b2a9
.TP
Packit Service a4b2a9
.I "\-O, \-\-global-options"
Packit Service a4b2a9
Allows the specification of global mount options used for all master
Packit Service a4b2a9
map entries. These options will either replace or be appened to options
Packit Service a4b2a9
given in a master map entry depending on the APPEND_OPTIONS configuration
Packit Service a4b2a9
setting.
Packit Service a4b2a9
.TP
Packit Service a4b2a9
.I "\-V, \-\-version"
Packit Service a4b2a9
Display the version number, then exit.
Packit Service a4b2a9
.TP
Packit Service a4b2a9
.I "\-l, \-\-set-log-priority priority path [path,...]"
Packit Service a4b2a9
Set the daemon log priority to the specified value.  Valid values include
Packit Service a4b2a9
the numbers 0-7, or the strings emerg, alert, crit, err, warning, notice,
Packit Service a4b2a9
info, or debug. Log level debug will log everything, log levels info, warn
Packit Service a4b2a9
(or warning), or notice with enable the daemon verbose logging. Any other
Packit Service a4b2a9
level will set basic logging. Note that enabling debug or verbose
Packit Service a4b2a9
logging in the autofs global configuration will override dynamic log level
Packit Service a4b2a9
changes. For example, if verbose logging is set in the configuration then
Packit Service a4b2a9
attempting to set logging to basic logging, by using alert, crit, err
Packit Service a4b2a9
or emerg won't stop the verbose logging. However, setting logging to debug
Packit Service a4b2a9
will lead to everything (debug logging) being logged witch can then also
Packit Service a4b2a9
be disabled, returning the daemon to verbose logging. This option can be
Packit Service a4b2a9
specified to change the logging priority of an already running automount
Packit Service a4b2a9
process.
Packit Service a4b2a9
.P
Packit Service a4b2a9
The \fIpath\fP argument corresponds to the automounted
Packit Service a4b2a9
path name as specified in the master map.
Packit Service a4b2a9
.TP
Packit Service a4b2a9
.I "\-C, \-\-dont-check-daemon"
Packit Service a4b2a9
Don't check if the daemon is currently running (see NOTES).
Packit Service a4b2a9
.TP
Packit Service a4b2a9
.I "\-F, \-\-force"
Packit Service a4b2a9
Force an unlink umount of existing mounts under autofs managed mount points
Packit Service a4b2a9
during startup. This can cause problems for processes with working directories
Packit Service a4b2a9
within these mounts (see NOTES).
Packit Service a4b2a9
.SH ARGUMENTS
Packit Service a4b2a9
\fBautomount\fP takes one optional argument, the name of the master map to
Packit Service a4b2a9
use.
Packit Service a4b2a9
.TP
Packit Service a4b2a9
\fBmaster_map\fP
Packit Service a4b2a9
Location for autofs master map that defines autofs managed mount points
Packit Service a4b2a9
and the mount maps they will use. The default is
Packit Service a4b2a9
.nh
Packit Service a4b2a9
\fBauto.master\fP.
Packit Service a4b2a9
.hy
Packit Service a4b2a9
.RE
Packit Service a4b2a9
.SH NOTES
Packit Service a4b2a9
If the \fBautomount\fP daemon catches a USR1 signal, it will umount all
Packit Service a4b2a9
currently unused autofs managed mounted file systems and continue running
Packit Service a4b2a9
(forced expire).  If it catches the TERM signal it will umount
Packit Service a4b2a9
all unused autofs managed mounted file systems and exit if there are
Packit Service a4b2a9
no remaining busy file systems. If autofs has been compiled with the
Packit Service a4b2a9
option to ignore busy mounts on exit it will exit leaving any busy
Packit Service a4b2a9
mounts in place otherwise busy file systems will not be umounted
Packit Service a4b2a9
and autofs will not exit.
Packit Service a4b2a9
Alternatively, if autofs has been compiled with the option to enable
Packit Service a4b2a9
forced shutdown then a USR2 signal to the daemon will cause all
Packit Service a4b2a9
mounts to be umounted and any busy mounts to be forcibly umounted,
Packit Service a4b2a9
including autofs mount point directories (summary execution). Note
Packit Service a4b2a9
that the forced umount is an unlink operation and the actual umount
Packit Service a4b2a9
will not happen in the kernel until active file handles are released.
Packit Service a4b2a9
The daemon also responds to a HUP signal which triggers an update of
Packit Service a4b2a9
the maps for each mount point.
Packit Service a4b2a9
.P
Packit Service a4b2a9
If any autofs mount point directories are busy when the daemon is sent
Packit Service a4b2a9
an exit signal the daemon will not exit. The exception to this is
Packit Service a4b2a9
if autofs has been built with configure options to either ignore busy
Packit Service a4b2a9
mounts at exit or force umount at exit. If the ignore busy mounts at
Packit Service a4b2a9
exit option is used the filesystems will be left in a catatonic
Packit Service a4b2a9
(non-functional) state and can be manually umounted when they become
Packit Service a4b2a9
unused. If the force umount at exit option is used the filesystems
Packit Service a4b2a9
will be umounted but the mount will not be released by the kernel
Packit Service a4b2a9
until they are no longer in use by the processes that held them busy.
Packit Service a4b2a9
If automount managed filesystems are found mounted when autofs is
Packit Service a4b2a9
started they will be recovered unless they are no longer present in
Packit Service a4b2a9
the map in which case they need to umounted manually.
Packit Service a4b2a9
.P
Packit Service a4b2a9
If the option to disable the check to see if the daemon is already
Packit Service a4b2a9
running is used be aware that autofs currently may not function correctly
Packit Service a4b2a9
for certain types of automount maps. The mounts of the separate daemons
Packit Service a4b2a9
might interfere with one another. The implications of running multiple
Packit Service a4b2a9
daemon instances needs to be checked and tested before we can say this
Packit Service a4b2a9
is supported.
Packit Service a4b2a9
.P
Packit Service a4b2a9
If the option to force an unlink of mounts at startup is used then processes
Packit Service a4b2a9
whose working directory is within unlinked automounted directories will not
Packit Service a4b2a9
get the correct pwd from the system. This is because, after the mount is
Packit Service a4b2a9
unlinked from the mount tree, anything that needs to walk back up the mount
Packit Service a4b2a9
tree to construct a path, such as getcwd(2) and the proc filesystem
Packit Service a4b2a9
/proc/<pid>/cwd, cannot work because the point from which the path is
Packit Service a4b2a9
constructed has been detached from the mount tree.
Packit Service a4b2a9
.SH "SEE ALSO"
Packit Service a4b2a9
.BR autofs (5),
Packit Service a4b2a9
.BR autofs (8),
Packit Service a4b2a9
.BR autofs.conf (5),
Packit Service a4b2a9
.BR auto.master (5),
Packit Service a4b2a9
.BR mount (8),
Packit Service a4b2a9
.BR autofs_ldap_auth.conf (5).
Packit Service a4b2a9
.SH BUGS
Packit Service a4b2a9
Don't know, I've fixed everything I know about.
Packit Service a4b2a9
Packit Service a4b2a9
The documentation could be better.
Packit Service a4b2a9
Packit Service a4b2a9
Please report other bugs along with a detailed description to
Packit Service a4b2a9
<autofs@vger.kernel.org>. Visit http://vger.kernel.org/vger-lists.html#autofs
Packit Service a4b2a9
for information about the list.
Packit Service a4b2a9
.SH AUTHOR
Packit Service a4b2a9
H. Peter Anvin <hpa@transmeta.com> and Ian Kent <raven@themaw.net>.