Filter out dtrace(1) probes

Ash Gokhale ashfixit at gmail.com
Fri Aug 17 13:35:29 UTC 2018


>
>
> > On 17 Aug 2018, at 00:49, Farhan Khan <khanzf at gmail.com> wrote:
> >
> > Hi all,
> >
> > Is it possible to filter out probes?
> > For example, if I did:
> >
> > dtrace -n 'fbt:kernel::entry { something_here }'
>

Sure,  try extending this:

dtrace -n 'fbt:kernel:read*:entry /probefunc != "read_cpu_time"  &&
probefunc != "readdep"/ {@[probefunc]=count();}'

Altough fbt::kernel::entry is going to mach a _lot_ of probes. Unless you
are looking for a simple kernel function use count  this is probably going
to overload the data collection plumbing. You should probably narrow your
probe list based on what you are hunting.  Also fbt:kernel::entry is only
going to get core freebsd calls, excluding all loadable modules  (zfs.ko
..) . if you really want all kernel functions,  use fbt:::entry, as blank
entries are wildcards.


More information about the freebsd-dtrace mailing list