Hello All ,
Am Shufil , working as a Linux system admin . we are using WHM servers , i regularly watching all forms for finding a solution .
Currently i have a issue . our server running with 4 core cpu and 4 GB Ram , our MySQL DB size 5.6 GB , problem is our MySQL load seems very high , i need to check our my.cnf configure correctly or not . also you can see mysql tuning result .
MySQL tuning scan Result .
Regards,
Shufil
______________________________________________________
Am Shufil , working as a Linux system admin . we are using WHM servers , i regularly watching all forms for finding a solution .
Currently i have a issue . our server running with 4 core cpu and 4 GB Ram , our MySQL DB size 5.6 GB , problem is our MySQL load seems very high , i need to check our my.cnf configure correctly or not . also you can see mysql tuning result .
MySQL tuning scan Result .
Code:
-------- Recommendations -----------------------------------------------------
General recommendations:
Run OPTIMIZE TABLE to defragment tables for better performance
Increasing the query_cache size over 128M may reduce performance
Adjust your join queries to always utilize indexes
Temporary table size is already large - reduce result set size
Reduce your SELECT DISTINCT queries without LIMIT clauses
Increase table_cache gradually to avoid file descriptor limits
Variables to adjust:
*** MySQL's maximum memory usage is dangerously high ***
*** Add RAM before increasing MySQL buffer variables ***
query_cache_size (> 256M) [see warning above]
join_buffer_size (> 1.0M, or always use indexes with joins)
table_cache (> 4096)
innodb_buffer_pool_size (>= 12G)
Code:
[mysqld]
#innodb_force_recovery = 4
old_passwords=1
tmpdir=/home/mysqltmp
datadir=/var/lib/mysql
skip-locking
#skip-networking
#tmp_table_size = 1024M
#max_heap_table_size = 1024M
tmp_table_size = 256M
max_heap_table_size = 256M
query_cache_limit=20M
query_cache_size=128M ## 32MB for every 1GB of RAM
query_cache_type=1
max_user_connections=100
max_connections=150
innodb_file_per_table=1
innodb_buffer_pool_size = 1073741824
collation_server=utf8_unicode_ci
character_set_server=utf8
delayed_insert_timeout=40
interactive_timeout=10
wait_timeout=500
connect_timeout=20
thread_cache_size=128
key_buffer=256M ## 32MB for every 1GB of RAM
join_buffer=1M
max_connect_errors=20
max_allowed_packet=64M
table_cache=4096
table_definition_cache=1024
record_buffer=2M
sort_buffer_size=4M ## 1MB for every 1GB of RAM
read_buffer_size=4M ## 1MB for every 1GB of RAM
read_rnd_buffer_size=4M ## 1MB for every 1GB of RAM
thread_concurrency=4 ## Number of CPUs x 2
myisam_sort_buffer_size=64M
server-id=1
log-slow-queries=/home/mysqltmp/mysql_slow_queries.log
open_files_limit=36116
[mysql.server]
user=mysql
[safe_mysqld]
err-log=/var/log/mysqld.log
pid-file=/var/lib/mysql/mysql.pid
[mysqldump]
quick
max_allowed_packet=32M
[mysql]
no-auto-rehash
Shufil
______________________________________________________