]> git.ipfire.org Git - thirdparty/util-linux.git/blame - mount/umount.8
Imported from util-linux-2.10s tarball.
[thirdparty/util-linux.git] / mount / umount.8
CommitLineData
fd6b7a7f
KZ
1.\" Copyright (c) 1996 Andries Brouwer
2.\" This page is somewhat derived from a page that was
3.\" (c) 1980, 1989, 1991 The Regents of the University of California
4.\" and had been heavily modified by Rik Faith and myself.
5.\"
6.\" This is free documentation; you can redistribute it and/or
7.\" modify it under the terms of the GNU General Public License as
8.\" published by the Free Software Foundation; either version 2 of
9.\" the License, or (at your option) any later version.
10.\"
11.\" The GNU General Public License's references to "object code"
12.\" and "executables" are to be interpreted as the output of any
13.\" document formatting or typesetting system, including
14.\" intermediate and printed output.
15.\"
16.\" This manual is distributed in the hope that it will be useful,
17.\" but WITHOUT ANY WARRANTY; without even the implied warranty of
18.\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19.\" GNU General Public License for more details.
20.\"
21.\" You should have received a copy of the GNU General Public
22.\" License along with this manual; if not, write to the Free
23.\" Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139,
24.\" USA.
25.\"
26.TH UMOUNT 8 "26 July 1997" "Linux 2.0" "Linux Programmer's Manual"
27.SH NAME
28umount \- unmount file systems
29.SH SYNOPSIS
30.BI "umount [\-hV]"
31.LP
32.BI "umount -a [\-nrv] [\-t " vfstype ]
33.br
34.BI "umount [\-nrv] " "device " | " dir " [...]
35.SH DESCRIPTION
36The
37.B umount
38command detaches the file system(s) mentioned from the file hierarchy.
39A file system is specified either by giving the directory where it
40has been mounted, or by giving the special device on which it lives.
41
42Note that a file system cannot be unmounted when it is `busy' -
43for example, when there are open files on it, or when some process
44has its working directory there, or when a swap file on it is in use.
45The offending process could even be
46.B umount
47itself - it opens libc, and libc in its turn may open for example
48locale files.
49
50Options for the
51.B umount
52command:
53.TP
54.B \-V
55Print version and exit.
56.TP
57.B \-h
58Print help message and exit.
59.TP
60.B \-v
61Verbose mode.
62.TP
63.B \-n
64Unmount without writing in
65.IR /etc/mtab .
66.TP
67.B \-r
68In case unmounting fails, try to remount read-only.
69.TP
66ee8158
KZ
70.B \-d
71In case the unmounted device was a loop device, also
72free this loop device.
73.TP
fd6b7a7f
KZ
74.B \-a
75All of the file systems described in
76.I /etc/mtab
77are unmounted. (With
78.B umount
79version 2.7 and later: the
80.I proc
81filesystem is not unmounted.)
82.TP
83.BI \-t " vfstype"
84Indicate that the actions should only be taken on file systems of the
85specified type. More than one type may be specified in a comma separated
86list. The list of file system types can be prefixed with
87.B no
88to specify the file system types on which no action should be taken.
7eda085c
KZ
89.TP
90.B \-f
91Force unmount (in case of an unreachable NFS system).
92(Requires kernel 2.1.116 or later.)
fd6b7a7f
KZ
93
94.SH "THE LOOP DEVICE"
95The
96.B umount
97command will free the loop device (if any) associated
98with the mount, in case it finds the option `loop=...' in
66ee8158
KZ
99.IR /etc/mtab ,
100or when the \-d option was given.
fd6b7a7f
KZ
101Any pending loop devices can be freed using `losetup -d', see
102.BR losetup (8).
103
104
105.SH FILES
106.I /etc/mtab
107table of mounted file systems
108
109.SH "SEE ALSO"
110.BR umount (2),
111.BR mount (8),
112.BR losetup (8).
113
114.SH HISTORY
115A
116.B umount
117command appeared in Version 6 AT&T UNIX.