600'den fazla bağlantı MySQL

0 Cevap php

I have Database Server and 4 other client servers.
No of connection at a time from the client servers is more than 600.
It has so many slow queries, which are due to table locking.
I have changed one of table to InnoDB, which gets more update and insert queries.

Veritabanını optimize bana yardımcı olun. Ben veritabanı için özel bir sunucu var.

Aşağıdaki my.cnf ayarları olduğunu.

[mysqld]  
tmpdir=/tmp  
open_files_limit=33628   
log-slow-queries=/slow-query.txt  
long_query_time=1  
log-queries-not-using-indexes=1  
concurrent_insert=2  


old_passwords=1  
datadir=/var/lib/mysql  

safe-show-database  
tmp_table_size = 128M  
max_heap_table_size = 128M  
query_cache_limit=8M  
query_cache_size=128M ## 32MB for every 1GB of RAM  
query_cache_type=1  
max_user_connections=800  
max_connections=800  
collation_server=utf8_unicode_ci  
character_set_server=utf8  


delayed_insert_timeout=40  

interactive_timeout=10  
wait_timeout=3600  
connect_timeout=20  
thread_cache_size=128  
key_buffer=128M ## 32MB for every 1GB of RAM  
join_buffer=1M  
max_connect_errors=20  
max_allowed_packet=16M  
table_cache=400  
record_buffer=1M  
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=8 ## Number of CPUs x 2  
myisam_sort_buffer_size=32M  
server-id=1  

[mysql.server]  
user=mysql  


[safe_mysqld]  
open_files_limit=33628  
err-log=/var/log/mysqld.log  
pid-file=/var/lib/mysql/mysql.pid 

Şu anda i bağlantı devam olmayan kullanıyorum, bağlantı benim performansını artırabilirsiniz devam mı?

0 Cevap