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