Question

Thanks for taking your time to look at my question, and I hope that you can help me with this.

I have a Windows Server 2012 server, it has:

Memory : 3840MB Ram

Processor: Intel(R) Xeon(R) CPU E5-2680 v2 @ 2.80GHz (2 CPUs), ~2.8GHz

But still mysql is going up to 100% cpu usage I ran the MySQLInstanceConfig.exe configuration Wizard to help me config everything for mysql and this is the my.ini config file that it created:

[client]

port=3306

[mysql]

default-character-set=latin1

[mysqld]

The TCP/IP Port the MySQL Server will listen on

port=3306

basedir="C:/Program Files/MySQL/MySQL Server 5.5/"

datadir="C:/ProgramData/MySQL/MySQL Server 5.5/data/"

character-set-server=latin1

default-storage-engine=INNODB

sql-mode="STRICT_TRANS_TABLES,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION"

max_connections=100

query_cache_size=0

table_cache=256

tmp_table_size=192M

thread_cache_size=8

myisam_max_sort_file_size=100G

myisam_sort_buffer_size=384M

key_buffer_size=332M

read_buffer_size=64K read_rnd_buffer_size=256K

sort_buffer_size=256K

* INNODB Specific options *

innodb_additional_mem_pool_size=14M

innodb_flush_log_at_trx_commit=1

innodb_log_buffer_size=7M

innodb_buffer_pool_size=643M

innodb_log_file_size=65M

innodb_thread_concurrency=8

But Something is still wrong, it's taking to much CPU

Was it helpful?

Solution

Try to use given configuration. This might help you.

[client]

port=3306

[mysql]

default-character-set=latin1

[mysqld]

The TCP/IP Port the MySQL Server will listen on

port=3306

basedir="C:/Program Files/MySQL/MySQL Server 5.5/"

datadir="C:/ProgramData/MySQL/MySQL Server 5.5/data/" #put basedir and datadir on different location

character-set-server=latin1

default-storage-engine=INNODB

sql-mode="STRICT_TRANS_TABLES,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION"

max_connections=100

query_cache_size=10M

query_cache_limit=15M

table_cache=256

tmp_table_size=100M # Reduce temp table size it uses ram

thread_cache_size=16 #Increase this value

myisam_max_sort_file_size=100G

myisam_sort_buffer_size=384M

key_buffer_size=250M #Reduce this

read_buffer_size=64K read_rnd_buffer_size=256K

sort_buffer_size=256K

* INNODB Specific options *

innodb_additional_mem_pool_size=14M # SHOW INNODB STATUS will display the current amount used. set according to that

innodb_flush_log_at_trx_commit=1

innodb_log_buffer_size=5M

innodb_buffer_pool_size=512M

innodb_log_file_size=65M

innodb_thread_concurrency=8

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top