From: Benny Halevy Subject: Re: [PATCH] nfsstat: reorder nfs4 stats for 2.6.38 and up Date: Wed, 27 Apr 2011 23:33:23 +0300 Message-ID: <4DB87D93.8040205@panasas.com> References: <1303461980-6731-1-git-send-email-bhalevy@panasas.com> <23EF6F61-46F2-431B-8A44-A3E941688D65@oracle.com> <4DB7A084.2060009@panasas.com> <1303913806.13195.3.camel@lade.trondhjem.org> <4DB86605.3000304@panasas.com> <1303930718.23640.6.camel@lade.trondhjem.org> <4DB87B96.8090400@panasas.com> <1303936194.28589.2.camel@lade.trondhjem.org> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Cc: Chuck Lever , steved@redhat.com, linux-nfs@vger.kernel.org To: Trond Myklebust Return-path: Received: from daytona.panasas.com ([67.152.220.89]:3550 "EHLO daytona.panasas.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756854Ab1D0Udc (ORCPT ); Wed, 27 Apr 2011 16:33:32 -0400 In-Reply-To: <1303936194.28589.2.camel-SyLVLa/KEI9HwK5hSS5vWB2eb7JE58TQ@public.gmane.org> Sender: linux-nfs-owner@vger.kernel.org List-ID: On 2011-04-27 23:29, Trond Myklebust wrote: > On Wed, 2011-04-27 at 23:24 +0300, Benny Halevy wrote: >> On 2011-04-27 21:58, Trond Myklebust wrote: >>> On Wed, 2011-04-27 at 21:52 +0300, Benny Halevy wrote: >>>> On 2011-04-27 17:16, Trond Myklebust wrote: >>>>> On Wed, 2011-04-27 at 07:50 +0300, Benny Halevy wrote: >>>>>> On 2011-04-25 17:11, Chuck Lever wrote: >>>>>>> Hey all- >>>>>>> >>>>>>> So what are we going to do when adding NFSv4.2 to this mix? Will we >>>>>>> then have to freeze both the NFSv4.1 and NFSv4.0 procedure API in the >>>>>>> kernel? Seems painful. >>>>>> >>>>>> Good question. >>>>>> How about changing the stat pseudo-file format to include an op >>>>>> identifier along with its respective counter, printing a line per op? >>>>> >>>>> We already have that in /proc/self/mountstats >>>>> >>>>> >>>> >>>> You mean /proc/self/status? >>> >>> No. >> >> So can you please explain what you meant by the /proc/self/mountstats >> example? >> >> This is what I see: >> >> $ head -3 /proc/self/mountstats >> device rootfs mounted on / with fstype rootfs >> device /proc mounted on /proc with fstype proc >> device /sys mounted on /sys with fstype sysfs >> >> Benny > > Try mounting an NFS partition. When I do, I also get: > > device ila.local:/raid0/data/vol0 mounted on /net/ila.local/raid0/data/vol0 with fstype nfs statvers=1.0 > opts: rw,vers=3,rsize=32768,wsize=32768,namlen=255,acregmin=3,acregmax=60,acdirmin=30,acdirmax=60,hard,proto=tcp,timeo=600,retrans=2,sec=sys,mountaddr=192.168.1.20,mountvers=3,mountport=993,mountproto=udp > age: 3 > caps: caps=0x3fcf,wtmult=4096,dtsize=4096,bsize=0,namlen=255 > sec: flavor=1,pseudoflavor=1 > events: 4 101 0 0 6 0 107 0 0 0 0 0 12 0 0 0 0 0 0 0 0 0 0 0 0 > bytes: 0 0 0 0 0 0 0 0 > RPC iostats version: 1.0 p/v: 100003/3 (nfs) > xprt: tcp 826 1 1 0 2 24 24 0 24 0 > per-op statistics > NULL: 0 0 0 0 0 0 0 0 > GETATTR: 6 6 0 752 672 0 1 1 > SETATTR: 0 0 0 0 0 0 0 0 > LOOKUP: 0 0 0 0 0 0 0 0 > ACCESS: 5 5 0 692 600 0 1 1 > READLINK: 0 0 0 0 0 0 0 0 > READ: 0 0 0 0 0 0 0 0 > WRITE: 0 0 0 0 0 0 0 0 > CREATE: 0 0 0 0 0 0 0 0 > MKDIR: 0 0 0 0 0 0 0 0 > SYMLINK: 0 0 0 0 0 0 0 0 > MKNOD: 0 0 0 0 0 0 0 0 > REMOVE: 0 0 0 0 0 0 0 0 > RMDIR: 0 0 0 0 0 0 0 0 > RENAME: 0 0 0 0 0 0 0 0 > LINK: 0 0 0 0 0 0 0 0 > READDIR: 0 0 0 0 0 0 0 0 > READDIRPLUS: 7 7 0 1112 13832 0 35 36 > FSSTAT: 1 1 0 104 84 0 1 1 > FSINFO: 2 2 0 208 160 0 0 0 > PATHCONF: 1 1 0 104 56 0 0 0 > COMMIT: 0 0 0 0 0 0 0 0 > > Providing this kind of statistic was _exactly_ the reason for adding > mountstats in the first place. Ah, cool! This makes much more sense now :) Benny