vtrace (kernel tracing)

weiser.pa at arisia.xerox.com weiser.pa at arisia.xerox.com
Thu Dec 21 17:06:34 AEST 1989


I am trying to figure out what the various parts of the kernel is doing to
us.  I am particularly interested, right now, in paging and swapping
events.  I want to see the actual events, not the summaries in vmstat.

There appears to be a feature of the kernel called "vtrace" that will
trace kernel events.  Does anyone have any experience with this?  "man
vtrace" reports that there is "No manual entry for vtrace."  Note that
this is not "trace" or "ptrace".

Apparently, what you do is compile a kernel with TRACE "ifdef"-ed.  By
issuing vtrace syscall (115), a user process (running as root) can read
the trace buffer.  The user process can than do anything it wants nts.

Is this correct?  Can anyone point me to C code that uses vtrace?  We have
a SUNOS source licence.

Thanks
Bob Hagmann (hagmann at xerox.com)
Mark Weiser (weiser at xerox.com)



More information about the Comp.sys.sun mailing list