Bug #36652 Mysql server uses 99% cpu when inserting rows in one machine, but not on other
Submitted: 11 May 2008 15:53 Modified: 11 May 2008 19:58
Reporter: Ricardo Sal Email Updates:
Status: Duplicate Impact on me:
None 
Category:MySQL Server: Maria storage engine Severity:S3 (Non-critical)
Version:5.1 maria OS:Windows (Sp3)
Assigned to: CPU Architecture:Any
Tags: XP SP3;cpu usage;tualatin cpu

[11 May 2008 15:53] Ricardo Sal
Description:
I have 2 systems with same type of installation (mysql and client).

On my laptop (dual core, 2GB ram, 80GB disk (max 35MB/s), windows Xp SP2) all run normally.

On my "server" (cpu tualatin 1.3MHz, 640MB ram, 200GB disk (70MB/s), windows XP Sp3) it uses almost 100% cpu during same operations.

On the laptop the client application is the one that uses more cpu while the db idles during the insert operations.
On the server pc, the client usually freezes waiting for each insert to be finished in mysql using 1% cpu while the mysql server uses almost 100%.

I have no idea in how to explain this.

How to repeat:
Maybe installing Sp3...

Suggested fix:
Get me a procedure to debug the situation in order to see what the BD is doing, and send it to you, while mysql uses so much cpu.
[11 May 2008 17:26] Ricardo Sal
Extra information on sequence of commands used:

Starting:
ALTER TABLE planets disABLE KEYS

Several inserts (3k)

Ending:
ALTER TABLE planets enABLE KEYS
optimize table planets (to clean extra space in the index file - bug reported and fixed)
[11 May 2008 19:58] Ricardo Sal
Ok cancel this.

Just found it was the reindexing process that was taking all the cpu.

I think that issue was already reported before.

Thans again