1 '\" te
   2 .\" Copyright (c) 2009 Sun Microsystems, Inc. All Rights Reserved
   3 .\" Copyright 2015 Nexenta Systems, Inc. All rights reserved.
   4 .\" Copyright 1989 AT&T
   5 .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License. You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing.
   6 .\" See the License for the specific language governing permissions and limitations under the License. When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the
   7 .\" fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
   8 .TH MOUNT_NFS 1M "Sep 8, 2015"
   9 .SH NAME
  10 mount_nfs \- mount remote NFS resources
  11 .SH SYNOPSIS
  12 .LP
  13 .nf
  14 \fBmount\fR [\fB-F\fR nfs] [\fIgeneric_options\fR] [\fB-o\fR \fIspecific_options\fR] [\fB-O\fR] \fIresource\fR
  15 .fi
  16 
  17 .LP
  18 .nf
  19 \fBmount\fR [\fB-F\fR nfs] [\fIgeneric_options\fR] [\fB-o\fR \fIspecific_options\fR] [\fB-O\fR] \fImount_point\fR
  20 .fi
  21 
  22 .LP
  23 .nf
  24 \fBmount\fR [\fB-F\fR nfs] [\fIgeneric_options\fR] [\fB-o\fR \fIspecific_options\fR]
  25      [\fB-O\fR] \fIresource\fR \fImount_point\fR
  26 .fi
  27 
  28 .SH DESCRIPTION
  29 .LP
  30 The \fBmount\fR utility attaches a named \fIresource\fR to the file system
  31 hierarchy at the pathname location \fImount_point\fR, which must already exist.
  32 If \fImount_point\fR has any contents prior to the \fBmount\fR operation, the
  33 contents remain hidden until the \fIresource\fR is once again unmounted.
  34 .sp
  35 .LP
  36 \fBmount_nfs\fR starts the \fBlockd\fR(1M) and \fBstatd\fR(1M) daemons if they
  37 are not already running.
  38 .sp
  39 .LP
  40 If the resource is listed in the \fB/etc/vfstab\fR file, the command line can
  41 specify either \fIresource\fR or \fImount_point\fR, and \fBmount\fR consults
  42 \fB/etc/vfstab\fR for more information. If the \fB-F\fR option is omitted,
  43 \fBmount\fR takes the file system type from \fB/etc/vfstab\fR.
  44 .sp
  45 .LP
  46 If the resource is not listed in the \fB/etc/vfstab\fR file, then the command
  47 line must specify both the \fIresource\fR and the \fImount_point\fR.
  48 .sp
  49 .LP
  50 \fIhost\fR can be an IPv4 or IPv6 address string. As IPv6 addresses already
  51 contain colons, enclose \fIhost\fR in a pair of square brackets when specifying
  52 an IPv6 address string. Otherwise the first occurrence of a colon can be
  53 interpreted as the separator between the host name and path, for example,
  54 \fB[1080::8:800:200C:417A]:tmp/file\fR. See \fBinet\fR(7P) and \fBinet6\fR(7P).
  55 .sp
  56 .ne 2
  57 .na
  58 \fB\fIhost\fR:\fIpathname\fR\fR
  59 .ad
  60 .sp .6
  61 .RS 4n
  62 Where \fIhost\fR is the name of the \fBNFS\fR server host, and \fIpathname\fR
  63 is the path name of the directory on the server being mounted. The path name is
  64 interpreted according to the server's path name parsing rules and is not
  65 necessarily slash-separated, though on most servers, this is the case.
  66 .RE
  67 
  68 .sp
  69 .ne 2
  70 .na
  71 \fB\fInfs\fR://\fIhost\fR[:\fIport\fR]/\fIpathname\fR\fR
  72 .ad
  73 .sp .6
  74 .RS 4n
  75 This is an \fBNFS\fR \fBURL\fR and follows the standard convention for
  76 \fBNFS\fR \fBURL\fRs as described in \fINFS URL Scheme\fR, RFC 2224. See the
  77 discussion of \fBURL\fR's and the public option under \fBNFS FILE SYSTEMS\fR
  78 for a more detailed discussion.
  79 .RE
  80 
  81 .sp
  82 .ne 2
  83 .na
  84 \fB\fIhost\fR:\fIpathname\fR
  85 \fInfs\fR://\fIhost\fR[:\fIport\fR]/\fIpathname\fR\fR
  86 .ad
  87 .br
  88 .na
  89 \fB\fR
  90 .ad
  91 .sp .6
  92 .RS 4n
  93 \fIhost\fR:\fIpathname\fR is a comma-separated list of
  94 \fIhost\fR:\fIpathname\fR.
  95 .sp
  96 See the discussion of replicated file systems and failover under \fBNFS FILE
  97 SYSTEMS\fR for a more detailed discussion.
  98 .RE
  99 
 100 .sp
 101 .ne 2
 102 .na
 103 \fB\fIhostlist\fR \fIpathname\fR\fR
 104 .ad
 105 .sp .6
 106 .RS 4n
 107 \fIhostlist\fR is a comma-separated list of hosts.
 108 .sp
 109 See the discussion of replicated file systems and failover under \fBNFS FILE
 110 SYSTEMS\fR for a more detailed discussion.
 111 .RE
 112 
 113 .sp
 114 .LP
 115 The \fBmount\fR command maintains a table of mounted file systems in
 116 \fB/etc/mnttab\fR, described in \fBmnttab\fR(4).
 117 .sp
 118 .LP
 119 \fBmount_nfs\fR supports both NFSv3 and NFSv4 mounts. The default NFS version
 120 is NFSv4.
 121 .SH OPTIONS
 122 .LP
 123 See \fBmount\fR(1M) for the list of supported \fIgeneric_options\fR. See
 124 \fBshare_nfs\fR(1M) for a description of server options.
 125 .sp
 126 .ne 2
 127 .na
 128 \fB\fB-o\fR \fIspecific_options\fR\fR
 129 .ad
 130 .sp .6
 131 .RS 4n
 132 Set file system specific options according to a comma-separated list with no
 133 intervening spaces.
 134 .sp
 135 .ne 2
 136 .na
 137 \fB\fBacdirmax=\fR\fIn\fR\fR
 138 .ad
 139 .sp .6
 140 .RS 4n
 141 Hold cached attributes for no more than \fIn\fR seconds after directory update.
 142 The default value is \fB60\fR.
 143 .RE
 144 
 145 .sp
 146 .ne 2
 147 .na
 148 \fB\fBacdirmin=\fR\fIn\fR\fR
 149 .ad
 150 .sp .6
 151 .RS 4n
 152 Hold cached attributes for at least \fIn\fR seconds after directory update. The
 153 default value is \fB30\fR.
 154 .RE
 155 
 156 .sp
 157 .ne 2
 158 .na
 159 \fB\fBacregmax=\fR\fIn\fR\fR
 160 .ad
 161 .sp .6
 162 .RS 4n
 163 Hold cached attributes for no more than \fIn\fR seconds after file
 164 modification. The default value is \fB60\fR.
 165 .RE
 166 
 167 .sp
 168 .ne 2
 169 .na
 170 \fB\fBacregmin=\fR\fIn\fR\fR
 171 .ad
 172 .sp .6
 173 .RS 4n
 174 Hold cached attributes for at least \fIn\fR seconds after file modification.
 175 The default value is \fB3\fR.
 176 .RE
 177 
 178 .sp
 179 .ne 2
 180 .na
 181 \fB\fBactimeo=\fR\fIn\fR\fR
 182 .ad
 183 .sp .6
 184 .RS 4n
 185 Set \fImin\fR and \fImax\fR times for regular files and directories to \fIn\fR
 186 seconds. See "File Attributes," below, for a description of the effect of
 187 setting this option to \fB0\fR.
 188 .sp
 189 See "Specifying Values for Attribute Cache Duration Options," below, for a
 190 description of how \fBacdirmax\fR, \fBacdirmin\fR, \fBacregmax\fR,
 191 \fBacregmin\fR, and \fBactimeo\fR are parsed on a \fBmount\fR command line.
 192 .RE
 193 
 194 .sp
 195 .ne 2
 196 .na
 197 \fB\fBbg\fR | \fBfg\fR\fR
 198 .ad
 199 .sp .6
 200 .RS 4n
 201 If the first attempt fails, retry in the background, or, in the foreground. The
 202 default is \fBfg\fR.
 203 .RE
 204 
 205 .sp
 206 .ne 2
 207 .na
 208 \fB\fBforcedirectio\fR | \fBnoforcedirectio\fR\fR
 209 .ad
 210 .sp .6
 211 .RS 4n
 212 If \fBforcedirectio\fR is specified, then for the duration of the mount, forced
 213 direct \fBI/O\fR is used. If the filesystem is mounted using
 214 \fBforcedirectio\fR, data is transferred directly between client and server,
 215 with no buffering on the client. If the filesystem is mounted using
 216 \fBnoforcedirectio\fR, data is buffered on the client. \fBforcedirectio\fR is a
 217 performance option that is of benefit only in large sequential data transfers.
 218 The default behavior is \fBnoforcedirectio\fR.
 219 .RE
 220 
 221 .sp
 222 .ne 2
 223 .na
 224 \fB\fBgrpid\fR\fR
 225 .ad
 226 .sp .6
 227 .RS 4n
 228 By default, the \fBGID\fR associated with a newly created file obeys the System
 229 V semantics; that is, the \fBGID\fR is set to the effective \fBGID\fR of the
 230 calling process. This behavior can be overridden on a per-directory basis by
 231 setting the set-GID bit of the parent directory; in this case, the \fBGID\fR of
 232 a newly created file is set to the \fBGID\fR of the parent directory (see
 233 \fBopen\fR(2) and \fBmkdir\fR(2)). Files created on file systems that are
 234 mounted with the \fBgrpid\fR option obeys \fBBSD\fR semantics independent of
 235 whether the set-GID bit of the parent directory is set; that is, the \fBGID\fR
 236 is unconditionally inherited from that of the parent directory.
 237 .RE
 238 
 239 .sp
 240 .ne 2
 241 .na
 242 \fB\fBhard\fR | \fBsoft\fR\fR
 243 .ad
 244 .sp .6
 245 .RS 4n
 246 Continue to retry requests until the server responds (\fBhard\fR) or give up
 247 and return an error (\fBsoft\fR). The default value is \fBhard\fR. Note that
 248 NFSv4 clients do not support soft mounts.
 249 .RE
 250 
 251 .sp
 252 .ne 2
 253 .na
 254 \fB\fBintr\fR | \fBnointr\fR\fR
 255 .ad
 256 .sp .6
 257 .RS 4n
 258 Allow (do not allow) keyboard interrupts to kill a process that is hung while
 259 waiting for a response on a hard-mounted file system. The default is
 260 \fBintr\fR, which makes it possible for clients to interrupt applications that
 261 can be waiting for a remote mount.
 262 .RE
 263 
 264 .sp
 265 .ne 2
 266 .na
 267 \fB\fBnoac\fR\fR
 268 .ad
 269 .sp .6
 270 .RS 4n
 271 Suppress data and attribute caching. The data caching that is suppressed is the
 272 write-behind. The local page cache is still maintained, but data copied into it
 273 is immediately written to the server.
 274 .RE
 275 
 276 .sp
 277 .ne 2
 278 .na
 279 \fB\fBnocto\fR\fR
 280 .ad
 281 .sp .6
 282 .RS 4n
 283 Do not perform the normal close-to-open consistency. When a file is closed, all
 284 modified data associated with the file is flushed to the server and not held on
 285 the client. When a file is opened the client sends a request to the server to
 286 validate the client's local caches. This behavior ensures a file's consistency
 287 across multiple NFS clients. When \fB-nocto\fR is in effect, the client does
 288 not perform the flush on close and the request for validation, allowing the
 289 possiblity of differences among copies of the same file as stored on multiple
 290 clients.
 291 .sp
 292 This option can be used where it can be guaranteed that accesses to a specified
 293 file system are made from only one client and only that client. Under such a
 294 condition, the effect of \fB-nocto\fR can be a slight performance gain.
 295 .RE
 296 
 297 .sp
 298 .ne 2
 299 .na
 300 \fB\fBport=\fR\fIn\fR\fR
 301 .ad
 302 .sp .6
 303 .RS 4n
 304 The server \fBIP\fR port number. The default is \fBNFS_PORT\fR. If the
 305 \fBport\fR option is specified, and if the resource includes one or more
 306 \fBNFS\fR \fBURL\fRs, and if any of the \fBURL\fRs include a \fBport\fR number,
 307 then the \fBport\fR number in the option and in the \fBURL\fR must be the same.
 308 .RE
 309 
 310 .sp
 311 .ne 2
 312 .na
 313 \fB\fBposix\fR\fR
 314 .ad
 315 .sp .6
 316 .RS 4n
 317 Request \fBPOSIX.1\fR semantics for the file system. Requires a mount Version 2
 318 \fBmountd\fR(1M) on the server. See \fBstandards\fR(5) for information
 319 regarding POSIX.
 320 .RE
 321 
 322 .sp
 323 .ne 2
 324 .na
 325 \fB\fBproto=\fR\fInetid\fR | \fBrdma\fR\fR
 326 .ad
 327 .sp .6
 328 .RS 4n
 329 By default, the transport protocol that the NFS mount uses is the first
 330 available RDMA transport supported both by the client and the server. If no
 331 RDMA transport is found, then it attempts to use a TCP transport or, failing
 332 that, a UDP transport, as ordered in the \fB/etc/netconfig\fR file. If it does
 333 not find a connection oriented transport, it uses the first available
 334 connectionless transport.
 335 .sp
 336 Use this option to override the default behavior.
 337 .sp
 338 \fBproto\fR is set to the value of \fInetid\fR or \fBrdma\fR. \fInetid\fR is
 339 the value of the \fBnetwork_id\fR field entry in the \fB/etc/netconfig\fR file.
 340 .sp
 341 The UDP protocol is not supported for NFS Version 4. If you specify a UDP
 342 protocol with the \fBproto\fR option, NFS version 4 is not used.
 343 .RE
 344 
 345 .sp
 346 .ne 2
 347 .na
 348 \fB\fBpublic\fR\fR
 349 .ad
 350 .sp .6
 351 .RS 4n
 352 The \fBpublic\fR option forces the use of the public file handle when
 353 connecting to the \fBNFS\fR server. The resource specified might not have an
 354 \fBNFS\fR \fBURL\fR. See the discussion of \fBURL\fRs and the public option
 355 under \fBNFS FILE SYSTEMS\fR for a more detailed discussion.
 356 .RE
 357 
 358 .sp
 359 .ne 2
 360 .na
 361 \fB\fBquota\fR | \fBnoquota\fR\fR
 362 .ad
 363 .sp .6
 364 .RS 4n
 365 Enable or prevent \fBquota\fR(1M) to check whether the user is over quota on
 366 this file system; if the file system has quotas enabled on the server, quotas
 367 are still checked for operations on this file system.
 368 .RE
 369 
 370 .sp
 371 .ne 2
 372 .na
 373 \fB\fBremount\fR\fR
 374 .ad
 375 .sp .6
 376 .RS 4n
 377 Remounts a read-only file system as read-write (using the \fBrw\fR option).
 378 This option cannot be used with other \fB-o\fR options, and this option works
 379 only on currently mounted read-only file systems.
 380 .RE
 381 
 382 .sp
 383 .ne 2
 384 .na
 385 \fB\fBretrans=\fR\fIn\fR\fR
 386 .ad
 387 .sp .6
 388 .RS 4n
 389 Set the number of \fBNFS\fR retransmissions to \fIn\fR. The default value is
 390 \fB5\fR. For connection-oriented transports, this option has no effect because
 391 it is assumed that the transport performs retransmissions on behalf of NFS.
 392 .RE
 393 
 394 .sp
 395 .ne 2
 396 .na
 397 \fB\fBretry=\fR\fIn\fR\fR
 398 .ad
 399 .sp .6
 400 .RS 4n
 401 The number of times to retry the \fBmount\fR operation. The default for the
 402 \fBmount\fR command is \fB10000\fR.
 403 .sp
 404 The default for the automounter is \fB0\fR, in other words, do not retry. You
 405 might find it useful to increase this value on heavily loaded servers, where
 406 automounter traffic is dropped, causing unnecessary server not responding
 407 errors.
 408 .RE
 409 
 410 .sp
 411 .ne 2
 412 .na
 413 \fB\fBrsize=\fR\fIn\fR\fR
 414 .ad
 415 .sp .6
 416 .RS 4n
 417 Set the read buffer size to a maximum of \fIn\fR bytes. The default value is
 418 \fB1048576\fR when using connection-oriented transports with Version 3 or
 419 Version 4 of the \fBNFS\fR protocol, and \fB32768\fR when using connection-less
 420 transports. The default can be negotiated down if the server prefers a smaller
 421 transfer size. "\fBRead\fR" operations may not necessarily use the maximum
 422 buffer size. When using Version 2, the default value is \fB32768\fR for all
 423 transports.
 424 .RE
 425 
 426 .sp
 427 .ne 2
 428 .na
 429 \fB\fBsec=\fR\fImode\fR\fR
 430 .ad
 431 .sp .6
 432 .RS 4n
 433 Set the security \fImode\fR for \fBNFS\fR transactions. If \fBsec=\fR is not
 434 specified, then the default action is to use \fBAUTH_SYS\fR over \fBNFS\fR
 435 Version 2 mounts, use a user-configured default \fBauth\fR over NFS version 3
 436 mounts, or to  negotiate a mode over Version 4 mounts.
 437 .sp
 438 The preferred mode for NFS Version 3 mounts is the default mode specified in
 439 \fB/etc/nfssec.conf\fR (see \fBnfssec.conf\fR(4)) on the client. If there is no
 440 default configured in this file or if the server does not export using the
 441 client's default mode, then the client picks the first mode that it supports in
 442 the array of modes returned by the server. These alternatives are limited to
 443 the security flavors listed in \fB/etc/nfssec.conf\fR.
 444 .sp
 445 NFS Version 4 mounts negotiate a security mode when the server returns an array
 446 of security modes. The client attempts the mount with each security mode, in
 447 order, until one is successful.
 448 .sp
 449 Only one mode can be specified with the \fBsec=\fR option. See \fBnfssec\fR(5)
 450 for the available \fImode\fR options.
 451 .RE
 452 
 453 .sp
 454 .ne 2
 455 .na
 456 \fB\fBsecure\fR\fR
 457 .ad
 458 .sp .6
 459 .RS 4n
 460 This option has been deprecated in favor of the \fBsec=\fR\fIdh\fR option.
 461 .RE
 462 
 463 .sp
 464 .ne 2
 465 .na
 466 \fB\fBtimeo=\fR\fIn\fR\fR
 467 .ad
 468 .sp .6
 469 .RS 4n
 470 Set the \fBNFS\fR timeout to \fIn\fR tenths of a second. The default value is
 471 \fB11\fR tenths of a second for connectionless transports, and \fB600\fR tenths
 472 of a second for connection-oriented transports. This value is ignored for
 473 connectionless transports. Such transports might implement their own timeouts,
 474 which are outside the control of NFS.
 475 .RE
 476 
 477 .sp
 478 .ne 2
 479 .na
 480 \fB\fBvers=\fR\fINFS version number\fR\fR
 481 .ad
 482 .sp .6
 483 .RS 4n
 484 By default, the version of \fBNFS\fR protocol used between the client and the
 485 server is the highest one available on both systems. The default maximum for
 486 the client is Version 4. This can be changed by setting the
 487 \fBNFS_CLIENT_VERSMAX\fR parameter in \fB/etc/default/nfs\fR to a valid version
 488 (2, 3, or 4). If the \fBNFS\fR server does not support the client's default
 489 maximum, the next lowest version attempted until a matching version is found.
 490 .RE
 491 
 492 .sp
 493 .ne 2
 494 .na
 495 \fB\fBwsize=\fR\fIn\fR\fR
 496 .ad
 497 .sp .6
 498 .RS 4n
 499 Set the write buffer size to a maximum of \fIn\fR bytes. The default value is
 500 \fB1048576\fR when using connection-oriented transports with Version 3 or
 501 Version 4 of the \fBNFS\fR protocol, and \fB32768\fR when using connection-less
 502 transports. The default can be negotiated down if the server prefers a smaller
 503 transfer size. "\fBWrite\fR" operations may not necessarily use the maximum
 504 buffer size. When using Version 2, the default value is \fB32768\fR for all
 505 transports.
 506 .RE
 507 
 508 .sp
 509 .ne 2
 510 .na
 511 \fB\fBxattr\fR | \fBnoxattr\fR\fR
 512 .ad
 513 .sp .6
 514 .RS 4n
 515 Allow or disallow the creation and manipulation of extended attributes. The
 516 default is \fBxattr\fR. See \fBfsattr\fR(5) for a description of extended
 517 attributes.
 518 .RE
 519 
 520 .RE
 521 
 522 .sp
 523 .ne 2
 524 .na
 525 \fB\fB-O\fR\fR
 526 .ad
 527 .sp .6
 528 .RS 4n
 529 Overlay mount. Allow the file system to be mounted over an existing mount
 530 point, making the underlying file system inaccessible. If a mount is attempted
 531 on a pre-existing mount point without setting this flag, the mount fails,
 532 producing the error "device busy."
 533 .RE
 534 
 535 .SH NFS FILE SYSTEMS
 536 .ne 2
 537 .na
 538 \fBBackground versus Foreground\fR
 539 .ad
 540 .sp .6
 541 .RS 4n
 542 File systems mounted with the \fBbg\fR option indicate that \fBmount\fR is to
 543 retry in the background if the server's mount daemon (\fBmountd\fR(1M)) does
 544 not respond. \fBmount\fR retries the request up to the count specified in the
 545 \fBretry=\fR\fIn\fR option. (Note that the default value for \fBretry\fR
 546 differs between \fBmount\fR and \fBautomount\fR. See the description of
 547 \fBretry\fR, above.) Once the file system is mounted, each \fBNFS\fR request
 548 made in the kernel waits \fBtimeo=\fR\fIn\fR tenths of a second for a response.
 549 If no response arrives, the time-out is multiplied by \fB2\fR and the request
 550 is retransmitted. When the number of retransmissions has reached the number
 551 specified in the \fBretrans=\fR\fIn\fR option, a file system mounted with the
 552 \fBsoft\fR option returns an error on the request; one mounted with the
 553 \fBhard\fR option prints a warning message and continues to retry the request.
 554 .RE
 555 
 556 .sp
 557 .ne 2
 558 .na
 559 \fBHard versus Soft\fR
 560 .ad
 561 .sp .6
 562 .RS 4n
 563 File systems that are mounted read-write or that contain executable files
 564 should always be mounted with the \fBhard\fR option. Applications using
 565 \fBsoft\fR mounted file systems can incur unexpected \fBI/O\fR errors, file
 566 corruption, and unexpected program core dumps. The soft option is not
 567 recommended.
 568 .RE
 569 
 570 .sp
 571 .ne 2
 572 .na
 573 \fBAuthenticated requests\fR
 574 .ad
 575 .sp .6
 576 .RS 4n
 577 The server can require authenticated \fBNFS\fR requests from the client.
 578 \fBsec=\fR\fIdh\fR authentication might be required. See \fBnfssec\fR(5).
 579 .RE
 580 
 581 .sp
 582 .ne 2
 583 .na
 584 \fBURLs and the public option\fR
 585 .ad
 586 .sp .6
 587 .RS 4n
 588 If the \fBpublic\fR option is specified, or if the \fIresource\fR includes and
 589 \fBNFS\fR \fBURL\fR, \fBmount\fR attempts to connect to the server using the
 590 public file handle lookup protocol. See \fIWebNFS Client Specification\fR, RFC
 591 2054. If the server supports the public file handle, the attempt is successful;
 592 \fBmount\fR does not need to contact the server's \fBrpcbind\fR(1M) and the
 593 \fBmountd\fR(1M) daemons to get the port number of the \fBmount\fR server and
 594 the initial file handle of \fIpathname\fR, respectively. If the \fBNFS\fR
 595 client and server are separated by a firewall that allows all outbound
 596 connections through specific ports, such as \fBNFS_PORT\fR, then this enables
 597 \fBNFS\fR operations through the firewall. The public option and the \fBNFS\fR
 598 \fBURL\fR can be specified independently or together. They interact as
 599 specified in the following matrix:
 600 .sp
 601 .in +2
 602 .nf
 603                    Resource Style
 604 
 605                     \fIhost\fR:\fIpathname\fR              NFS URL
 606 
 607 public option      Force public file          Force public file
 608                     handle and fail            handle and fail
 609                     mount if not supported.    mount if not supported.
 610 
 611                     Use Native paths.          Use Canonical paths.
 612 
 613 default            Use MOUNT protocol.        Try public file handle
 614                                                with Canonical paths.
 615                                                Fall back to MOUNT
 616                                                protocol if not
 617                                                supported.
 618 .fi
 619 .in -2
 620 
 621 A Native path is a path name that is interpreted according to conventions used
 622 on the native operating system of the \fBNFS\fR server. A Canonical path is a
 623 path name that is interpreted according to the \fBURL\fR rules. See \fIUniform
 624 Resource Locators (URL)\fR, RFC 1738. See  for uses of Native and Canonical
 625 paths.
 626 .RE
 627 
 628 .sp
 629 .ne 2
 630 .na
 631 \fBReplicated file systems and failover\fR
 632 .ad
 633 .sp .6
 634 .RS 4n
 635 \fIresource\fR can list multiple read\(mionly file systems to be used to
 636 provide data. These file systems should contain equivalent directory structures
 637 and identical files. It is also recommended that they be created by a utility
 638 such as \fBrdist\fR(1). The file systems can be specified either with a
 639 comma\(miseparated list of \fIhost:/pathname\fR entries and/or \fBNFS\fR
 640 \fBURL\fR entries, or with a comma \(miseparated list of hosts, if all file
 641 system names are the same. If multiple file systems are named and the first
 642 server in the list is down, failover uses the next alternate server to access
 643 files. If the read\(mionly option is not chosen, replication is disabled. File
 644 access, for NFS Versions 2 and 3, is blocked on the original if NFS locks are
 645 active for that file.
 646 .RE
 647 
 648 .SS "File Attributes"
 649 .LP
 650 To improve \fBNFS\fR read performance, files and file attributes are cached.
 651 File modification times get updated whenever a write occurs. However, file
 652 access times can be temporarily out-of-date until the cache gets refreshed.
 653 .sp
 654 .LP
 655 The attribute cache retains file attributes on the client. Attributes for a
 656 file are assigned a time to be flushed. If the file is modified before the
 657 flush time, then the flush time is extended by the time since the last
 658 modification (under the assumption that files that changed recently are likely
 659 to change soon). There is a minimum and maximum flush time extension for
 660 regular files and for directories. Setting \fBactimeo=\fR\fIn\fR sets flush
 661 time to \fIn\fR seconds for both regular files and directories.
 662 .sp
 663 .LP
 664 Setting \fBactimeo=0\fR disables attribute caching on the client. This means
 665 that every reference to attributes is satisfied directly from the server though
 666 file data is still cached. While this guarantees that the client always has the
 667 latest file attributes from the server, it has an adverse effect on performance
 668 through additional latency, network load, and server load.
 669 .sp
 670 .LP
 671 Setting the \fBnoac\fR option also disables attribute caching, but has the
 672 further effect of disabling client write caching. While this guarantees that
 673 data written by an application is written directly to a server, where it can be
 674 viewed immediately by other clients, it has a significant adverse effect on
 675 client write performance. Data written into memory-mapped file pages
 676 (\fBmmap\fR(2)) are not written directly to this server.
 677 .SS "Specifying Values for Attribute Cache Duration Options"
 678 .LP
 679 The attribute cache duration options are \fBacdirmax\fR, \fBacdirmin\fR,
 680 \fBacregmax\fR, \fBacregmin\fR, and \fBactimeo\fR, as described under OPTIONS.
 681 A value specified for \fBactimeo\fR sets the values of all attribute cache
 682 duration options except for any of these options specified following
 683 \fBactimeo\fR on a \fBmount\fR command line. For example, consider the
 684 following command:
 685 .sp
 686 .in +2
 687 .nf
 688 example# mount -o acdirmax=10,actimeo=1000 server:/path /localpath
 689 .fi
 690 .in -2
 691 
 692 .sp
 693 .LP
 694 Because \fBactimeo\fR is the last duration option in the command line, its
 695 value (\fB1000\fR) becomes the setting for all of the duration options,
 696 including \fBacdirmax\fR. Now consider:
 697 .sp
 698 .in +2
 699 .nf
 700 example# mount -o actimeo=1000,acdirmax=10 server:/path /localpath
 701 .fi
 702 .in -2
 703 
 704 .sp
 705 .LP
 706 Because the \fBacdirmax\fR option follows \fBactimeo\fR on the command line, it
 707 is assigned the value specified (\fB10\fR). The remaining duration options are
 708 set to the value of \fBactimeo\fR (\fB1000\fR).
 709 .SH EXAMPLES
 710 .LP
 711 \fBExample 1 \fRMounting an \fBNFS\fR File System
 712 .sp
 713 .LP
 714 To mount an \fBNFS\fR file system:
 715 
 716 .sp
 717 .in +2
 718 .nf
 719 example# mount serv:/usr/src /usr/src
 720 .fi
 721 .in -2
 722 .sp
 723 
 724 .LP
 725 \fBExample 2 \fRMounting An \fBNFS\fR File System Read-Only With No suid
 726 Privileges
 727 .sp
 728 .LP
 729 To mount an \fBNFS\fR file system read-only with no suid privileges:
 730 
 731 .sp
 732 .in +2
 733 .nf
 734 example# mount -r -o nosuid serv:/usr/src /usr/src
 735 .fi
 736 .in -2
 737 .sp
 738 
 739 .LP
 740 \fBExample 3 \fRMounting An \fBNFS\fR File System Over Version 2, with the UDP
 741 Transport
 742 .sp
 743 .LP
 744 To mount an \fBNFS\fR file system over Version 2, with the UDP transport:
 745 
 746 .sp
 747 .in +2
 748 .nf
 749 example# mount -o vers=2,proto=udp serv:/usr/src /usr/src
 750 .fi
 751 .in -2
 752 .sp
 753 
 754 .LP
 755 \fBExample 4 \fRMounting an \fBNFS\fR File System Using An \fBNFS\fR \fBURL\fR
 756 .sp
 757 .LP
 758 To mount an \fBNFS\fR file system using an \fBNFS\fR \fBURL\fR (a canonical
 759 path):
 760 
 761 .sp
 762 .in +2
 763 .nf
 764 example# mount nfs://serv/usr/man /usr/man
 765 .fi
 766 .in -2
 767 .sp
 768 
 769 .LP
 770 \fBExample 5 \fRMounting An \fBNFS\fR File System Forcing Use Of The Public
 771 File Handle
 772 .sp
 773 .LP
 774 To mount an \fBNFS\fR file system and force the use of the public file handle
 775 and an \fBNFS\fR \fBURL\fR (a canonical path) that has a non 7-bit ASCII escape
 776 sequence:
 777 
 778 .sp
 779 .in +2
 780 .nf
 781 example# mount -o public nfs://serv/usr/%A0abc /mnt/test
 782 .fi
 783 .in -2
 784 .sp
 785 
 786 .LP
 787 \fBExample 6 \fRMounting an \fBNFS\fR File System Using a Native Path
 788 .sp
 789 .LP
 790 To mount an \fBNFS\fR file system using a native path (where the server uses
 791 colons (":") as the component separator) and the public file handle:
 792 
 793 .sp
 794 .in +2
 795 .nf
 796 example# mount -o public serv:C:doc:new /usr/doc
 797 .fi
 798 .in -2
 799 .sp
 800 
 801 .LP
 802 \fBExample 7 \fRMounting a Replicated Set of \fBNFS\fR File Systems with the
 803 Same Pathnames
 804 .sp
 805 .LP
 806 To mount a replicated set of \fBNFS\fR file systems with the same pathnames:
 807 
 808 .sp
 809 .in +2
 810 .nf
 811 example# mount serv\(mia,serv\(mib,serv\(mic:/usr/man /usr/man
 812 .fi
 813 .in -2
 814 .sp
 815 
 816 .LP
 817 \fBExample 8 \fRMounting a Replicated Set of \fBNFS\fR File Systems with
 818 Different Pathnames
 819 .sp
 820 .LP
 821 To mount a replicated set of \fBNFS\fR file systems with different pathnames:
 822 
 823 .sp
 824 .in +2
 825 .nf
 826 example# mount serv\(mix:/usr/man,serv\(miy:/var/man,nfs://serv-z/man /usr/man
 827 .fi
 828 .in -2
 829 .sp
 830 
 831 .SH FILES
 832 .ne 2
 833 .na
 834 \fB\fB/etc/mnttab\fR\fR
 835 .ad
 836 .sp .6
 837 .RS 4n
 838 table of mounted file systems
 839 .RE
 840 
 841 .sp
 842 .ne 2
 843 .na
 844 \fB\fB/etc/dfs/fstypes\fR\fR
 845 .ad
 846 .sp .6
 847 .RS 4n
 848 default distributed file system type
 849 .RE
 850 
 851 .sp
 852 .ne 2
 853 .na
 854 \fB\fB/etc/vfstab\fR\fR
 855 .ad
 856 .sp .6
 857 .RS 4n
 858 table of automatically mounted resources
 859 .RE
 860 
 861 .SH SEE ALSO
 862 .LP
 863 \fBrdist\fR(1), \fBlockd\fR(1M), \fBmountall\fR(1M), \fBmountd\fR(1M),
 864 \fBnfsd\fR(1M), \fBquota\fR(1M), \fBstatd\fR(1M), \fBmkdir\fR(2),
 865 \fBmmap\fR(2), \fBmount\fR(2), \fBopen\fR(2), \fBumount\fR(2), \fBmnttab\fR(4),
 866 \fBnfs\fR(4), \fBnfssec.conf\fR(4), \fBattributes\fR(5), \fBfsattr\fR(5),
 867 \fBnfssec\fR(5), \fBstandards\fR(5), \fBinet\fR(7P), \fBinet6\fR(7P),
 868 \fBlofs\fR(7FS)
 869 .sp
 870 .LP
 871 Callaghan, Brent, \fIWebNFS Client Specification\fR, RFC 2054, October 1996.
 872 .sp
 873 .LP
 874 Callaghan, Brent, \fINFS URL Scheme\fR, RFC 2224, October 1997.
 875 .sp
 876 .LP
 877 Berners-Lee, Masinter & McCahill , \fIUniform Resource Locators (URL)\fR, RFC
 878 1738, December 1994.
 879 .SH NOTES
 880 .LP
 881 An \fBNFS\fR server should not attempt to mount its own file systems. See
 882 \fBlofs\fR(7FS).
 883 .sp
 884 .LP
 885 If the directory on which a file system is to be mounted is a symbolic link,
 886 the file system is mounted on \fBthe directory to which the symbolic link
 887 refers,\fR rather than being mounted on top of the symbolic link itself.
 888 .sp
 889 .LP
 890 SunOS 4.x used the \fBbiod\fR maintenance procedure to perform parallel
 891 read-ahead and write-behind on \fBNFS\fR clients. SunOS 5.x made \fBbiod\fR
 892 obsolete with multi-threaded processing, which transparently performs parallel
 893 read-ahead and write-behind.
 894 .sp
 895 .LP
 896 Since the root \fB(\fR/\fB)\fR file system is mounted read-only by the kernel
 897 during the boot process, only the \fBremount\fR option (and options that can be
 898 used in conjunction with \fBremount\fR) affect the root (\fB/\fR) entry in the
 899 \fB/etc/vfstab\fR file.
 900 .sp
 901 .LP
 902 The NFS client service is managed by the service management facility,
 903 \fBsmf\fR(5), under the service identifier:
 904 .sp
 905 .in +2
 906 .nf
 907 svc:/network/nfs/client:default
 908 .fi
 909 .in -2
 910 .sp
 911 
 912 .sp
 913 .LP
 914 Administrative actions on this service, such as enabling, disabling, or
 915 requesting restart, can be performed using \fBsvcadm\fR(1M). The service's
 916 status can be queried using the \fBsvcs\fR(1) command.