summaryrefslogtreecommitdiffstats
path: root/utils/nfsstat
Commit message (Collapse)AuthorAgeFilesLines
* nfsstat: reorder nfs4 stats for 2.6.39Benny Halevy2011-06-221-2/+2
| | | | | Signed-off-by: Benny Halevy <benny@tonian.com> Signed-off-by: Steve Dickson <steved@redhat.com>
* nfsstat: reorder nfs4 stats for 2.6.38 and upBenny Halevy2011-05-231-4/+1
| | | | | | | | match order in 2.6.38, 2.6.39 (-rc3) and development tree while at it, get rid of obsolete ds_write and ds_commit Signed-off-by: Benny Halevy <bhalevy@panasas.com> Signed-off-by: Steve Dickson <steved@redhat.com>
* nfsstat: Output headings mislabledSteve Dickson2011-04-261-1/+1
| | | | | | | | The badclnt and badauth headers were reversed when the server side rpc stats (-s -o rpc) were displayed. Signed-off-by: Steve Dickson <steved@redhat.com>
* nfs-utils: nfsstat: has_stats() does not function correctly for NFSv4 client ↵Harshula Jayasuriya2010-11-222-71/+59
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | stats The NFSv4 client procs/ops in "struct rpc_procinfo nfs4_procedures" is used to generate the NFS client stats interface: ------------------------------------------------------------ net 0 0 0 0 rpc 15 0 0 proc2 18 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 proc3 22 0 2 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 2 1 0 proc4 42 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 ------------------------------------------------------------ Note, for proc4, the number 42. That is the number of stats that follow on the same line. Currently nfsstat's has_stats() relies on this number to be equal to CLTPROC4_SZ. Unfortunately this is not the case. I have changed has_stats() not to rely on these two values being equal. This should also allow nfsstat to work with different kernel versions that expose a different number of NFS client ops. * Fix has_stats() * Stop print_clnt_list() printing server stats! * Describe the option -3 and -4 completely in the nfsstat manpage. Signed-off-by: Harshula Jayasuriya <harshula@redhat.com> Signed-off-by: Steve Dickson <steved@redhat.com>
* nfsstat: add release_lockowner to client statsBenny Halevy2010-09-091-1/+2
| | | | Signed-off-by: Benny Halevy <bhalevy@panasas.com>
* Removed warnings from nfsstat.cSteve Dickson2010-08-091-3/+3
| | | | | | | | | | | | | | | | | | | | | | nfsstat.c: In function 'print_callstats': nfsstat.c:797: warning: comparison between signed and unsigned integer expressions nfsstat.c:801: warning: comparison between signed and unsigned integer expressions nfsstat.c:802: warning: comparison between signed and unsigned integer expressions nfsstat.c:805: warning: comparison between signed and unsigned integer expressions nfsstat.c: In function 'print_callstats_list': nfsstat.c:821: warning: comparison between signed and unsigned integer expressions nfsstat.c:828: warning: comparison between signed and unsigned integer expressions nfsstat.c: In function 'unpause': nfsstat.c:1111: warning: unused parameter 'sig' Signed-off-by: Steve Dickson <steved@redhat.com>
* nfsstat: use symbolic constants for operation array sizesBenny Halevy2010-02-081-12/+29
| | | | | Signed-off-by: Benny Halevy <bhalevy@panasas.com> Signed-off-by: Steve Dickson <steved@redhat.com>
* Add recalim_complete to client stats.Benny Halevy2010-02-081-2/+3
| | | | | Signed-off-by: Benny Halevy <bhalevy@panasas.com> Signed-off-by: Steve Dickson <steved@redhat.com>
* Augment nfs4 stats to cover new nfs41 client andBenny Halevy2009-08-161-6/+40
| | | | | | | server operations' stats. Signed-off-by: Benny Halevy <bhalevy@panasas.com> Signed-off-by: Steve Dickson <steved@redhat.com>
* The --list option does not work on server stats.Steve Dickson2009-04-081-29/+80
| | | | | | | | | | | | The print_stats_list() routine was using the client's stats to decide whether to display any stats. This did not work when there was only server stats. This patch breaks up print_stats_list into two different routines allowing both server and clients stats to be listed. Signed-off-by: Steve Dickson <steved@redhat.com>
* The server stats were not being updated with theSteve Dickson2009-04-081-1/+5
| | | | | | -Z options causing the stats to be incorrect. Signed-off-by: Steve Dickson <steved@redhat.com>
* Eliminate the displaying zero stats when the explicit protocolSteve Dickson2009-04-081-103/+135
| | | | | | | | | | | | | | | is specified (-2, -3, -4) the -Z and or --list options. When a particular protocol is specified and either the -Z or --list options are used, zeros or blank lines are echoed to the screen when there is not any NFS traffic. This cause any useful data to be scroll off the screen. With this patch only non-zero stats will be shown, which makes the output of these options more condensed and in turn more useful. Signed-off-by: Steve Dickson <steved@redhat.com>
* nfsstat: Add --list flagKevin Constantine2009-04-042-3/+83
| | | | | | | | | nfsstat.c: Adds the --list flag to print information in a list format instead of the standard multi-column format nfsstat.man: Updates the manpage to include the --list flag. Signed-off-by: Kevin Constantine <kevin.constantine@disneyanimation.com> Signed-off-by: Steve Dickson <steved@redhat.com>
* Keep the interval output quite when there is no NFS traffic.Steve Dickson2009-04-041-13/+27
| | | | | | | | | | | | | | The 'nfsstat -Z5' command continually outputs the following when there is no NFS traffic. Client rpc stats: calls retrans authrefrsh 0 0 0 This patch adds code that will keep the interval output quite so real results will not be scrolled of the screen Signed-off-by: Steve Dickson <steved@redhat.com>
* nfsstat: Print diff stats every N secondsKevin Constantine2009-04-042-27/+85
| | | | | | | | | nfsstat.c: Implements an optional "interval" argument to --sleep nfsstat.man: Explains the use of --sleep[interval] Reviewed-By: Greg Banks <gnb@fmeh.org> Signed-off-by: Kevin Constantine <kevin.constantine@disneyanimation.com> Signed-off-by: Steve Dickson <steved@redhat.com>
* The nfsstat program reads /proc/net/rpc/* files to gets info aboutJeff Layton2008-06-231-4/+5
| | | | | | | | | | | | | | | | calls. This info is output as unsigned numbers (at least on any relatively recent kernel). When nfsstat prints these numbers, they are printed as signed integers. When the call counters reach 2^31, things start being printed as negative numbers. This patch changes nfsstat to read and print all counters as unsigned integers. Tested by hacking up a kernel to initialize call counters to 2^31+1. Thanks to Takafumi Miki for the initial version of this patch. Signed-off-by: Jeff Layton <jlayton@redhat.com> Signed-off-by: Steve Dickson <steved@redhat.com>
* nfsstat -m lists all current nfs mounts, with the mount options.Neil Brown2008-06-061-1/+1
| | | | | | | | | | It does this by reading /proc/mounts and looking for mounts of type "nfs". It really should check for "nfs4" as well. For simplicity, just check the first 3 characters of the type. Signed-off-by: NeilBrown <neilb@suse.de> Signed-off-by: Steve Dickson <steved@redhat.com>
* Fixed a couple typos that effected the '--mounts' nfsstat optionSteinar H. Gunderson2008-03-102-2/+2
| | | | | Signed-off-by: Steinar H. Gunderson <sgunderson@bigfoot.com> Signed-off-by: Steve Dickson <steved@redhat.com>
* Fixed typo in the nfsstat command line arugments.Peng Haitao2008-02-261-1/+1
| | | | Signed-off-by: Steve Dickson <steved@redhat.com>
* Added -S/--since to the nfsstat(1) manpageSteve Dickson2007-10-261-1/+21
| | | | | Author: David Richter <richterd@citi.umich.edu> Signed-off-by: Steve Dickson <steved@redhat.com>
* nfsstat: Add -S/--since flag.david m. richter2007-08-161-18/+134
| | | | | | | | | | | | | | | | Read statistics from the file given with -S/--since and display the difference between those and the current statistics. Valid stat files are those in the form of /proc/net/rpc/nfs, /proc/net/rpc/nfsd, or any "pretty" output from nfsstat itself. Statistics that are missing from a "pretty" stat file are treated as zeroes. Similar to Neil Brown's suggestion, one might use this in conjunction with watch(1) like this: $ watch "nfsstat --since /tmp/stats; nfsstat >/tmp/stats" Signed-off-by: David M. Richter <richterd@citi.umich.edu> Signed-off-by: Neil Brown <neilb@suse.de>
* nfsstat: #define stat header labels.david m. richter2007-08-161-20/+35
| | | | | | | | | Make #defines for the stat header labels, use for output, and add to struct statinfo. This will be used by a subsequent patch for -S/--since. Signed-off-by: David M. Richter <richterd@citi.umich.edu> Signed-off-by: Neil Brown <neilb@suse.de>
* nfsstat: Remove some pointer comparisons against global statinfos.david m. richter2007-08-161-12/+15
| | | | | | | | Pass-in an "is_srv" arg instead of doing pointer comparisons against the static statinfo arrays themselves. Signed-off-by: David M. Richter <richterd@citi.umich.edu> Signed-off-by: Neil Brown <neilb@suse.de>
* nfsstat: Obviate and remove copy_stats().david m. richter2007-08-161-25/+18
| | | | | | | | | Rather than copying stats during --sleep, instead introduce a few pointers and rearrange them to avoid the copy. Will be useful with --since, too. Signed-off-by: David M. Richter <richterd@citi.umich.edu> Signed-off-by: Neil Brown <neilb@suse.de>
* nfsstat: rename *_tmp variables to *_old.david m. richter2007-08-161-19/+19
| | | | | | | | | To make a subsequent patch a little clearer, make it explicit that current *_tmp variables are actually always/only the "old" set used in comparisons. Signed-off-by: David M. Richter <richterd@citi.umich.edu> Signed-off-by: Neil Brown <neilb@suse.de>
* nfsstat: include -Z/--sleep in the manpagedavid m. richter2007-08-091-1/+11
| | | | | | | Add a little blurb about -Z/--sleep to the nfsstat manpage. Signed-off-by: David M. Richter <richterd@citi.umich.edu> Signed-off-by: Neil Brown <neilb@suse.de>
* nfsstat: rename --diff-stat to --sleepdavid m. richter2007-08-091-7/+7
| | | | | | | | As per Bruce Fields' suggestion, rename the clunky -D/--diff-stat to the more-intuitive -Z/--sleep. Signed-off-by: David M. Richter <richterd@citi.umich.edu> Signed-off-by: Neil Brown <neilb@suse.de>
* nfsstat: fix a bug in diff_stats()david m. richter2007-08-091-4/+25
| | | | | | | | | Fix a bug in diff_stats() that causes false-positives in has_stats(), which can result in a bunch of zeros being displayed instead of suppressed as intended. Signed-off-by: David M. Richter <richterd@citi.umich.edu> Signed-off-by: Neil Brown <neilb@suse.de>
* nfsstat: add a comment to has_stats()david m. richter2007-08-091-1/+7
| | | | | | | Clarify what has_stats() is actually doing. Signed-off-by: David M. Richter <richterd@citi.umich.edu> Signed-off-by: Neil Brown <neilb@suse.de>
* nfsstat: display 3 additional NFSv4 client op countersdavid m. richter2007-08-091-4/+5
| | | | | | | | | Display three extra NFSv4 client counters that are already exposed in /proc/net/rpc/nfs: GETACL, SETACL, and FS_LOCATIONS. Won't cause trouble on older kernels that might lack those counters. Signed-off-by: David M. Richter <richterd@citi.umich.edu> Signed-off-by: Neil Brown <neilb@suse.de>
* nfsstat: add -D/--diff-statdavid m. richter2007-08-011-2/+91
| | | | | | | | | | | Add -D/--diff-stat: instead of immediately displaying total collected NFS stats and exiting, nfsstat will take a snapshot of current statistics and pause until the user hits ^C, at which point it takes a second snapshot and then prints out the difference of the two; i.e., only the statistics collected during the pause. Signed-off-by: David M. Richter <richterd@citi.umich.edu> Signed-off-by: Neil Brown <neilb@suse.de>
* nfsstat: just declare -D/--diff-stat's variablesdavid m. richter2007-08-011-49/+51
| | | | | | | | Add the temp vars -D/--diff-stat will use. (just using a separate patch to make the next one easier to read) Signed-off-by: David M. Richter <richterd@citi.umich.edu> Signed-off-by: Neil Brown <neilb@suse.de>
* nfsstat: use macros to declare struct statinfo arraysdavid m. richter2007-08-011-22/+30
| | | | | | | | | Use macros to build the arrays of struct statinfos. This will make adding the extra set of temporary variables needed by -D/--diff-stat much easier. Signed-off-by: David M. Richter <richterd@citi.umich.edu> Signed-off-by: Neil Brown <neilb@suse.de>
* nfsstat: standardize naming of opcount arraysdavid m. richter2007-08-011-30/+30
| | | | | | | | | | Standardized Naming 2: Make the client and server "call counts" arrays' variable names reflect/include the actual text labels from the /proc files -- e.g., "cltv2info" becomes "cltproc2info". A subsequent patch will rely on this naming scheme. Signed-off-by: David M. Richter <richterd@citi.umich.edu> Signed-off-by: Neil Brown <neilb@suse.de>
* nfsstat: standardize naming of server variablesdavid m. richter2007-08-011-40/+40
| | | | | | | | | | Standardized Naming 1: Instead of having a variety of different server-related variable name prefixes ("srv", "svr", "svc", "SVC"), set them all to "srv" or "SRV". A subsequent patch will rely on this naming scheme. Signed-off-by: David M. Richter <richterd@citi.umich.edu> Signed-off-by: Neil Brown <neilb@suse.de>
* nfsstat: add get_stats()david m. richter2007-08-011-21/+17
| | | | | | | | Share some of the existing statistics-gathering code by folding it into a function, get_stats(). Signed-off-by: David M. Richter <richterd@citi.umich.edu> Signed-off-by: Neil Brown <neilb@suse.de>
* nfsstat: add has_stats()david m. richter2007-08-011-6/+14
| | | | | | | | To help readability, add has_stats() and use it when deciding whether to print. Signed-off-by: David M. Richter <richterd@citi.umich.edu> Signed-off-by: Neil Brown <neilb@suse.de>
* Various minor manpage fixes.Kevin Coffman2007-02-091-3/+3
| | | | | | | | | | | | | Signed-off-by: Steinar H. Gunderson <sgunderson@bigfoot.com> Signed-off-by: Kevin Coffman <kwc@citi.umich.edu> This mostly takes care of the difference between - and \-; in man pages, the former is hyphen (which indicates, among others, that a line might be split at that point), while the latter is a dash. For options, the latter is correct. There's also one minor grammatical fix. Signed-off-by: Neil Brown <neilb@suse.de>
* Various minor manpage fixes.Steinar H. Gunderson2007-02-051-18/+18
| | | | | | | | | | This mostly takes care of the difference between - and \-; in man pages, the former is hyphen (which indicates, among others, that a line might be split at that point), while the latter is a dash. For options, the latter is correct. There's also one minor grammatical fix.
* Assorted man page fixesNeil Brown2006-10-241-1/+1
| | | | Mostly thanks to Sylvain Cherrier <sylvain.cherrier@free.fr>
* This patch adds code to nfsstat to read /proc/net/rpc/nfsd for nfsv4 server ↵Shankar Anand2006-07-051-1/+18
| | | | | | statistics and print them. Submitted by: Shankar Anand <shanand@novell.com>
* Fix typos in various man pages.Steinar H. Gunderson2006-07-051-3/+3
|
* Remove **/Makefile.in, aclocal.m4, configure, andNeil Brown2006-04-171-552/+0
| | | | | | support/include/config.h.in from source control These are auto autogenerated by aclocal -I aclocal ; autoheader ; automake ; autoconf
* 2006-04-10 "Kevin Coffman" <kwc@citi.umich.edu>neilbrown2006-04-101-0/+2
| | | | | Check for sufficient version of librpcsecgss and libgssapi in configure.in
* 2006-04-10 "Kevin Coffman" <kwc@citi.umich.edu>neilbrown2006-04-101-0/+2
| | | | | Update aclocal/tcp-wrappers.m4 to define HAVE_LIBWRAP and HAVE_TCP_WRAPPERS as appropriate.
* aclocal/autoconf/automake, properly this time.neilbrown2006-03-281-0/+4
|
* Remove all the Makefilesneilbrown2005-12-201-33/+0
|
* More automake stuffneilbrown2005-12-201-0/+544
|
* Autogen updateneilbrown2005-12-202-1/+15
|
* added version output control (-2 -3 -4)gmorris2005-04-121-32/+118
|