2 |
- |
1 |
.\" Copyright (c) 1992, 1993, 1994, 1995
|
|
|
2 |
.\" The Regents of the University of California. All rights reserved.
|
|
|
3 |
.\"
|
|
|
4 |
.\" Redistribution and use in source and binary forms, with or without
|
|
|
5 |
.\" modification, are permitted provided that the following conditions
|
|
|
6 |
.\" are met:
|
|
|
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.
|
|
|
19 |
.\"
|
|
|
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
|
|
|
30 |
.\" SUCH DAMAGE.
|
|
|
31 |
.\"
|
|
|
32 |
.\" @(#)mount_nfs.8 8.3 (Berkeley) 3/29/95
|
|
|
33 |
.\"
|
|
|
34 |
.\" $Id: mount_nfs.8,v 1.14 1998/07/06 07:15:53 charnier Exp $
|
|
|
35 |
.\""
|
|
|
36 |
.Dd March 29, 1995
|
|
|
37 |
.Dt MOUNT_NFS 8
|
|
|
38 |
.Os BSD 4.4
|
|
|
39 |
.Sh NAME
|
|
|
40 |
.Nm mount_nfs
|
|
|
41 |
.Nd mount nfs file systems
|
|
|
42 |
.Sh SYNOPSIS
|
|
|
43 |
.Nm mount_nfs
|
|
|
44 |
.Op Fl 23KNPTUbcdilqs
|
|
|
45 |
.Op Fl D Ar deadthresh
|
|
|
46 |
.Op Fl I Ar readdirsize
|
|
|
47 |
.Op Fl L Ar leaseterm
|
|
|
48 |
.Op Fl R Ar retrycnt
|
|
|
49 |
.Op Fl a Ar maxreadahead
|
|
|
50 |
.Op Fl g Ar maxgroups
|
|
|
51 |
.Op Fl m Ar realm
|
|
|
52 |
.Op Fl o Ar options
|
|
|
53 |
.Op Fl r Ar readsize
|
|
|
54 |
.Op Fl t Ar timeout
|
|
|
55 |
.Op Fl w Ar writesize
|
|
|
56 |
.Op Fl x Ar retrans
|
|
|
57 |
.Ar rhost:path node
|
|
|
58 |
.Sh DESCRIPTION
|
|
|
59 |
The
|
|
|
60 |
.Nm
|
|
|
61 |
command
|
|
|
62 |
calls the
|
|
|
63 |
.Xr mount 2
|
|
|
64 |
system call to prepare and graft a remote nfs file system (rhost:path)
|
|
|
65 |
on to the file system tree at the point
|
|
|
66 |
.Ar node.
|
|
|
67 |
This command is normally executed by
|
|
|
68 |
.Xr mount 8 .
|
|
|
69 |
It implements the mount protocol as described in RFC 1094, Appendix A and
|
|
|
70 |
.%T "NFS: Network File System Version 3 Protocol Specification" ,
|
|
|
71 |
Appendix I.
|
|
|
72 |
.Pp
|
|
|
73 |
The options are:
|
|
|
74 |
.Bl -tag -width indent
|
|
|
75 |
.It Fl 2
|
|
|
76 |
Use the NFS Version 2 protocol (the default is to try version 3 first
|
|
|
77 |
then version 2). Note that NFS version 2 has a file size limit of 2
|
|
|
78 |
gigabytes.
|
|
|
79 |
.It Fl 3
|
|
|
80 |
Use the NFS Version 3 protocol.
|
|
|
81 |
.It Fl D
|
|
|
82 |
Used with NQNFS to set the
|
|
|
83 |
.Dq "dead server threshold"
|
|
|
84 |
to the specified number of round trip timeout intervals.
|
|
|
85 |
After a
|
|
|
86 |
.Dq "dead server threshold"
|
|
|
87 |
of retransmit timeouts,
|
|
|
88 |
cached data for the unresponsive server is assumed to still be valid.
|
|
|
89 |
Values may be set in the range of 1 - 9, with 9 referring to an
|
|
|
90 |
.Dq "infinite dead threshold"
|
|
|
91 |
(i.e. never assume cached data still valid).
|
|
|
92 |
This option is not generally recommended and is really an experimental
|
|
|
93 |
feature.
|
|
|
94 |
.It Fl I
|
|
|
95 |
Set the readdir read size to the specified value. The value should normally
|
|
|
96 |
be a multiple of DIRBLKSIZ that is <= the read size for the mount.
|
|
|
97 |
.It Fl K
|
|
|
98 |
Pass Kerberos authenticators to the server for client-to-server
|
|
|
99 |
user-credential mapping.
|
|
|
100 |
This requires that the kernel be built with the NFSKERB option.
|
|
|
101 |
(Refer to the INTERNET-DRAFT titled
|
|
|
102 |
.%T "Authentication Mechanisms for ONC RPC" ,
|
|
|
103 |
for more information.)
|
|
|
104 |
.It Fl L
|
|
|
105 |
Used with NQNFS to set the lease term to the specified number of seconds.
|
|
|
106 |
Only use this argument for mounts with a large round trip delay.
|
|
|
107 |
Values are normally in the 10-30 second range.
|
|
|
108 |
.It Fl N
|
|
|
109 |
Do
|
|
|
110 |
.Em not
|
|
|
111 |
use a reserved socket port number (see below).
|
|
|
112 |
.It Fl P
|
|
|
113 |
Use a reserved socket port number.
|
|
|
114 |
This flag is obsolete, and only retained for compatibility reasons.
|
|
|
115 |
Reserved port numbers are used by default now.
|
|
|
116 |
This is useful for mounting servers that require clients to use a
|
|
|
117 |
reserved port number on the mistaken belief that this makes NFS
|
|
|
118 |
more secure. (For the rare case where the client has a trusted root account
|
|
|
119 |
but untrustworthy users and the network cables are in secure areas this does
|
|
|
120 |
help, but for normal desktop clients this does not apply.)
|
|
|
121 |
.It Fl R
|
|
|
122 |
Set the retry count for doing the mount to the specified value.
|
|
|
123 |
.It Fl T
|
|
|
124 |
Use TCP transport instead of UDP.
|
|
|
125 |
This is recommended for servers that are not on the same LAN cable as
|
|
|
126 |
the client.
|
|
|
127 |
(NB: This is NOT supported by most non-BSD servers.)
|
|
|
128 |
.It Fl U
|
|
|
129 |
Force the mount protocol to use UDP transport, even for TCP NFS mounts.
|
|
|
130 |
(Necessary for some old BSD servers.)
|
|
|
131 |
.It Fl a
|
|
|
132 |
Set the read-ahead count to the specified value.
|
|
|
133 |
This may be in the range of 0 - 4, and determines how many blocks
|
|
|
134 |
will be read ahead when a large file is being read sequentially.
|
|
|
135 |
Trying a value greater than 1 for this is suggested for
|
|
|
136 |
mounts with a large bandwidth * delay product.
|
|
|
137 |
.It Fl b
|
|
|
138 |
If an initial attempt to contact the server fails, fork off a child to keep
|
|
|
139 |
trying the mount in the background.
|
|
|
140 |
Useful for
|
|
|
141 |
.Xr fstab 5 ,
|
|
|
142 |
where the filesystem mount is not critical to multiuser operation.
|
|
|
143 |
.It Fl c
|
|
|
144 |
For UDP mount points, do not do a
|
|
|
145 |
.Xr connect 2 .
|
|
|
146 |
This must be used for servers that do not reply to requests from the
|
|
|
147 |
standard NFS port number 2049.
|
|
|
148 |
.It Fl d
|
|
|
149 |
Turn off the dynamic retransmit timeout estimator.
|
|
|
150 |
This may be useful for UDP mounts that exhibit high retry rates,
|
|
|
151 |
since it is possible that the dynamically estimated timeout interval is too
|
|
|
152 |
short.
|
|
|
153 |
.It Fl g
|
|
|
154 |
Set the maximum size of the group list for the credentials to the
|
|
|
155 |
specified value.
|
|
|
156 |
This should be used for mounts on old servers that cannot handle a
|
|
|
157 |
group list size of 16, as specified in RFC 1057.
|
|
|
158 |
Try 8, if users in a lot of groups cannot get response from the mount
|
|
|
159 |
point.
|
|
|
160 |
.It Fl i
|
|
|
161 |
Make the mount interruptible, which implies that file system calls that
|
|
|
162 |
are delayed due to an unresponsive server will fail with EINTR when a
|
|
|
163 |
termination signal is posted for the process.
|
|
|
164 |
.It Fl l
|
|
|
165 |
Used with NQNFS and NFSV3 to specify that the \fBReaddirPlus\fR RPC should
|
|
|
166 |
be used.
|
|
|
167 |
This option reduces RPC traffic for cases such as
|
|
|
168 |
.Dq "ls -l" ,
|
|
|
169 |
but tends to flood the attribute and name caches with prefetched entries.
|
|
|
170 |
Try this option and see whether performance improves or degrades. Probably
|
|
|
171 |
most useful for client to server network interconnects with a large bandwidth
|
|
|
172 |
times delay product.
|
|
|
173 |
.It Fl m
|
|
|
174 |
Set the Kerberos realm to the string argument.
|
|
|
175 |
Used with the
|
|
|
176 |
.Fl K
|
|
|
177 |
option for mounts to other realms.
|
|
|
178 |
.It Fl o
|
|
|
179 |
Options are specified with a
|
|
|
180 |
.Fl o
|
|
|
181 |
flag followed by a comma separated string of options.
|
|
|
182 |
See the
|
|
|
183 |
.Xr mount 8
|
|
|
184 |
man page for possible options and their meanings.
|
|
|
185 |
The following NFS specific option is also available:
|
|
|
186 |
.Bl -tag -width indent
|
|
|
187 |
.It port=<port_number>
|
|
|
188 |
Use specified port number for NFS requests.
|
|
|
189 |
The default is to query the portmapper for the NFS port.
|
|
|
190 |
.It acregmin=<seconds>
|
|
|
191 |
.It acregmax=<seconds>
|
|
|
192 |
.It acdirmin=<seconds>
|
|
|
193 |
.It acdirmax=<seconds>
|
|
|
194 |
When attributes of files are cached, a timeout calculated to determine
|
|
|
195 |
whether a given cache entry has expired. These four values determine the
|
|
|
196 |
upper and lower bounds of the timeouts for ``directory'' attributes and
|
|
|
197 |
``regular'' (ie: everything else). The default values are 3 -> 60 seconds
|
|
|
198 |
for regular files, and 30 -> 60 seconds for directories. The algorithm to
|
|
|
199 |
calculate the timeout is based on the age of the file. The older the file,
|
|
|
200 |
the longer the cache is considered valid, subject to the limits above.
|
|
|
201 |
.El
|
|
|
202 |
.Pp
|
|
|
203 |
.Bl -tag -width "dumbtimerXX"
|
|
|
204 |
\fBHistoric \&-o options\fR
|
|
|
205 |
.Pp
|
|
|
206 |
Use of these options is deprecated, they are only mentioned here for
|
|
|
207 |
compatibility with historic versions of
|
|
|
208 |
.Nm Ns .
|
|
|
209 |
.It bg
|
|
|
210 |
Same as
|
|
|
211 |
.Fl b .
|
|
|
212 |
.It conn
|
|
|
213 |
Same as not specifying
|
|
|
214 |
.Fl c .
|
|
|
215 |
.It dumbtimer
|
|
|
216 |
Same as
|
|
|
217 |
.Fl d .
|
|
|
218 |
.It intr
|
|
|
219 |
Same as
|
|
|
220 |
.Fl i .
|
|
|
221 |
.It kerb
|
|
|
222 |
Same as
|
|
|
223 |
.Fl K .
|
|
|
224 |
.It nfsv2
|
|
|
225 |
Same as
|
|
|
226 |
.Fl 2 .
|
|
|
227 |
.It nfsv3
|
|
|
228 |
Same as
|
|
|
229 |
.Fl 3 .
|
|
|
230 |
.It rdirplus
|
|
|
231 |
Same as
|
|
|
232 |
.Fl l .
|
|
|
233 |
.It mntudp
|
|
|
234 |
Same as
|
|
|
235 |
.Fl U .
|
|
|
236 |
.It resvport
|
|
|
237 |
Same as
|
|
|
238 |
.Fl P .
|
|
|
239 |
.It seqpacket
|
|
|
240 |
Same as
|
|
|
241 |
.Fl p .
|
|
|
242 |
.It nqnfs
|
|
|
243 |
Same as
|
|
|
244 |
.Fl q .
|
|
|
245 |
.It soft
|
|
|
246 |
Same as
|
|
|
247 |
.Fl s .
|
|
|
248 |
.It tcp
|
|
|
249 |
Same as
|
|
|
250 |
.Fl T.
|
|
|
251 |
.El
|
|
|
252 |
.It Fl q
|
|
|
253 |
Use the leasing extensions to the NFS Version 3 protocol
|
|
|
254 |
to maintain cache consistency.
|
|
|
255 |
This protocol Version 2, referred to as Not Quite Nfs (NQNFS),
|
|
|
256 |
is only supported by this updated release of NFS code.
|
|
|
257 |
(It is not backwards compatible with the release of NQNFS that went out on
|
|
|
258 |
4.4BSD-Lite. To interoperate with a 4.4BSD-Lite NFS system you will have to
|
|
|
259 |
avoid this option until you have had an opportunity to upgrade the NFS code
|
|
|
260 |
on all your 4.4BSD-Lite based systems.)
|
|
|
261 |
.It Fl r
|
|
|
262 |
Set the read data size to the specified value.
|
|
|
263 |
It should normally be a power of 2 greater than or equal to 1024.
|
|
|
264 |
This should be used for UDP mounts when the
|
|
|
265 |
.Dq "fragments dropped due to timeout"
|
|
|
266 |
value is getting large while actively using a mount point.
|
|
|
267 |
(Use
|
|
|
268 |
.Xr netstat 1
|
|
|
269 |
with the
|
|
|
270 |
.Fl s
|
|
|
271 |
option to see what the
|
|
|
272 |
.Dq "fragments dropped due to timeout"
|
|
|
273 |
value is.)
|
|
|
274 |
See the
|
|
|
275 |
.Fl w
|
|
|
276 |
option as well.
|
|
|
277 |
.It Fl s
|
|
|
278 |
A soft mount, which implies that file system calls will fail
|
|
|
279 |
after \fBRetry\fR round trip timeout intervals.
|
|
|
280 |
.It Fl t
|
|
|
281 |
Set the initial retransmit timeout to the specified value.
|
|
|
282 |
May be useful for fine tuning UDP mounts over internetworks
|
|
|
283 |
with high packet loss rates or an overloaded server.
|
|
|
284 |
Try increasing the interval if
|
|
|
285 |
.Xr nfsstat 1
|
|
|
286 |
shows high retransmit rates while the file system is active or reducing the
|
|
|
287 |
value if there is a low retransmit rate but long response delay observed.
|
|
|
288 |
(Normally, the -d option should be specified when using this option to manually
|
|
|
289 |
tune the timeout
|
|
|
290 |
interval.)
|
|
|
291 |
.It Fl w
|
|
|
292 |
Set the write data size to the specified value.
|
|
|
293 |
Ditto the comments w.r.t. the
|
|
|
294 |
.Fl r
|
|
|
295 |
option, but using the
|
|
|
296 |
.Dq "fragments dropped due to timeout"
|
|
|
297 |
value on the server instead of the client.
|
|
|
298 |
Note that both the
|
|
|
299 |
.Fl r
|
|
|
300 |
and
|
|
|
301 |
.Fl w
|
|
|
302 |
options should only be used as a last ditch effort at improving performance
|
|
|
303 |
when mounting servers that do not support TCP mounts.
|
|
|
304 |
.It Fl x
|
|
|
305 |
Set the retransmit timeout count for soft mounts to the specified value.
|
|
|
306 |
.El
|
|
|
307 |
.Sh SEE ALSO
|
|
|
308 |
.Xr mount 2 ,
|
|
|
309 |
.Xr unmount 2 ,
|
|
|
310 |
.Xr fstab 5 ,
|
|
|
311 |
.Xr mount 8
|
|
|
312 |
.Sh BUGS
|
|
|
313 |
Due to the way that Sun RPC is implemented on top of UDP (unreliable datagram)
|
|
|
314 |
transport, tuning such mounts is really a black art that can only be expected
|
|
|
315 |
to have limited success.
|
|
|
316 |
For clients mounting servers that are not on the same
|
|
|
317 |
LAN cable or that tend to be overloaded,
|
|
|
318 |
TCP transport is strongly recommended,
|
|
|
319 |
but unfortunately this is restricted to mostly 4.4BSD servers.
|