Comments on: Don’t forget about SHOW PROFILES http://www.xaprb.com/blog/2009/05/31/dont-forget-about-show-profiles/ Stay curious! Thu, 02 May 2013 12:36:53 +0000 hourly 1 http://wordpress.org/?v=3.5.1 By: Mark Leith http://www.xaprb.com/blog/2009/05/31/dont-forget-about-show-profiles/#comment-16493 Mark Leith Mon, 01 Jun 2009 11:45:53 +0000 http://www.xaprb.com/blog/?p=1012#comment-16493 It’s important to note that SHOW PROFILES is not reliable when looking at CPU timings on a production machine – as they are *process* wide (and hence include CPU time for other threads executing whilst you run the profile).

So don’t rely on anything but the plain timings (which are correct), such as CPU times, context switches etc. on a production instance. :)

]]>
By: Rohit Nadhani http://www.xaprb.com/blog/2009/05/31/dont-forget-about-show-profiles/#comment-16491 Rohit Nadhani Mon, 01 Jun 2009 04:11:08 +0000 http://www.xaprb.com/blog/?p=1012#comment-16491 The “Query Profiler” feature of the latest version of SQLyog Enterprise does all the manual book-keeping required for getting SHOW PROFILE data for an individual query. The user gets to see the profiling info along with the result-set.

]]>
By: Mark Callaghan http://www.xaprb.com/blog/2009/05/31/dont-forget-about-show-profiles/#comment-16489 Mark Callaghan Mon, 01 Jun 2009 03:35:39 +0000 http://www.xaprb.com/blog/?p=1012#comment-16489 The way I see it there are two roles that may or may not overlap depending on the size/complexity of your mysql deployment. The first role is responsible for the health of the server and uses SHOW STATUS, SHOW USER_STATISTICS and SHOW TABLE_STATISTICS to determine system performance and resource consumption over time. The second role is concerned with the performance of individual statements over time.

On a large deployment, the first role doesn’t have time to do the tasks (query tuning) of the second role. There is time to identity accounts that have performance problems and occasionally time to identify problem queries after they have become a problem. But there is no time to tune queries before the fact.

On other deployments, both roles may be done by the same people.

I don’t use SHOW PROFILES. I frequently identify accounts with performance problems and occasionally identiy the problem queries, but I have neither the time nor the privileges to fix those queries.

]]>
By: Ronald Bradford http://www.xaprb.com/blog/2009/05/31/dont-forget-about-show-profiles/#comment-16488 Ronald Bradford Mon, 01 Jun 2009 00:40:09 +0000 http://www.xaprb.com/blog/?p=1012#comment-16488 While I agree SHOW PROFILES is valuable to gleen some more information about a query, regardless of knowing about the MySQL Source code, and you get better timing then the MySQL client 1/10ms response, SHOW PROFILES exposes internal messaging which is sometimes a bit misleading.

I wonder if for 5.1, MySQL actually took the time to clean up some of the messaging displayed by SHOW PROFILES, or if they added some more data points to expose some more instrumentation to the end user.

]]>