# MYSQL performance issue?

**URL:** <https://forums.percona.com/t/mysql-performance-issue/1031>\
**Category:** Other MySQL® Questions\
**Created:** [December 10, 2008, 8:32am UTC](https://forums.percona.com/t/mysql-performance-issue/1031 "2008-12-10T08:32:02Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![manantsoa](https://avatars.discourse-cdn.com/v4/letter/m/b3f665/32.png) [@manantsoa](https://forums.percona.com/u/manantsoa)\
**Post date:** [December 10, 2008, 8:32am UTC](https://forums.percona.com/t/mysql-performance-issue/1031/1 "2008-12-10T08:32:02Z")

</div>

Hi,

I am using a production server with apache and mysql 5.0.22. Configuration is: 2 x Xeon 3Ghz and 4GB ram. Disks are SAS 15000rpm. OS is RHEL 5.  
My problem is during peak time mysql is taking around 790% of total cpu’s and load average is around 40 (sometimes load average is 90+ and mysql crashes).

Below is my.cnf

[mysqld]  
datadir=/var/lib/mysql  
socket=/var/lib/mysql/mysql.sock  
back\_log = 50  
long\_query\_time = 5  
max\_connections = 300  
key\_buffer = 32M  
myisam\_sort\_buffer\_size = 64M  
join\_buffer\_size = 2M  
read\_buffer\_size = 4M  
sort\_buffer\_size = 2M  
table\_cache = 4096  
thread\_cache\_size = 384  
wait\_timeout = 15  
connect\_timeout = 10  
max\_tmp\_table = 256  
tmp\_table\_size = 384M  
max\_heap\_table\_size = 64M  
max\_tmp\_table = 256  
max\_allowed\_packet = 64M  
max\_connect\_errors = 10  
read\_rnd\_buffer\_size = 524288  
bulk\_insert\_buffer\_size = 8M  
query\_cache\_limit = 4M  
query\_cache\_size = 80M  
query\_cache\_type = 1  
query\_prealloc\_size = 65536  
query\_alloc\_block\_size = 131072  
concurrent\_insert = 2  
low\_priority\_update = 1  
default-storage-engine = MyISAM

innodb\_additional\_mem\_pool\_size=4M  
innodb\_flush\_log\_at\_trx\_commit=1  
innodb\_log\_buffer\_size=4M  
innodb\_buffer\_pool\_size=256M  
innodb\_thread\_concurrency=4

[mysql.server]  
user=mysql  
basedir=/var/lib

[mysqld\_safe]  
err-log=/var/log/mysqld.log  
pid-file=/var/run/mysqld/mysqld.pid  
open\_files\_limit = 8192

[mysqldump]  
quick  
max\_allowed\_packet = 16M

[myisamchk]  
key\_buffer = 64M  
sort\_buffer = 64M  
read\_buffer = 16M  
write\_buffer = 16M

I am using MyIsam tables and InnoDB for transaction and the server is hosting many websites (120 customers sites).

If you can help to find if there is a problem in my configuration or there is some wrong parameters.

Thanks,

---

<div class="post-metadata">

**Author:** ![januzi](https://avatars.discourse-cdn.com/v4/letter/j/82dd89/32.png) [@januzi](https://forums.percona.com/u/januzi)\
**Post date:** [December 10, 2008, 8:37am UTC](https://forums.percona.com/t/mysql-performance-issue/1031/2 "2008-12-10T08:37:41Z")

</div>

Could You post info about mysql server status (show status / show global status - second one should be better) ?
