1*14414594SDavid du Colombier.\" Copyright (c) 1992, 1993, 1994, 1995 2*14414594SDavid du Colombier.\" The Regents of the University of California. All rights reserved. 3*14414594SDavid du Colombier.\" 4*14414594SDavid du Colombier.\" Redistribution and use in source and binary forms, with or without 5*14414594SDavid du Colombier.\" modification, are permitted provided that the following conditions 6*14414594SDavid du Colombier.\" are met: 7*14414594SDavid du Colombier.\" 1. Redistributions of source code must retain the above copyright 8*14414594SDavid du Colombier.\" notice, this list of conditions and the following disclaimer. 9*14414594SDavid du Colombier.\" 2. Redistributions in binary form must reproduce the above copyright 10*14414594SDavid du Colombier.\" notice, this list of conditions and the following disclaimer in the 11*14414594SDavid du Colombier.\" documentation and/or other materials provided with the distribution. 12*14414594SDavid du Colombier.\" 3. All advertising materials mentioning features or use of this software 13*14414594SDavid du Colombier.\" must display the following acknowledgement: 14*14414594SDavid du Colombier.\" This product includes software developed by the University of 15*14414594SDavid du Colombier.\" California, Berkeley and its contributors. 16*14414594SDavid du Colombier.\" 4. Neither the name of the University nor the names of its contributors 17*14414594SDavid du Colombier.\" may be used to endorse or promote products derived from this software 18*14414594SDavid du Colombier.\" without specific prior written permission. 19*14414594SDavid du Colombier.\" 20*14414594SDavid du Colombier.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 21*14414594SDavid du Colombier.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 22*14414594SDavid du Colombier.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 23*14414594SDavid du Colombier.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 24*14414594SDavid du Colombier.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 25*14414594SDavid du Colombier.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 26*14414594SDavid du Colombier.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 27*14414594SDavid du Colombier.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 28*14414594SDavid du Colombier.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 29*14414594SDavid du Colombier.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 30*14414594SDavid du Colombier.\" SUCH DAMAGE. 31*14414594SDavid du Colombier.\" 32*14414594SDavid du Colombier.\" @(#)mount_nfs.8 8.3 (Berkeley) 3/29/95 33*14414594SDavid du Colombier.\" 34*14414594SDavid du Colombier.\" $Id: mount_nfs.8,v 1.14 1998/07/06 07:15:53 charnier Exp $ 35*14414594SDavid du Colombier.\"" 36*14414594SDavid du Colombier.Dd March 29, 1995 37*14414594SDavid du Colombier.Dt MOUNT_NFS 8 38*14414594SDavid du Colombier.Os BSD 4.4 39*14414594SDavid du Colombier.Sh NAME 40*14414594SDavid du Colombier.Nm mount_nfs 41*14414594SDavid du Colombier.Nd mount nfs file systems 42*14414594SDavid du Colombier.Sh SYNOPSIS 43*14414594SDavid du Colombier.Nm mount_nfs 44*14414594SDavid du Colombier.Op Fl 23KNPTUbcdilqs 45*14414594SDavid du Colombier.Op Fl D Ar deadthresh 46*14414594SDavid du Colombier.Op Fl I Ar readdirsize 47*14414594SDavid du Colombier.Op Fl L Ar leaseterm 48*14414594SDavid du Colombier.Op Fl R Ar retrycnt 49*14414594SDavid du Colombier.Op Fl a Ar maxreadahead 50*14414594SDavid du Colombier.Op Fl g Ar maxgroups 51*14414594SDavid du Colombier.Op Fl m Ar realm 52*14414594SDavid du Colombier.Op Fl o Ar options 53*14414594SDavid du Colombier.Op Fl r Ar readsize 54*14414594SDavid du Colombier.Op Fl t Ar timeout 55*14414594SDavid du Colombier.Op Fl w Ar writesize 56*14414594SDavid du Colombier.Op Fl x Ar retrans 57*14414594SDavid du Colombier.Ar rhost:path node 58*14414594SDavid du Colombier.Sh DESCRIPTION 59*14414594SDavid du ColombierThe 60*14414594SDavid du Colombier.Nm 61*14414594SDavid du Colombiercommand 62*14414594SDavid du Colombiercalls the 63*14414594SDavid du Colombier.Xr mount 2 64*14414594SDavid du Colombiersystem call to prepare and graft a remote nfs file system (rhost:path) 65*14414594SDavid du Colombieron to the file system tree at the point 66*14414594SDavid du Colombier.Ar node. 67*14414594SDavid du ColombierThis command is normally executed by 68*14414594SDavid du Colombier.Xr mount 8 . 69*14414594SDavid du ColombierIt implements the mount protocol as described in RFC 1094, Appendix A and 70*14414594SDavid du Colombier.%T "NFS: Network File System Version 3 Protocol Specification" , 71*14414594SDavid du ColombierAppendix I. 72*14414594SDavid du Colombier.Pp 73*14414594SDavid du ColombierThe options are: 74*14414594SDavid du Colombier.Bl -tag -width indent 75*14414594SDavid du Colombier.It Fl 2 76*14414594SDavid du ColombierUse the NFS Version 2 protocol (the default is to try version 3 first 77*14414594SDavid du Colombierthen version 2). Note that NFS version 2 has a file size limit of 2 78*14414594SDavid du Colombiergigabytes. 79*14414594SDavid du Colombier.It Fl 3 80*14414594SDavid du ColombierUse the NFS Version 3 protocol. 81*14414594SDavid du Colombier.It Fl D 82*14414594SDavid du ColombierUsed with NQNFS to set the 83*14414594SDavid du Colombier.Dq "dead server threshold" 84*14414594SDavid du Colombierto the specified number of round trip timeout intervals. 85*14414594SDavid du ColombierAfter a 86*14414594SDavid du Colombier.Dq "dead server threshold" 87*14414594SDavid du Colombierof retransmit timeouts, 88*14414594SDavid du Colombiercached data for the unresponsive server is assumed to still be valid. 89*14414594SDavid du ColombierValues may be set in the range of 1 - 9, with 9 referring to an 90*14414594SDavid du Colombier.Dq "infinite dead threshold" 91*14414594SDavid du Colombier(i.e. never assume cached data still valid). 92*14414594SDavid du ColombierThis option is not generally recommended and is really an experimental 93*14414594SDavid du Colombierfeature. 94*14414594SDavid du Colombier.It Fl I 95*14414594SDavid du ColombierSet the readdir read size to the specified value. The value should normally 96*14414594SDavid du Colombierbe a multiple of DIRBLKSIZ that is <= the read size for the mount. 97*14414594SDavid du Colombier.It Fl K 98*14414594SDavid du ColombierPass Kerberos authenticators to the server for client-to-server 99*14414594SDavid du Colombieruser-credential mapping. 100*14414594SDavid du ColombierThis requires that the kernel be built with the NFSKERB option. 101*14414594SDavid du Colombier(Refer to the INTERNET-DRAFT titled 102*14414594SDavid du Colombier.%T "Authentication Mechanisms for ONC RPC" , 103*14414594SDavid du Colombierfor more information.) 104*14414594SDavid du Colombier.It Fl L 105*14414594SDavid du ColombierUsed with NQNFS to set the lease term to the specified number of seconds. 106*14414594SDavid du ColombierOnly use this argument for mounts with a large round trip delay. 107*14414594SDavid du ColombierValues are normally in the 10-30 second range. 108*14414594SDavid du Colombier.It Fl N 109*14414594SDavid du ColombierDo 110*14414594SDavid du Colombier.Em not 111*14414594SDavid du Colombieruse a reserved socket port number (see below). 112*14414594SDavid du Colombier.It Fl P 113*14414594SDavid du ColombierUse a reserved socket port number. 114*14414594SDavid du ColombierThis flag is obsolete, and only retained for compatibility reasons. 115*14414594SDavid du ColombierReserved port numbers are used by default now. 116*14414594SDavid du ColombierThis is useful for mounting servers that require clients to use a 117*14414594SDavid du Colombierreserved port number on the mistaken belief that this makes NFS 118*14414594SDavid du Colombiermore secure. (For the rare case where the client has a trusted root account 119*14414594SDavid du Colombierbut untrustworthy users and the network cables are in secure areas this does 120*14414594SDavid du Colombierhelp, but for normal desktop clients this does not apply.) 121*14414594SDavid du Colombier.It Fl R 122*14414594SDavid du ColombierSet the retry count for doing the mount to the specified value. 123*14414594SDavid du Colombier.It Fl T 124*14414594SDavid du ColombierUse TCP transport instead of UDP. 125*14414594SDavid du ColombierThis is recommended for servers that are not on the same LAN cable as 126*14414594SDavid du Colombierthe client. 127*14414594SDavid du Colombier(NB: This is NOT supported by most non-BSD servers.) 128*14414594SDavid du Colombier.It Fl U 129*14414594SDavid du ColombierForce the mount protocol to use UDP transport, even for TCP NFS mounts. 130*14414594SDavid du Colombier(Necessary for some old BSD servers.) 131*14414594SDavid du Colombier.It Fl a 132*14414594SDavid du ColombierSet the read-ahead count to the specified value. 133*14414594SDavid du ColombierThis may be in the range of 0 - 4, and determines how many blocks 134*14414594SDavid du Colombierwill be read ahead when a large file is being read sequentially. 135*14414594SDavid du ColombierTrying a value greater than 1 for this is suggested for 136*14414594SDavid du Colombiermounts with a large bandwidth * delay product. 137*14414594SDavid du Colombier.It Fl b 138*14414594SDavid du ColombierIf an initial attempt to contact the server fails, fork off a child to keep 139*14414594SDavid du Colombiertrying the mount in the background. 140*14414594SDavid du ColombierUseful for 141*14414594SDavid du Colombier.Xr fstab 5 , 142*14414594SDavid du Colombierwhere the filesystem mount is not critical to multiuser operation. 143*14414594SDavid du Colombier.It Fl c 144*14414594SDavid du ColombierFor UDP mount points, do not do a 145*14414594SDavid du Colombier.Xr connect 2 . 146*14414594SDavid du ColombierThis must be used for servers that do not reply to requests from the 147*14414594SDavid du Colombierstandard NFS port number 2049. 148*14414594SDavid du Colombier.It Fl d 149*14414594SDavid du ColombierTurn off the dynamic retransmit timeout estimator. 150*14414594SDavid du ColombierThis may be useful for UDP mounts that exhibit high retry rates, 151*14414594SDavid du Colombiersince it is possible that the dynamically estimated timeout interval is too 152*14414594SDavid du Colombiershort. 153*14414594SDavid du Colombier.It Fl g 154*14414594SDavid du ColombierSet the maximum size of the group list for the credentials to the 155*14414594SDavid du Colombierspecified value. 156*14414594SDavid du ColombierThis should be used for mounts on old servers that cannot handle a 157*14414594SDavid du Colombiergroup list size of 16, as specified in RFC 1057. 158*14414594SDavid du ColombierTry 8, if users in a lot of groups cannot get response from the mount 159*14414594SDavid du Colombierpoint. 160*14414594SDavid du Colombier.It Fl i 161*14414594SDavid du ColombierMake the mount interruptible, which implies that file system calls that 162*14414594SDavid du Colombierare delayed due to an unresponsive server will fail with EINTR when a 163*14414594SDavid du Colombiertermination signal is posted for the process. 164*14414594SDavid du Colombier.It Fl l 165*14414594SDavid du ColombierUsed with NQNFS and NFSV3 to specify that the \fBReaddirPlus\fR RPC should 166*14414594SDavid du Colombierbe used. 167*14414594SDavid du ColombierThis option reduces RPC traffic for cases such as 168*14414594SDavid du Colombier.Dq "ls -l" , 169*14414594SDavid du Colombierbut tends to flood the attribute and name caches with prefetched entries. 170*14414594SDavid du ColombierTry this option and see whether performance improves or degrades. Probably 171*14414594SDavid du Colombiermost useful for client to server network interconnects with a large bandwidth 172*14414594SDavid du Colombiertimes delay product. 173*14414594SDavid du Colombier.It Fl m 174*14414594SDavid du ColombierSet the Kerberos realm to the string argument. 175*14414594SDavid du ColombierUsed with the 176*14414594SDavid du Colombier.Fl K 177*14414594SDavid du Colombieroption for mounts to other realms. 178*14414594SDavid du Colombier.It Fl o 179*14414594SDavid du ColombierOptions are specified with a 180*14414594SDavid du Colombier.Fl o 181*14414594SDavid du Colombierflag followed by a comma separated string of options. 182*14414594SDavid du ColombierSee the 183*14414594SDavid du Colombier.Xr mount 8 184*14414594SDavid du Colombierman page for possible options and their meanings. 185*14414594SDavid du ColombierThe following NFS specific option is also available: 186*14414594SDavid du Colombier.Bl -tag -width indent 187*14414594SDavid du Colombier.It port=<port_number> 188*14414594SDavid du ColombierUse specified port number for NFS requests. 189*14414594SDavid du ColombierThe default is to query the portmapper for the NFS port. 190*14414594SDavid du Colombier.It acregmin=<seconds> 191*14414594SDavid du Colombier.It acregmax=<seconds> 192*14414594SDavid du Colombier.It acdirmin=<seconds> 193*14414594SDavid du Colombier.It acdirmax=<seconds> 194*14414594SDavid du ColombierWhen attributes of files are cached, a timeout calculated to determine 195*14414594SDavid du Colombierwhether a given cache entry has expired. These four values determine the 196*14414594SDavid du Colombierupper and lower bounds of the timeouts for ``directory'' attributes and 197*14414594SDavid du Colombier``regular'' (ie: everything else). The default values are 3 -> 60 seconds 198*14414594SDavid du Colombierfor regular files, and 30 -> 60 seconds for directories. The algorithm to 199*14414594SDavid du Colombiercalculate the timeout is based on the age of the file. The older the file, 200*14414594SDavid du Colombierthe longer the cache is considered valid, subject to the limits above. 201*14414594SDavid du Colombier.El 202*14414594SDavid du Colombier.Pp 203*14414594SDavid du Colombier.Bl -tag -width "dumbtimerXX" 204*14414594SDavid du Colombier\fBHistoric \&-o options\fR 205*14414594SDavid du Colombier.Pp 206*14414594SDavid du ColombierUse of these options is deprecated, they are only mentioned here for 207*14414594SDavid du Colombiercompatibility with historic versions of 208*14414594SDavid du Colombier.Nm Ns . 209*14414594SDavid du Colombier.It bg 210*14414594SDavid du ColombierSame as 211*14414594SDavid du Colombier.Fl b . 212*14414594SDavid du Colombier.It conn 213*14414594SDavid du ColombierSame as not specifying 214*14414594SDavid du Colombier.Fl c . 215*14414594SDavid du Colombier.It dumbtimer 216*14414594SDavid du ColombierSame as 217*14414594SDavid du Colombier.Fl d . 218*14414594SDavid du Colombier.It intr 219*14414594SDavid du ColombierSame as 220*14414594SDavid du Colombier.Fl i . 221*14414594SDavid du Colombier.It kerb 222*14414594SDavid du ColombierSame as 223*14414594SDavid du Colombier.Fl K . 224*14414594SDavid du Colombier.It nfsv2 225*14414594SDavid du ColombierSame as 226*14414594SDavid du Colombier.Fl 2 . 227*14414594SDavid du Colombier.It nfsv3 228*14414594SDavid du ColombierSame as 229*14414594SDavid du Colombier.Fl 3 . 230*14414594SDavid du Colombier.It rdirplus 231*14414594SDavid du ColombierSame as 232*14414594SDavid du Colombier.Fl l . 233*14414594SDavid du Colombier.It mntudp 234*14414594SDavid du ColombierSame as 235*14414594SDavid du Colombier.Fl U . 236*14414594SDavid du Colombier.It resvport 237*14414594SDavid du ColombierSame as 238*14414594SDavid du Colombier.Fl P . 239*14414594SDavid du Colombier.It seqpacket 240*14414594SDavid du ColombierSame as 241*14414594SDavid du Colombier.Fl p . 242*14414594SDavid du Colombier.It nqnfs 243*14414594SDavid du ColombierSame as 244*14414594SDavid du Colombier.Fl q . 245*14414594SDavid du Colombier.It soft 246*14414594SDavid du ColombierSame as 247*14414594SDavid du Colombier.Fl s . 248*14414594SDavid du Colombier.It tcp 249*14414594SDavid du ColombierSame as 250*14414594SDavid du Colombier.Fl T. 251*14414594SDavid du Colombier.El 252*14414594SDavid du Colombier.It Fl q 253*14414594SDavid du ColombierUse the leasing extensions to the NFS Version 3 protocol 254*14414594SDavid du Colombierto maintain cache consistency. 255*14414594SDavid du ColombierThis protocol Version 2, referred to as Not Quite Nfs (NQNFS), 256*14414594SDavid du Colombieris only supported by this updated release of NFS code. 257*14414594SDavid du Colombier(It is not backwards compatible with the release of NQNFS that went out on 258*14414594SDavid du Colombier4.4BSD-Lite. To interoperate with a 4.4BSD-Lite NFS system you will have to 259*14414594SDavid du Colombieravoid this option until you have had an opportunity to upgrade the NFS code 260*14414594SDavid du Colombieron all your 4.4BSD-Lite based systems.) 261*14414594SDavid du Colombier.It Fl r 262*14414594SDavid du ColombierSet the read data size to the specified value. 263*14414594SDavid du ColombierIt should normally be a power of 2 greater than or equal to 1024. 264*14414594SDavid du ColombierThis should be used for UDP mounts when the 265*14414594SDavid du Colombier.Dq "fragments dropped due to timeout" 266*14414594SDavid du Colombiervalue is getting large while actively using a mount point. 267*14414594SDavid du Colombier(Use 268*14414594SDavid du Colombier.Xr netstat 1 269*14414594SDavid du Colombierwith the 270*14414594SDavid du Colombier.Fl s 271*14414594SDavid du Colombieroption to see what the 272*14414594SDavid du Colombier.Dq "fragments dropped due to timeout" 273*14414594SDavid du Colombiervalue is.) 274*14414594SDavid du ColombierSee the 275*14414594SDavid du Colombier.Fl w 276*14414594SDavid du Colombieroption as well. 277*14414594SDavid du Colombier.It Fl s 278*14414594SDavid du ColombierA soft mount, which implies that file system calls will fail 279*14414594SDavid du Colombierafter \fBRetry\fR round trip timeout intervals. 280*14414594SDavid du Colombier.It Fl t 281*14414594SDavid du ColombierSet the initial retransmit timeout to the specified value. 282*14414594SDavid du ColombierMay be useful for fine tuning UDP mounts over internetworks 283*14414594SDavid du Colombierwith high packet loss rates or an overloaded server. 284*14414594SDavid du ColombierTry increasing the interval if 285*14414594SDavid du Colombier.Xr nfsstat 1 286*14414594SDavid du Colombiershows high retransmit rates while the file system is active or reducing the 287*14414594SDavid du Colombiervalue if there is a low retransmit rate but long response delay observed. 288*14414594SDavid du Colombier(Normally, the -d option should be specified when using this option to manually 289*14414594SDavid du Colombiertune the timeout 290*14414594SDavid du Colombierinterval.) 291*14414594SDavid du Colombier.It Fl w 292*14414594SDavid du ColombierSet the write data size to the specified value. 293*14414594SDavid du ColombierDitto the comments w.r.t. the 294*14414594SDavid du Colombier.Fl r 295*14414594SDavid du Colombieroption, but using the 296*14414594SDavid du Colombier.Dq "fragments dropped due to timeout" 297*14414594SDavid du Colombiervalue on the server instead of the client. 298*14414594SDavid du ColombierNote that both the 299*14414594SDavid du Colombier.Fl r 300*14414594SDavid du Colombierand 301*14414594SDavid du Colombier.Fl w 302*14414594SDavid du Colombieroptions should only be used as a last ditch effort at improving performance 303*14414594SDavid du Colombierwhen mounting servers that do not support TCP mounts. 304*14414594SDavid du Colombier.It Fl x 305*14414594SDavid du ColombierSet the retransmit timeout count for soft mounts to the specified value. 306*14414594SDavid du Colombier.El 307*14414594SDavid du Colombier.Sh SEE ALSO 308*14414594SDavid du Colombier.Xr mount 2 , 309*14414594SDavid du Colombier.Xr unmount 2 , 310*14414594SDavid du Colombier.Xr fstab 5 , 311*14414594SDavid du Colombier.Xr mount 8 312*14414594SDavid du Colombier.Sh BUGS 313*14414594SDavid du ColombierDue to the way that Sun RPC is implemented on top of UDP (unreliable datagram) 314*14414594SDavid du Colombiertransport, tuning such mounts is really a black art that can only be expected 315*14414594SDavid du Colombierto have limited success. 316*14414594SDavid du ColombierFor clients mounting servers that are not on the same 317*14414594SDavid du ColombierLAN cable or that tend to be overloaded, 318*14414594SDavid du ColombierTCP transport is strongly recommended, 319*14414594SDavid du Colombierbut unfortunately this is restricted to mostly 4.4BSD servers. 320