MySQL has a nice tool called ‘mysqldumpslow’. It parses and summarizes the MySQL slow query log.
An interesting tool, however in most cases you’ll want to solve slow queries which reoccur the most, thus sorting the slow query log by count.
Read More