This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Ways to Monitor NFS Calls from Client


On 08/22/2016 10:49 PM, Lee Eric wrote:
> Hi David,
> 
> Thanks for your information and I just gave a try on nfs.proc.open
> which is working fine. However, I have some questions about the return
> values.
> 
> from the tapset manual nfs.proc.open has 6 return values so how do I
> know the types of those return values? For instance, how do I look up
> the return value type of prot?

Those aren't really return values, we call those values 'convenience
variables'. A 'nfs.proc.open' probe hits when the corresponding kernel
function ("nfs_open") is called. Systemtap tries to provide convenience
variables - variables/values that someone might need when that probe hits.

As far as types go, the easiest thing to do might be to look at the
probe source. For nfs.proc.open, it appears that those values are all
binary values, except for 'filename'. 'prot' is the protocol number. You
can use the sock_prot_num2str() function to convert that protocol number
to a string value if you'd like.

-- 
David Smith
dsmith@redhat.com
Red Hat
http://www.redhat.com
256.217.0141 (direct)
256.837.0057 (fax)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]