tags:

views:

130

answers:

3

Is there any way to see an overview of what kind of queries are spent the most time on every day on mysql?

+1  A: 

You can always set up query logging as described here:
http://dev.mysql.com/doc/refman/5.0/en/query-log.html

petr k.
+4  A: 

Yes, mysql can create a slow query log. You'll need to start mysqld with the --log-slow-queries flag:

mysqld --log-slow-queries=/path/to/your.log

Then you can parse the log using mysqldumpslow:

mysqldumpslow /path/to/your.log

More info is here (http://dev.mysql.com/doc/refman/5.0/en/slow-query-log.html).

Gordon Wilson