Re: CPU usage 99% - and query very slow - help
Posted by:
Rick James
Date: August 04, 2012 01:36PM
High CPU --> need to find worst query/queries --> add index and/or redesign query
You have the slow log; find the worst
To assist in analyzing slow SELECTs, please provide
* SHOW CREATE TABLE tbl\G -- engine, indexes
* SHOW TABLE STATUS LIKE 'tbl'\G -- sizes
* EXPLAIN SELECT ...\G -- clues of inefficiencies
* SHOW VARIABLES LIKE '%buffer%'; -- cache size
and surround them with [ code ] and [ / code ]
How much RAM do you have?
> all tables have indexes
Need the details.
> and are optimizaed every 3 days.
Usually a waste to do it that often. Less than 1% of tables need periodic OPTIMIZE. Monthly is probably often enough. (Again, need details to comment further.)
Subject
Views
Written By
Posted
5190
August 03, 2012 10:49AM
Re: CPU usage 99% - and query very slow - help
2063
August 04, 2012 01:36PM
2819
August 06, 2012 01:04PM
2215
August 15, 2012 03:09AM
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.