1

I have a huge magazine on dedicated server(1 website only on the server), all time the server have big load,

"top" tool show me that the user "mysql" make this load:

PID   USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND
16058 mysql     20   0 1453m  88m 6088 S 96.3  0.6   2:34.59 mysqld

what is the best configuration should I put in "my.cnf" to speed up and increase performance ?

this is my server information:

  • CPU : Intel Core i7-4770 Quadcore
  • RAM : 32 GB DDR3
  • HDD : 240GB SSD
  • OS : Centos 6.5 /64bit with cPanel
  • mysql version: 5.5, default storage engine MYISAM

my website information:

  • Database size: about 1GB
  • 40000 vists per day

Please suggest what is the best configuration to decrease server load and speed up the site

Andrew Schulman
  • 8,811
  • 21
  • 32
  • 47
moh
  • 11
  • 2

2 Answers2

0

There are MANY things that can be done in your case but are greatly dependent on what exactly happens in the application and which queries run on the DB.

If going more in depth is not possible then these three options are the most important if you can't change other things. They will use your RAM more efficiently if one of the limitations is disk speed.

key_buffer_size = 1G
read_buffer_size = 64M
read_rnd_buffer_size = 128M

If the next two don't improve things set them to 0. It depends if your server runs the same queries all the time.

query_cache_size = 128M
query_cache_limit = 2M
Bogdan
  • 218
  • 2
  • 8
0

There are some mysql-tuning script, which examine your database, parameters, counters and give you recomendations.

Korjavin Ivan
  • 2,250
  • 2
  • 26
  • 41