xref: /original-bsd/sbin/mount_nfs/mount_nfs.8 (revision 27393bdf)
1.\" Copyright (c) 1992, 1993, 1994, 1995
2.\"	The Regents of the University of California.  All rights reserved.
3.\"
4.\" %sccs.include.redist.roff%
5.\"
6.\"	@(#)mount_nfs.8	8.3 (Berkeley) 03/29/95
7.\"
8.Dd
9.Dt MOUNT_NFS 8
10.Os BSD 4.4
11.Sh NAME
12.Nm mount_nfs
13.Nd mount nfs file systems
14.Sh SYNOPSIS
15.Nm mount_nfs
16.Op Fl 3KPTUbcdilqs
17.Op Fl D Ar deadthresh
18.Op Fl I Ar readdirsize
19.Op Fl L Ar leaseterm
20.Op Fl R Ar retrycnt
21.Op Fl a Ar maxreadahead
22.Op Fl g Ar maxgroups
23.Op Fl m Ar realm
24.Op Fl o Ar options
25.Op Fl r Ar readsize
26.Op Fl t Ar timeout
27.Op Fl w Ar writesize
28.Op Fl x Ar retrans
29.Ar rhost:path node
30.Sh DESCRIPTION
31The
32.Nm mount_nfs
33command
34calls the
35.Xr mount 2
36system call to prepare and graft a remote nfs file system (rhost:path)
37on to the file system tree at the point
38.Ar node.
39This command is normally executed by
40.Xr mount 8 .
41It implements the mount protocol as described in RFC 1094, Appendix A and
42.%T "NFS: Network File System Version 3 Protocol Specification" ,
43Appendix I.
44.Pp
45The options are:
46.Bl -tag -width indent
47.It Fl 3
48Use the NFS Version 3 protocol (Version 2 is the default).
49.It Fl D
50Used with NQNFS to set the
51.Dq "dead server threshold"
52to the specified number of round trip timeout intervals.
53After a
54.Dq "dead server threshold"
55of retransmit timeouts,
56cached data for the unresponsive server is assumed to still be valid.
57Values may be set in the range of 1 - 9, with 9 referring to an
58.Dq "infinite dead threshold"
59(i.e. never assume cached data still valid).
60This option is not generally recommended and is really an experimental
61feature.
62.It Fl I
63Set the readdir read size to the specified value. The value should normally
64be a multiple of DIRBLKSIZ that is <= the read size for the mount.
65.It Fl K
66Pass Kerberos authenticators to the server for client-to-server
67user-credential mapping.
68This requires that the kernel be built with the NFSKERB option.
69(Refer to the INTERNET-DRAFT titled
70.%T "Authentication Mechanisms for ONC RPC" ,
71for more information.)
72.It Fl L
73Used with NQNFS to set the lease term to the specified number of seconds.
74Only use this argument for mounts with a large round trip delay.
75Values are normally in the 10-30 second range.
76.It Fl P
77Use a reserved socket port number.
78This is useful for mounting servers that require clients to use a
79reserved port number on the mistaken belief that this makes NFS
80more secure. (For the rare case where the client has a trusted root account
81but untrusworthy users and the network cables are in secure areas this does
82help, but for normal desktop clients this does not apply.)
83.It Fl R
84Set the retry count for doing the mount to the specified value.
85.It Fl T
86Use TCP transport instead of UDP.
87This is recommended for servers that are not on the same LAN cable as
88the client.
89(NB: This is NOT supported by most non-BSD servers.)
90.It Fl U
91Force the mount protocol to use UDP transport, even for TCP NFS mounts.
92(Necessary for some old BSD servers.)
93.It Fl a
94Set the read-ahead count to the specified value.
95This may be in the range of 0 - 4, and determines how many blocks
96will be read ahead when a large file is being read sequentially.
97Trying a value greater than 1 for this is suggested for
98mounts with a large bandwidth * delay product.
99.It Fl b
100If an initial attempt to contact the server fails, fork off a child to keep
101trying the mount in the background.
102Useful for
103.Xr fstab 5 ,
104where the filesystem mount is not critical to multiuser operation.
105.It Fl c
106For UDP mount points, do not do a
107.Xr connect 2 .
108This must be used for servers that do not reply to requests from the
109standard NFS port number 2049.
110.It Fl d
111Turn off the dynamic retransmit timeout estimator.
112This may be useful for UDP mounts that exhibit high retry rates,
113since it is possible that the dynamically estimated timeout interval is too
114short.
115.It Fl g
116Set the maximum size of the group list for the credentials to the
117specified value.
118This should be used for mounts on old servers that cannot handle a
119group list size of 16, as specified in RFC 1057.
120Try 8, if users in a lot of groups cannot get response from the mount
121point.
122.It Fl i
123Make the mount interruptible, which implies that file system calls that
124are delayed due to an unresponsive server will fail with EINTR when a
125termination signal is posted for the process.
126.It Fl l
127Used with NQNFS and NFSV3 to specify that the \fBReaddirPlus\fR RPC should
128be used.
129This option reduces RPC traffic for cases such as
130.Dq "ls -l" ,
131but tends to flood the attribute and name caches with prefetched entries.
132Try this option and see whether performance improves or degrades. Probably
133most useful for client to server network interconnects with a large bandwidth
134times delay product.
135.It Fl m
136Set the Kerberos realm to the string argument.
137Used with the
138.Fl K
139option for mounts to other realms.
140.It Fl o
141Options are specified with a
142.Fl o
143flag followed by a comma separated string of options.
144See the
145.Xr mount 8
146man page for possible options and their meanings.
147.It Fl q
148Use the leasing extensions to the NFS Version 3 protocol
149to maintain cache consistency.
150This protocol version 2 revision to Not Quite Nfs (NQNFS)
151is only supported by this updated release of NFS code.
152It is not backwards compatible with the version 1 NQNFS protocol
153that was part of the first release of 4.4BSD-Lite.
154To interoperate with a first release 4.4BSD-Lite NFS system you will have to
155avoid this option until you have had an oppurtunity to upgrade the NFS code
156to release 2 of 4.4BSD-Lite on all your systems.
157.It Fl r
158Set the read data size to the specified value.
159It should normally be a power of 2 greater than or equal to 1024.
160This should be used for UDP mounts when the
161.Dq "fragments dropped due to timeout"
162value is getting large while actively using a mount point.
163(Use
164.Xr netstat 1
165with the
166.Fl s
167option to see what the
168.Dq "fragments dropped due to timeout"
169value is.)
170See the
171.Fl w
172option as well.
173.It Fl s
174A soft mount, which implies that file system calls will fail
175after \fBRetry\fR round trip timeout intervals.
176.It Fl t
177Set the initial retransmit timeout to the specified value.
178May be useful for fine tuning UDP mounts over internetworks
179with high packet loss rates or an overloaded server.
180Try increasing the interval if
181.Xr nfsstat 1
182shows high retransmit rates while the file system is active or reducing the
183value if there is a low retransmit rate but long response delay observed.
184(Normally, the -d option should be specified when using this option to manually
185tune the timeout
186interval.)
187.It Fl w
188Set the write data size to the specified value.
189Ditto the comments w.r.t. the
190.Fl r
191option, but using the
192.Dq "fragments dropped due to timeout"
193value on the server instead of the client.
194Note that both the
195.Fl r
196and
197.Fl w
198options should only be used as a last ditch effort at improving performance
199when mounting servers that do not support TCP mounts.
200.It Fl x
201Set the retransmit timeout count for soft mounts to the specified value.
202.El
203.Sh SEE ALSO
204.Xr mount 2 ,
205.Xr unmount 2 ,
206.Xr fstab 5 ,
207.Xr mount 8
208.Sh BUGS
209Due to the way that Sun RPC is implemented on top of UDP (unreliable datagram)
210transport, tuning such mounts is really a black art that can only be expected
211to have limited success.
212For clients mounting servers that are not on the same
213LAN cable or that tend to be overloaded,
214TCP transport is strongly recommended,
215but unfortunately this is restricted to mostly 4.4BSD servers.
216