If you do not use a site with a massive level of traffic, then any snapshot of requests launched / completed is unlikely to be representative. There are also problems in terms of correlating the request with the script that spawned it.
I would recommend using your own code - use auto-prepend to define a wrapper around mysql_query() , then you can implement your own log, which:
- creates a log entry before running the script (most log entries are created later - not very convenient if the code that writes the failure log)
- writes the script that caused the request and the request itself
- records memory usage before
- records the same facts after time
Then do a recursive search and replace the source code to replace the mysql_query() calls with your wrapper function.
source share