MySQL Forums
Forum List  »  Performance

Re: Monitoring large resultsets
Posted by: Aftab Khan
Date: July 12, 2012 02:19AM

>For example, a lot of the queries I see in the log are select count(id) which return only 1 int row but take 6s when the server is busy.

We don't know how did you process slow query log, try this:

mysqldumpslow -s t -t 5 /path/to/slow_query_log

Provide use with EXPLAIN SELECT for slow queries and SHOW CREATE TABLE info and wrap out it inside [ CODE ] .... [/ CODE ] without spaces inside brackets[].

>I suspect some queries are retrieving huges resultsets. Cache is pruned because it cannot hold results of that size. Php holds the results array in memory.

To help find how much memory is allocated to per-thread/global buffers and see how much data is sent/received over the time etc..

Provide us output of:

SHOW GLOBAL VARIABLES;
SHOW GLOBAL STATUS;

Options: ReplyQuote


Subject
Views
Written By
Posted
2203
July 10, 2012 10:26PM
1202
July 11, 2012 02:01AM
Re: Monitoring large resultsets
975
July 12, 2012 02:19AM
1026
July 12, 2012 03:37AM
1018
July 12, 2012 04:13AM
1069
July 12, 2012 05:49AM
1209
July 12, 2012 07:02AM
1026
July 13, 2012 07:50PM
1016
July 14, 2012 02:43AM
979
July 12, 2012 08:13AM
988
July 12, 2012 08:55AM
1060
July 12, 2012 12:12PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.