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: systemtap to trace source of syscall error?


"Richard W.M. Jones" <rjones@redhat.com> writes:

> [...]
> Unfortunately my reproducer is quite hard to trigger[1], and it's
> probably happening somewhere inside FUSE, so I was hoping for a way to
> just grab say a stack trace when it happens.  Oh well ...

The problem is that by the time the error propagates to userspace, the
kernel stack has been unwound, so there is nothing to trace exactly.

However, if you suspect the FUSE subsystem, you could probe there
instead, not at the syscall boundary.  For example,

% stap -L 'module("fuse").function("*").return'
[... many functions ...]

% sudo stap -vt -e '
probe module("fuse").function("*").return {
  if (@defined($return) && $return < 0) println(pp()," ",$return)
}'

This should give you a list of functions that have a <0 result code.

- FChE


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