mount(1M) MISC. REFERENCE MANUAL PAGES mount(1M)
NAME
mount - mount remote NFS resources
SYNOPSIS
mount [ -F nfs ] [ -r ] [ -o specific_options ] [ resource
mountpoint ]
DESCRIPTION
The mount command attaches a named resource to the file sys-
tem hierarchy at the pathname location mountpoint, which
must already exist. If mountpoint has any contents prior to
the mount operation, the contents remain hidden until the
resource is once again unmounted.
If the resource is listed in the vfstab file, the command
line can specify either resource or mountpoint, and mount
will consult vfstab for more information. If the -F option
is omitted, mount will take the file system type from
vfstab.
mount maintains a table of mounted file systems in
/etc/mnttab, described in mnttab(4).
The following options are available to the mount command:
-r Mount the specified file system read-only.
-o specific_options
Specify file system specific options in a comma-
separated list of words from the list below.
rw|ro resource is mounted read-write or read-
only. The default is rw.
suid|nosuid Setuid execution allowed or disallowed.
The default is suid.
remount If a file system is mounted read-only,
remounts the file system read-write.
bg|fg If the first attempt fails, retry in the
background, or, in the foreground. The
default is fg.
retry=n The number of times to retry the mount
operation. The default is 10000.
port=n The server IP port number. The default
is NFSPORT.
grpid Create a file with its GID set to the
effective GID of the calling process.
This behavior may be overridden on a
per-directory basis by setting the set-
GID bit of the parent directory; in this
case, the GID is set to the GID of the
parent directory [see open(2) and
mkdir(2)]. Files created on file systems
Last change: NFS 1
mount(1M) MISC. REFERENCE MANUAL PAGES mount(1M)
that are not mounted with the grpid
option will obey BSD semantics; that is,
the GID is unconditionally inherited from
that of the parent directory.
rsize=n Set the read buffer size to n bytes.
wsize=n Set the write buffer size to n bytes.
timeo=n Set the NFS timeout to n tenths of a
second.
retrans=n Set the number of NFS retransmissions to
n.
soft|hard Return an error if the server does not
respond, or continue the retry request
until the server responds.
intr Allow keyboard interrupts to kill a pro-
cess that is hung while waiting for a
response on a hard-mounted file system.
secure Use a more secure protocol for NFS tran-
sactions.
noac Suppress attribute caching.
acregmin=n Hold cached attributes for at least n
seconds after file modification.
acregmax=n Hold cached attributes for no more than n
seconds after file modification.
acdirmin=n Hold cached attributes for at least n
seconds after directory update.
acdirmax=n Hold cached attributes for no more than n
seconds after directory update.
actimeo=n Set min and max times for regular files
and directories to n seconds.
NFS FILE SYSTEMS
Background vs. Foreground
File systems mounted with the bg option indicate that mount
is to retry in the background if the server's mount daemon
[mountd(1M)] does not respond. mount retries the request up
to the count specified in the retry=n option. Once the file
system is mounted, each NFS request made in the kernel waits
timeo=n tenths of a second for a response. If no response
arrives, the time-out is multiplied by 2 and the request is
retransmitted. When the number of retransmissions has
reached the number specified in the retrans=n option, a file
system mounted with the soft option returns an error on the
request; one mounted with the hard option prints a warning
message and continues to retry the request.
Read-Write vs. Read-Only
File systems that are mounted rw (read-write) should use the
hard option.
Secure File Systems
The secure option must be given if the server requires
secure mounting for the file system.
Last change: NFS 2
mount(1M) MISC. REFERENCE MANUAL PAGES mount(1M)
File Attributes
The attribute cache retains file attributes on the client.
Attributes for a file are assigned a time to be flushed. If
the file is modified before the flush time, then the flush
time is extended by the time since the last modification
(under the assumption that files that changed recently are
likely to change soon). There is a minimum and maximum
flush time extension for regular files and for directories.
Setting actimeo=n extends flush time by n seconds for both
regular files and directories.
EXAMPLES
To mount a remote file system: mount -F nfs serv:/usr/src
/usr/src
To hard mount a remote file system: mount -o hard
serv:/usr/src /usr/src
FILES
/etc/mnttab table of mounted file systems
/etc/dfs/fstypes default distributed file system type
/etc/vfstab table of automatically mounted resources
SEE ALSO
mountall(1M), mount(2), umount(2), mnttab(4).
NOTES
If the directory on which a file system is to be mounted is
a symbolic link, the file system is mounted on the directory
to which the symbolic link refers, rather than being mounted
on top of the symbolic link itself.
Last change: NFS 3