Bell 32V development
[unix-history] / usr / man / man2 / mount.2
CommitLineData
cb67878b
TL
1.TH MOUNT 2
2.SH NAME
3mount, umount \- mount or remove file system
4.SH SYNOPSIS
5.B mount(special, name, rwflag)
6.br
7.B char *special, *name;
8.PP
9.B umount(special)
10.br
11.B char *special;
12.SH DESCRIPTION
13.I Mount
14announces to the system that a removable file system has
15been mounted on
16the block-structured special file
17.I special;
18from now on, references to file
19.I name
20will refer to
21the root file on the newly mounted file system.
22.I Special
23and
24.I name
25are pointers to null-terminated strings
26containing the appropriate path names.
27.PP
28.I Name
29must exist already.
30.I Name
31must be a directory (unless the root of the mounted file system
32is not a directory).
33Its old contents
34are inaccessible while the file system
35is mounted.
36.PP
37The
38.I rwflag
39argument determines whether
40the file system can be written on; if it is 0 writing
41is allowed, if non-zero no writing is done.
42Physically write-protected and magnetic
43tape file systems must be mounted read-only or
44errors will occur when access times are updated,
45whether or not any
46explicit write is attempted.
47.PP
48.I Umount
49announces to the system that the
50.I special
51file is no longer to contain a removable file system.
52The associated file reverts to its ordinary interpretation.
53.SH "SEE ALSO"
54mount(1)
55.SH DIAGNOSTICS
56.I Mount
57returns 0 if the action occurred; \-1 if
58.I special
59is inaccessible or not an appropriate file; if
60.I name
61does not exist; if
62.I special
63is already mounted; if
64.I name
65is in use; or if
66there are already too many
67file systems mounted.
68.PP
69.I Umount
70returns 0 if the action occurred; \-1 if
71if the special file is inaccessible or
72does not have a mounted file system,
73or if there are active files in the mounted
74file system.
75.SH BUGS
76If a file containing holes
77(unallocated blocks)
78is read, even on a file system mounted read-only,
79the system will attempt to fill in the holes
80by writing on the device.
81.SH "ASSEMBLER (PDP-11)"
82(mount = 21.)
83.br
84.B sys mount; special; name; rwflag
85.PP
86(umount = 22.)
87.br
88.B sys umount; special