Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re^2: Sun Solaris (SPARC processor) + Threads + performance/optimization

by JSchmitz (Canon)
on Apr 15, 2009 at 18:20 UTC ( #757756=note: print w/ replies, xml ) Need Help??


in reply to Re: Sun Solaris (SPARC processor) + Threads + performance/optimization
in thread Sun Solaris (SPARC processor) + Threads + performance/optimization

Isn't this something that would be well suited for DTrace? I am assuming you are running Solaris 10... Sorry I was in a meeting the first go around Brendan Gregg would do something like this

#!/usr/sbin/dtrace -s /* * mysqld_pid_etime.d - measure mysqld query execution latency. * Written for Solaris 10 (needs DTrace). * * 01-Jun-2007, ver 0.50 * * USAGE: ./mysqld_pid_etime.d -p `pgrep -x mysqld` * * This prints distribution plots of the elapsed time during the execu +tion * of MySQL statements, with a plot for each query string traced. This * measure the execution stage only, not the parse or plan stages. * * This is written using the DTrace pid provider, which means it uses +an * unstable interface and is likely to stop working for future version +s of * mysql (this was tested on mysql-5.1.17-beta). * * 01-Jun-2007 Brendan Gregg Created this. */ #pragma D option quiet dtrace:::BEGIN { printf("Tracing... Hit Ctrl-C to end.\n"); } pid$target::*mysql_parse*:entry { self->query = copyinstr(arg1); } pid$target::*mysql_execute_command*:entry { self->start = timestamp; } pid$target::*mysql_execute_command*:return /self->start/ { this->elapsed = timestamp - self->start; @time[self->query] = quantize(this->elapsed); self->query = 0; self->start = 0; } dtrace:::END { printf("MySQL Query execution latency (ns):\n"); printa(@time); } </

There is a lot more detail to be found HERE

Hope this points you in the right direction. Cheers - Jeffery


Comment on Re^2: Sun Solaris (SPARC processor) + Threads + performance/optimization
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://757756]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (10)
As of 2015-07-31 20:07 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (281 votes), past polls