1 '\" te
   2 .\"  Copyright (c) 2007, Sun Microsystems, Inc. All Rights Reserved
   3 .\" 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.
   4 .\"  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
   5 .\" the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
   6 .TH NFSSTAT 1M "Jun 16, 2009"
   7 .SH NAME
   8 nfsstat \- NFS statistics
   9 .SH SYNOPSIS
  10 .LP
  11 .nf
  12 \fBnfsstat\fR [\fB-cnrsza\fR] [\fB-T\fR u | d ] [\fB-v\fR \fIversion\fR] [\fIinterval\fR [\fIcount\fR]]
  13 .fi
  14 
  15 .LP
  16 .nf
  17 \fBnfsstat\fR \fB-m\fR [\fIpathname\fR]...
  18 .fi
  19 
  20 .SH DESCRIPTION
  21 .sp
  22 .LP
  23 \fBnfsstat\fR displays statistical information about the \fBNFS\fR and
  24 \fBRPC\fR (Remote Procedure Call), interfaces to the kernel. It can also be
  25 used to reinitialize this information. If no options are given the default is
  26 as follows:
  27 .sp
  28 .LP
  29 \fBnfsstat\fR \fB-csnra\fR
  30 .sp
  31 .LP
  32 The default displays everything, but reinitializes nothing.
  33 .SH OPTIONS
  34 .sp
  35 .ne 2
  36 .na
  37 \fB\fB-a\fR\fR
  38 .ad
  39 .sp .6
  40 .RS 4n
  41 Display \fBNFS_ACL\fR information.
  42 .RE
  43 
  44 .sp
  45 .ne 2
  46 .na
  47 \fB\fB-c\fR\fR
  48 .ad
  49 .sp .6
  50 .RS 4n
  51 Display client information. Only the client side \fBNFS\fR, \fBRPC\fR, and
  52 \fBNFS_ACL\fR information is printed. Can be combined with the \fB-n\fR,
  53 \fB-r\fR, and \fB-a\fR options to print client side \fBNFS\fR, \fBRPC\fR, and
  54 \fBNFS_ACL\fR information only.
  55 .RE
  56 
  57 .sp
  58 .ne 2
  59 .na
  60 \fB\fB-m\fR [\fIpathname...\fR]\fR
  61 .ad
  62 .sp .6
  63 .RS 4n
  64 Display statistics for each \fBNFS\fR mounted file system. If \fIpathname\fR is
  65 not specified, displays statistics for all NFS mounted file systems. If
  66 \fIpathname\fR is specified, displays statistics for the NFS mounted file
  67 systems indicated by \fIpathname\fR.
  68 .sp
  69 This includes the server name and address, mount flags, current read and write
  70 sizes, the retransmission count, the attribute cache timeout values, failover
  71 information, and the timers used for dynamic retransmission. The dynamic
  72 retransmission timers are displayed only where dynamic retransmission is in
  73 use. By default, \fBNFS\fR mounts over the \fBTCP\fR protocols and \fBNFS\fR
  74 Version 3 mounts over either \fBTCP\fR or \fBUDP\fR do not use dynamic
  75 retransmission.
  76 .sp
  77 If you specify the \fB-m\fR option, this is the only option that \fBnfsstat\fR
  78 uses. If you specify other options with \fB-m\fR, you receive an error message
  79 alerting that the \fB-m\fR flag cannot be combined with other options.
  80 .RE
  81 
  82 .sp
  83 .ne 2
  84 .na
  85 \fB\fB-n\fR\fR
  86 .ad
  87 .sp .6
  88 .RS 4n
  89 Display \fBNFS\fR information. \fBNFS\fR information for both the client and
  90 server side are printed. Can be combined with the \fB-c\fR and \fB-s\fR options
  91 to print client or server \fBNFS\fR information only.
  92 .RE
  93 
  94 .sp
  95 .ne 2
  96 .na
  97 \fB\fB-r\fR\fR
  98 .ad
  99 .sp .6
 100 .RS 4n
 101 Display \fBRPC\fR information.
 102 .RE
 103 
 104 .sp
 105 .ne 2
 106 .na
 107 \fB\fB-s\fR\fR
 108 .ad
 109 .sp .6
 110 .RS 4n
 111 Display server information.
 112 .RE
 113 
 114 .sp
 115 .ne 2
 116 .na
 117 \fB\fB-T\fR \fBu\fR | \fBd\fR\fR
 118 .ad
 119 .sp .6
 120 .RS 4n
 121 Display a time stamp.
 122 .sp
 123 Specify \fBu\fR for a printed representation of the internal representation of
 124 time. See \fBtime\fR(2). Specify \fBd\fR for standard date format. See
 125 \fBdate\fR(1).
 126 .RE
 127 
 128 .sp
 129 .ne 2
 130 .na
 131 \fB\fB-v\fR \fIversion\fR\fR
 132 .ad
 133 .sp .6
 134 .RS 4n
 135 Specify which NFS version for which to print statistics. When followed by the
 136 optional \fIversion\fR argument, (\fB2\fR|\fB3\fR|\fB4\fR), specifies
 137 statistics for that version. By default, prints statistics for all versions.
 138 .RE
 139 
 140 .sp
 141 .ne 2
 142 .na
 143 \fB\fB-z\fR\fR
 144 .ad
 145 .sp .6
 146 .RS 4n
 147 Zero (reinitialize) statistics. This option is for use by the super user only,
 148 and can be combined with any of the above options to zero particular sets of
 149 statistics after printing them.
 150 .RE
 151 
 152 .SH OPERANDS
 153 .sp
 154 .LP
 155 The following operands are supported:
 156 .sp
 157 .ne 2
 158 .na
 159 \fB\fIcount\fR\fR
 160 .ad
 161 .sp .6
 162 .RS 4n
 163 Display only count reports
 164 .RE
 165 
 166 .sp
 167 .ne 2
 168 .na
 169 \fB\fIinterval\fR\fR
 170 .ad
 171 .sp .6
 172 .RS 4n
 173 Report once each interval seconds.
 174 .RE
 175 
 176 .sp
 177 .ne 2
 178 .na
 179 \fB\fIpathname\fR\fR
 180 .ad
 181 .sp .6
 182 .RS 4n
 183 Specify the pathname of a file in an NFS mounted file system for which
 184 statistics are to be displayed.
 185 .RE
 186 
 187 .SH DISPLAYS
 188 .sp
 189 .LP
 190 The server \fBRPC\fR display includes the following fields:
 191 .sp
 192 .ne 2
 193 .na
 194 \fB\fBbadcalls\fR\fR
 195 .ad
 196 .sp .6
 197 .RS 4n
 198 The total number of calls rejected by the \fBRPC\fR layer (the sum of
 199 \fBbadlen\fR and \fBxdrcall\fR as defined below).
 200 .RE
 201 
 202 .sp
 203 .ne 2
 204 .na
 205 \fB\fBbadlen\fR\fR
 206 .ad
 207 .sp .6
 208 .RS 4n
 209 The number of \fBRPC\fR calls with a length shorter than a minimum-sized
 210 \fBRPC\fR call.
 211 .RE
 212 
 213 .sp
 214 .ne 2
 215 .na
 216 \fB\fBcalls\fR\fR
 217 .ad
 218 .sp .6
 219 .RS 4n
 220 The total number of \fBRPC\fR calls received.
 221 .RE
 222 
 223 .sp
 224 .ne 2
 225 .na
 226 \fB\fBdupchecks\fR\fR
 227 .ad
 228 .sp .6
 229 .RS 4n
 230 The number of \fBRPC\fR calls that looked up in the duplicate request cache.
 231 .RE
 232 
 233 .sp
 234 .ne 2
 235 .na
 236 \fB\fBdupreqs\fR\fR
 237 .ad
 238 .sp .6
 239 .RS 4n
 240 The number of \fBRPC\fR calls that were found to be duplicates.
 241 .RE
 242 
 243 .sp
 244 .ne 2
 245 .na
 246 \fB\fBnullrecv\fR\fR
 247 .ad
 248 .sp .6
 249 .RS 4n
 250 The number of times an \fBRPC\fR call was not available when it was thought to
 251 be received.
 252 .RE
 253 
 254 .sp
 255 .ne 2
 256 .na
 257 \fB\fBxdrcall\fR\fR
 258 .ad
 259 .sp .6
 260 .RS 4n
 261 The number of \fBRPC\fR calls whose header could not be \fBXDR\fR decoded.
 262 .RE
 263 
 264 .sp
 265 .LP
 266 The server \fBNFS\fR display shows the number of \fBNFS\fR calls received
 267 (\fBcalls\fR) and rejected (\fBbadcalls\fR), and the counts and percentages for
 268 the various calls that were made.
 269 .sp
 270 .LP
 271 The server \fBNFS_ACL\fR display shows the counts and percentages for the
 272 various calls that were made.
 273 .sp
 274 .LP
 275 The client \fBRPC\fR display includes the following fields:
 276 .sp
 277 .ne 2
 278 .na
 279 \fB\fBcalls\fR\fR
 280 .ad
 281 .sp .6
 282 .RS 4n
 283 The total number of \fBRPC\fR calls made.
 284 .RE
 285 
 286 .sp
 287 .ne 2
 288 .na
 289 \fB\fBbadcalls\fR\fR
 290 .ad
 291 .sp .6
 292 .RS 4n
 293 The total number of calls rejected by the \fBRPC\fR layer.
 294 .RE
 295 
 296 .sp
 297 .ne 2
 298 .na
 299 \fB\fBbadverfs\fR\fR
 300 .ad
 301 .sp .6
 302 .RS 4n
 303 The number of times the call failed due to a bad verifier in the response.
 304 .RE
 305 
 306 .sp
 307 .ne 2
 308 .na
 309 \fB\fBbadxids\fR\fR
 310 .ad
 311 .sp .6
 312 .RS 4n
 313 The number of times a reply from a server was received which did not correspond
 314 to any outstanding call.
 315 .RE
 316 
 317 .sp
 318 .ne 2
 319 .na
 320 \fB\fBcantconn\fR\fR
 321 .ad
 322 .sp .6
 323 .RS 4n
 324 The number of times the call failed due to a failure to make a connection to
 325 the server.
 326 .RE
 327 
 328 .sp
 329 .ne 2
 330 .na
 331 \fB\fBcantsend\fR\fR
 332 .ad
 333 .sp .6
 334 .RS 4n
 335 The number of times a client was unable to send an \fBRPC\fR request over a
 336 connectionless transport when it tried to do so.
 337 .RE
 338 
 339 .sp
 340 .ne 2
 341 .na
 342 \fB\fBinterrupts\fR\fR
 343 .ad
 344 .sp .6
 345 .RS 4n
 346 The number of times the call was interrupted by a signal before completing.
 347 .RE
 348 
 349 .sp
 350 .ne 2
 351 .na
 352 \fB\fBnewcreds\fR\fR
 353 .ad
 354 .sp .6
 355 .RS 4n
 356 The number of times authentication information had to be refreshed.
 357 .RE
 358 
 359 .sp
 360 .ne 2
 361 .na
 362 \fB\fBnomem\fR\fR
 363 .ad
 364 .sp .6
 365 .RS 4n
 366 The number of times the call failed due to a failure to allocate memory.
 367 .RE
 368 
 369 .sp
 370 .ne 2
 371 .na
 372 \fB\fBretrans\fR\fR
 373 .ad
 374 .sp .6
 375 .RS 4n
 376 The number of times a call had to be retransmitted due to a timeout while
 377 waiting for a reply from the server. Applicable only to \fBRPC\fR over
 378 connection-less transports.
 379 .RE
 380 
 381 .sp
 382 .ne 2
 383 .na
 384 \fB\fBtimeouts\fR\fR
 385 .ad
 386 .sp .6
 387 .RS 4n
 388 The number of times a call timed out while waiting for a reply from the server.
 389 .RE
 390 
 391 .sp
 392 .ne 2
 393 .na
 394 \fB\fBtimers\fR\fR
 395 .ad
 396 .sp .6
 397 .RS 4n
 398 The number of times the calculated time-out value was greater than or equal to
 399 the minimum specified time-out value for a call.
 400 .RE
 401 
 402 .sp
 403 .LP
 404 The client \fBNFS\fR display shows the number of calls sent and rejected, as
 405 well as the number of times a \fBCLIENT\fR handle was received (\fBclgets\fR),
 406 the number of times the \fBCLIENT\fR handle cache had no unused entries
 407 (\fBcltoomany\fR), as well as a count of the various calls and their respective
 408 percentages.
 409 .sp
 410 .LP
 411 The client \fBNFS_ACL\fR display shows the counts and percentages for the
 412 various calls that were made.
 413 .sp
 414 .LP
 415 The \fB-m\fR option includes information about mount flags set by mount
 416 options, mount flags internal to the system, and other mount information. See
 417 \fBmount_nfs\fR(1M).
 418 .sp
 419 .LP
 420 The following mount flags are set by mount options:
 421 .sp
 422 .ne 2
 423 .na
 424 \fB\fBgrpid\fR\fR
 425 .ad
 426 .sp .6
 427 .RS 4n
 428 System V group id inheritance.
 429 .RE
 430 
 431 .sp
 432 .ne 2
 433 .na
 434 \fB\fBhard\fR\fR
 435 .ad
 436 .sp .6
 437 .RS 4n
 438 Hard mount.
 439 .RE
 440 
 441 .sp
 442 .ne 2
 443 .na
 444 \fB\fBintr\fR\fR
 445 .ad
 446 .sp .6
 447 .RS 4n
 448 Interrupts allowed on hard mount.
 449 .RE
 450 
 451 .sp
 452 .ne 2
 453 .na
 454 \fB\fBllock\fR\fR
 455 .ad
 456 .sp .6
 457 .RS 4n
 458 Local locking being used (no lock manager).
 459 .RE
 460 
 461 .sp
 462 .ne 2
 463 .na
 464 \fB\fBnoac\fR\fR
 465 .ad
 466 .sp .6
 467 .RS 4n
 468 Client is not caching attributes.
 469 .RE
 470 
 471 .sp
 472 .ne 2
 473 .na
 474 \fB\fBnointr\fR\fR
 475 .ad
 476 .sp .6
 477 .RS 4n
 478 No interrupts allowed on hard mount.
 479 .RE
 480 
 481 .sp
 482 .ne 2
 483 .na
 484 \fB\fBnocto\fR\fR
 485 .ad
 486 .sp .6
 487 .RS 4n
 488 No close-to-open consistency.
 489 .RE
 490 
 491 .sp
 492 .ne 2
 493 .na
 494 \fB\fBretrans\fR\fR
 495 .ad
 496 .sp .6
 497 .RS 4n
 498 \fBNFS\fR retransmissions.
 499 .RE
 500 
 501 .sp
 502 .ne 2
 503 .na
 504 \fB\fBrpctimesync\fR\fR
 505 .ad
 506 .sp .6
 507 .RS 4n
 508 \fBRPC\fR time sync.
 509 .RE
 510 
 511 .sp
 512 .ne 2
 513 .na
 514 \fB\fBrsize\fR\fR
 515 .ad
 516 .sp .6
 517 .RS 4n
 518 Read buffer size in bytes.
 519 .RE
 520 
 521 .sp
 522 .ne 2
 523 .na
 524 \fB\fBsec\fR\fR
 525 .ad
 526 .sp .6
 527 .RS 4n
 528 \fBsec\fR has one of the following values:
 529 .sp
 530 .ne 2
 531 .na
 532 \fB\fBdh\fR\fR
 533 .ad
 534 .sp .6
 535 .RS 4n
 536 \fBdes\fR-style authentication (encrypted timestamps).
 537 .RE
 538 
 539 .sp
 540 .ne 2
 541 .na
 542 \fB\fBkrb5\fR\fR
 543 .ad
 544 .sp .6
 545 .RS 4n
 546 \fBkerberos v5\fR-style authentication.
 547 .RE
 548 
 549 .sp
 550 .ne 2
 551 .na
 552 \fB\fBkrb5i\fR\fR
 553 .ad
 554 .sp .6
 555 .RS 4n
 556 \fBkerberos v5\fR-style authentication with integrity.
 557 .RE
 558 
 559 .sp
 560 .ne 2
 561 .na
 562 \fB\fBkrb5p\fR\fR
 563 .ad
 564 .sp .6
 565 .RS 4n
 566 \fBkerberos v5\fR-style authentication with privacy.
 567 .RE
 568 
 569 .sp
 570 .ne 2
 571 .na
 572 \fB\fBnone\fR\fR
 573 .ad
 574 .sp .6
 575 .RS 4n
 576 No authentication.
 577 .RE
 578 
 579 .sp
 580 .ne 2
 581 .na
 582 \fB\fBshort\fR\fR
 583 .ad
 584 .sp .6
 585 .RS 4n
 586 Short hand UNIX-style authentication.
 587 .RE
 588 
 589 .sp
 590 .ne 2
 591 .na
 592 \fB\fBsys\fR\fR
 593 .ad
 594 .sp .6
 595 .RS 4n
 596 UNIX-style authentication (UID, GID).
 597 .RE
 598 
 599 .RE
 600 
 601 .sp
 602 .ne 2
 603 .na
 604 \fB\fBsoft\fR\fR
 605 .ad
 606 .sp .6
 607 .RS 4n
 608 Soft mount.
 609 .RE
 610 
 611 .sp
 612 .ne 2
 613 .na
 614 \fB\fBtimeo\fR\fR
 615 .ad
 616 .sp .6
 617 .RS 4n
 618 Initial \fBNFS\fR timeout, in tenths of a second.
 619 .RE
 620 
 621 .sp
 622 .ne 2
 623 .na
 624 \fB\fBwsize\fR\fR
 625 .ad
 626 .sp .6
 627 .RS 4n
 628 Write buffer size in bytes.
 629 .RE
 630 
 631 .sp
 632 .LP
 633 The following mount flags are internal to the system:
 634 .sp
 635 .ne 2
 636 .na
 637 \fB\fBacl\fR\fR
 638 .ad
 639 .sp .6
 640 .RS 4n
 641 Server supports \fBNFS_ACL\fR.
 642 .RE
 643 
 644 .sp
 645 .ne 2
 646 .na
 647 \fB\fBdown\fR\fR
 648 .ad
 649 .sp .6
 650 .RS 4n
 651 Server is down.
 652 .RE
 653 
 654 .sp
 655 .ne 2
 656 .na
 657 \fB\fBdynamic\fR\fR
 658 .ad
 659 .sp .6
 660 .RS 4n
 661 Dynamic transfer size adjustment.
 662 .RE
 663 
 664 .sp
 665 .ne 2
 666 .na
 667 \fB\fBlink\fR\fR
 668 .ad
 669 .sp .6
 670 .RS 4n
 671 Server supports links.
 672 .RE
 673 
 674 .sp
 675 .ne 2
 676 .na
 677 \fB\fBmirrormount\fR\fR
 678 .ad
 679 .sp .6
 680 .RS 4n
 681 Mounted automatically by means of the \fBmirrormount\fR mechanism.
 682 .RE
 683 
 684 .sp
 685 .ne 2
 686 .na
 687 \fB\fBprinted\fR\fR
 688 .ad
 689 .sp .6
 690 .RS 4n
 691 "Not responding" message printed.
 692 .RE
 693 
 694 .sp
 695 .ne 2
 696 .na
 697 \fB\fBreaddir\fR\fR
 698 .ad
 699 .sp .6
 700 .RS 4n
 701 Use \fBreaddir\fR instead of \fBreaddirplus\fR.
 702 .RE
 703 
 704 .sp
 705 .ne 2
 706 .na
 707 \fB\fBsymlink\fR\fR
 708 .ad
 709 .sp .6
 710 .RS 4n
 711 Server supports symbolic links.
 712 .RE
 713 
 714 .sp
 715 .LP
 716 The following flags relate to additional mount information:
 717 .sp
 718 .ne 2
 719 .na
 720 \fB\fBproto\fR\fR
 721 .ad
 722 .sp .6
 723 .RS 4n
 724 Protocol.
 725 .RE
 726 
 727 .sp
 728 .ne 2
 729 .na
 730 \fB\fBvers\fR\fR
 731 .ad
 732 .sp .6
 733 .RS 4n
 734 \fBNFS\fR version.
 735 .RE
 736 
 737 .sp
 738 .LP
 739 The \fB-m\fR option also provides attribute cache timeout values. The following
 740 fields in \fB-m\fR ouput provide timeout values for attribute cache:
 741 .sp
 742 .ne 2
 743 .na
 744 \fB\fBacdirmax\fR\fR
 745 .ad
 746 .sp .6
 747 .RS 4n
 748 Maximum seconds to hold cached directory attributes.
 749 .RE
 750 
 751 .sp
 752 .ne 2
 753 .na
 754 \fB\fBacdirmin\fR\fR
 755 .ad
 756 .sp .6
 757 .RS 4n
 758 Minimum seconds to hold cached directory attributes.
 759 .RE
 760 
 761 .sp
 762 .ne 2
 763 .na
 764 \fB\fBacregmax\fR\fR
 765 .ad
 766 .sp .6
 767 .RS 4n
 768 Maximum seconds to hold cached file attributes.
 769 .RE
 770 
 771 .sp
 772 .ne 2
 773 .na
 774 \fB\fBacregmin\fR\fR
 775 .ad
 776 .sp .6
 777 .RS 4n
 778 Minimum seconds to hold cached file attributes.
 779 .RE
 780 
 781 .sp
 782 .LP
 783 The following fields in \fB-m\fR output provide failover information:
 784 .sp
 785 .ne 2
 786 .na
 787 \fB\fBcurrserver\fR\fR
 788 .ad
 789 .sp .6
 790 .RS 4n
 791 Which server is currently providing \fBNFS\fR service. See the \fI\fR for
 792 additional details.
 793 .RE
 794 
 795 .sp
 796 .ne 2
 797 .na
 798 \fB\fBfailover\fR\fR
 799 .ad
 800 .sp .6
 801 .RS 4n
 802 How many times a new server has been selected.
 803 .RE
 804 
 805 .sp
 806 .ne 2
 807 .na
 808 \fB\fBnoresponse\fR\fR
 809 .ad
 810 .sp .6
 811 .RS 4n
 812 How many times servers have failed to respond.
 813 .RE
 814 
 815 .sp
 816 .ne 2
 817 .na
 818 \fB\fBremap\fR\fR
 819 .ad
 820 .sp .6
 821 .RS 4n
 822 How many times files have been re-evaluated to the new server.
 823 .RE
 824 
 825 .sp
 826 .LP
 827 The fields in \fB-m\fR output shown below provide information on dynamic
 828 retransmissions. These items are displayed only where dynamic retransmission is
 829 in use.
 830 .sp
 831 .ne 2
 832 .na
 833 \fB\fBcur\fR\fR
 834 .ad
 835 .sp .6
 836 .RS 4n
 837 Current backed-off retransmission value, in milliseconds.
 838 .RE
 839 
 840 .sp
 841 .ne 2
 842 .na
 843 \fB\fBdev\fR\fR
 844 .ad
 845 .sp .6
 846 .RS 4n
 847 Estimated deviation, in milliseconds.
 848 .RE
 849 
 850 .sp
 851 .ne 2
 852 .na
 853 \fB\fBsrtt\fR\fR
 854 .ad
 855 .sp .6
 856 .RS 4n
 857 The value for the smoothed round-trip time, in milliseconds.
 858 .RE
 859 
 860 .SH EXIT STATUS
 861 .sp
 862 .LP
 863 The following exit values are returned:
 864 .sp
 865 .ne 2
 866 .na
 867 \fB\fB0\fR\fR
 868 .ad
 869 .sp .6
 870 .RS 4n
 871 Successful completion.
 872 .RE
 873 
 874 .sp
 875 .ne 2
 876 .na
 877 \fB\fB>0\fR\fR
 878 .ad
 879 .sp .6
 880 .RS 4n
 881 An error occurred.
 882 .RE
 883 
 884 .SH SEE ALSO
 885 .sp
 886 .LP
 887 \fBmount_nfs\fR(1M), \fBattributes\fR(5)
 888 .sp
 889 .LP
 890 \fI\fR
 891 .sp
 892 .LP
 893 \fI\fR