How to reset the root passwordhttp://dev.mysql.com/doc/refman/5.0/en/resetting-permissions.html How to view what queries / databases are consuming the CPUmysqladmin -u root -p processlist Slow queriesI had a 19,000-row table, which was taking 5 seconds to return a simple COUNT(*). After much mucking around, I realized that it had a complex primary key on two columns. I added an index to the one of those columns - the column that the scripts in question were querying - and that solved the problem. COUNT(*) takes the expected 0.02 seconds, and the report went from 2 minutes to about 5 seconds. This website belongs to Christopher Jastram. |