# MYSQL Server consuming a lot



## almobd3 (Aug 20, 2011)

Hello, 

I'm facing a problem and I don't know how to solve it. The problem is that my MYSQL Server is consuming a lot, this is a line from TOP screen. I hope that you know the answer.


```
1245 mysql      95  44    0   511M   343M ucond  12   0:00 200.83% mysqld
```

The server is:
Processor: DUAL Xeon E5620 Processor 2.4Ghz 12MB Cache
Ram: 12 GB DDR3 

Thank you in advance


----------



## Savagedlight (Aug 21, 2011)

Memory usage seems relatively small (mine eats about 4GB), while the WCPU field looks rather harsh.
You should check how many queries are being executed, and if any of them could be optimized (by using indexes or rewriting them).
Should also check if there's something hammering the server with connections, such as a script or website which makes a new connection for every request.


----------



## SirDice (Aug 22, 2011)

Time to start tuning. How is MySQL installed? Do you use InnoDB, MyISAM or both? 

What other tuning have you done in my.cnf?

Have a look at this script: http://day32.com/MySQL/tuning-primer.sh


----------

