1 .\" Copyright (c) 1980, 1989, 1991, 1993
2 .\" The Regents of the University of California. All rights reserved.
4 .\" Redistribution and use in source and binary forms, with or without
5 .\" modification, are permitted provided that the following conditions
7 .\" 1. Redistributions of source code must retain the above copyright
8 .\" notice, this list of conditions and the following disclaimer.
9 .\" 2. Redistributions in binary form must reproduce the above copyright
10 .\" notice, this list of conditions and the following disclaimer in the
11 .\" documentation and/or other materials provided with the distribution.
12 .\" 3. All advertising materials mentioning features or use of this software
13 .\" must display the following acknowledgement:
14 .\" This product includes software developed by the University of
15 .\" California, Berkeley and its contributors.
16 .\" 4. Neither the name of the University nor the names of its contributors
17 .\" may be used to endorse or promote products derived from this software
18 .\" without specific prior written permission.
20 .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
21 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
22 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
23 .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
24 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
25 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
26 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
27 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
28 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
29 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
32 .\" @(#)mount.8 8.8 (Berkeley) 6/16/94
40 .Nd mount file systems
44 .Op Fl t Ar ufs | external_type
51 .Op Fl t Ar ufs | external_type
59 system call to prepare and graft a
61 or the remote node (rhost:path) on to the file system tree at the point
67 are not provided, the appropriate information is taken from the
71 The system maintains a list of currently mounted file systems.
72 If no arguments are given to
76 The options are as follows:
77 .Bl -tag -width indent
79 All the filesystems described in
82 Exceptions are those marked as
86 flag (see below), or if they are already mounted (except the
87 root filesystem which is always remounted to preserve
88 traditional single user mode behavior).
90 Causes everything to be done except for the actual system call.
91 This option is useful in conjunction with the
96 command is trying to do.
98 Forces the revocation of write access when trying to downgrade
99 a filesystem mount status from read-write to read-only.
101 forces the R/W mount of an unclean filesystem (dangerous; use with
104 Options are specified with a
106 flag followed by a comma separated string of options.
107 In case of conflicting options being specified, the rightmost option
109 The following options are available:
110 .Bl -tag -width indent
114 to the file system should be done asynchronously.
118 and should not be used unless you are prepared to recreate the file
119 system should your system crash.
123 flag, this is the same as specifying the options currently in effect for
124 the mounted filesystem.
128 forces the revocation of write access when trying to downgrade
129 a filesystem mount status from read-write to read-only.
131 forces the R/W mount of an unclean filesystem (dangerous; use with caution).
135 flag, this is the same as specifying all the options listed in the
137 file for the filesystem.
139 Metadata I/O should be done synchronously, while data I/O should be done
143 Do not update the file access time when reading from a file.
145 is useful on filesystems where there are large numbers of files and
146 performance is more critical than updating the file access time (which is
147 rarely ever important).
148 This option is currently only supported on local filesystems.
150 This filesystem should be skipped when
156 Disable read clustering.
158 Disable write clustering.
160 Do not interpret character or block special devices on the file system.
161 This option is useful for a server that has file systems containing
162 special devices for architectures other than its own.
164 Do not allow execution of any binaries on the mounted file system.
165 This option is useful for a server that has file systems containing
166 binaries for architectures other than its own.
168 Do not allow set-user-identifier or set-group-identifier bits to take effect.
169 Note: this option is worthless if a public available suid or sgid
172 is installed on your system.
174 Do not follow symlinks
175 on the mounted file system.
179 mount the file system read-only (even the super-user may not write it).
183 to the file system should be done synchronously.
185 A directory on the mounted filesystem will respond to the SUID bit
186 being set, by setting the owner of any new files to be the same
187 as the owner of the directory.
188 New directories will inherit the bit from their parents.
189 Execute bits are removed from
190 the file, and it will not be given to root.
192 This feature is designed for use on fileservers serving PC users via
193 ftp, SAMBA, or netatalk.
194 It provides security holes for shell users and as
195 such should not be used on shell machines, especially on home directories.
196 This option requires the SUIDDIR
197 option in the kernel to work.
198 Only UFS filesystems support this option.
201 for more information.
205 indicate that the status of an already mounted file system should be changed.
207 Causes the namespace at the mount point to appear as the union
208 of the mounted filesystem root and the existing directory.
209 Lookups will be done in the mounted filesystem first.
210 If those operations fail due to a non-existent file the underlying
211 directory is then accessed.
212 All creates are done in the mounted filesystem.
215 Any additional options specific to a filesystem type that is not
216 one of the internally known types (see the
218 option) may be passed as a comma separated list; these options are
219 distinguished by a leading
222 Options that take a value are specified using the syntax -option=value.
226 .Bd -literal -offset indent
227 mount -t unionfs -o -b /sys $HOME/sys
232 to execute the equivalent of:
233 .Bd -literal -offset indent
234 /sbin/mount_unionfs -b /sys $HOME/sys
237 Additional options specific to filesystem types
238 which are not internally known
239 (see the description of the
242 may be described in the manual pages for the associated
243 .Pa /sbin/mount_ Ns Sy XXX
246 Print mount information in
253 The file system is to be mounted read-only.
254 Mount the file system read-only (even the super-user may not write it).
260 .It Fl t Ar ufs | external_type
261 The argument following the
263 is used to indicate the file system type.
270 to indicate that the actions should only be taken on
271 filesystems of the specified type.
272 More than one type may be specified in a comma separated list.
273 The list of filesystem types can be prefixed with
275 to specify the filesystem types for which action should
281 .Bd -literal -offset indent
282 mount -a -t nonfs,nullfs
285 mounts all filesystems except those of type
290 If the type is not one of the internally known types,
292 will attempt to execute a program in
293 .Pa /sbin/mount_ Ns Sy XXX
296 is replaced by the type name.
297 For example, nfs filesystems are mounted by the program
298 .Pa /sbin/mount_nfs .
300 Most filesystems will be dynamically loaded by their
303 if not already present in the kernel, using the
306 Because this mechanism requires writable temporary space,
307 the filesystem type containing
309 must be compiled into the kernel, and the filesystems containing
315 before any filesystems which might be dynamically loaded.
319 flag indicates that the status of an already mounted file
320 system should be changed.
321 Any of the options discussed above (the
325 also a file system can be changed from read-only to read-write
327 An attempt to change from read-write to read-only will fail if any
328 files on the filesystem are currently open for writing unless the
330 flag is also specified.
331 The set of options is determined by applying the options specified
334 and finally applying the
342 The file system object is to be read and write.
345 Various, most of them are self-explanatory.
347 .Dl XXXXX filesystem is not available
349 The kernel does not support the respective filesystem type.
351 support for a particular filesystem might be provided either on a static
352 (kernel compile-time), or dynamic basis (loaded as a kernel module by
356 or its subprocesses attempt to dynamically load a filesystem module if
357 it has not been configured statically, using
359 In this case, the above error message can also mean that you did not
360 have permission to load the module.
362 .Bl -tag -width /etc/fstab -compact
374 .Xr mount_fdescfs 8 ,
376 .Xr mount_linprocfs 8 ,
377 .Xr mount_msdosfs 8 ,
382 .Xr mount_portalfs 8 ,
386 .Xr mount_unionfs 8 ,
389 It is possible for a corrupted file system to cause a crash.
393 the permissions on the original mount point determine if
395 is accessible from the mounted file system.
396 The minimum permissions for
397 the mount point for traversal across the mount point in both
398 directions to be possible for all users is 0111 (execute for all).