dtrace

844 views

Published on

Published in: Technology, Business
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
844
On SlideShare
0
From Embeds
0
Number of Embeds
17
Actions
Shares
0
Downloads
0
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

dtrace

  1. 1. dtrace
  2. 2. DTrace is a comprehensive dynamic tracing framework created by Sun Microsystems. DTrace is designed to give operational insights that allow users to tune and troubleshoot applications and the OS itself. … there is minimal probe effect and no performance impact associated with any disabled probe; this is important since there are tens of thousands of DTrace probes that can be enabled.
  3. 5. kernel userland jvm Custom App
  4. 6. <ul><li>#!/usr/sbin/dtrace –qs </li></ul><ul><li>BEGIN </li></ul><ul><li>{ </li></ul><ul><li>printf(&quot;size time &quot;); </li></ul><ul><li>} </li></ul><ul><li>syscall::read:entry </li></ul><ul><li>/execname == &quot;httpd&quot;/ </li></ul><ul><li>{ </li></ul><ul><ul><li>self->start = timestamp; </li></ul></ul><ul><li>} </li></ul><ul><li>syscall::read:return </li></ul><ul><li>/self->start/ </li></ul><ul><li>{ </li></ul><ul><ul><li>printf(&quot;%d %d &quot;, arg0, timestamp - self->start); </li></ul></ul><ul><ul><li>self->start = 0; </li></ul></ul><ul><li>} </li></ul>
  5. 7. if you get one thing from this install dtrace toolkit on Solaris 10
  6. 8. DEMO

×