MySQL Optimierung
Posted: 2016-08-08 16:31
Hallo zusammen,
ich weiß das es eigentlich eine Frechheit ist, mit den spärlichen Angaben etwas zu Fragen.
Leider hab ich aber keine Ahnung was ihr braucht um mir zu helfen.
Ich hab auf der Seite immer wieder mal einen Error 500 und vermute die Datenbank, da alles andere wirklich sauber läuft.
Das ganze läuft auf einem Windows 2008 R2 Datacenter
Intel XEON 6 Kerne/12 Threads
32GB Arbeitsspeicher deren Auslastung bei durchschnittlich 60% liegt
Kann mir mit den folgenden Angaben jemand helfen das ganze zu optimieren?
Wenn was fehlt kann das recht schnell nachgeliefert werden.
MySQL Tuner spuckt folgendes aus:
Wenn ich mir alle Status-Variablen anzeigen lasse tauchen dort folgende Punkte in ROT auf:
Der Inhalt meiner my.ini lautet wie folgt:
Vielen Dank im voraus
Takumi
ich weiß das es eigentlich eine Frechheit ist, mit den spärlichen Angaben etwas zu Fragen.
Leider hab ich aber keine Ahnung was ihr braucht um mir zu helfen.
Ich hab auf der Seite immer wieder mal einen Error 500 und vermute die Datenbank, da alles andere wirklich sauber läuft.
Das ganze läuft auf einem Windows 2008 R2 Datacenter
Intel XEON 6 Kerne/12 Threads
32GB Arbeitsspeicher deren Auslastung bei durchschnittlich 60% liegt
Kann mir mit den folgenden Angaben jemand helfen das ganze zu optimieren?
Wenn was fehlt kann das recht schnell nachgeliefert werden.
MySQL Tuner spuckt folgendes aus:
Code: Select all
MySQL Tuner 0.8 - Peter Chapman <peter@conglomo.co.nz>
Performing tests on localhost:3306 at Monday, 8 August 2016 1:57:02 p.m.
Currently running supported MySQL version 5.1.73-community
Archive Engine Installed
Berkeley DB Engine Not Installed
Federated Engine Not Installed
InnoDB Engine Installed
ISAM Engine Not Installed
NDBCLUSTER Engine Not Installed
Data in InnoDB tables: 1G (Tables: 4666)
Data in MyISAM tables: 48M (Tables: 590)
Total fragmented tables: 4681
All database users have passwords assigned
Up for: 8d 4h 4m 10s (10M q [15,000 qps], 482K conn, TX: 81G, RX: 2G)
Reads / Writes: 58% / 42%
Total buffers: 1,1G global + 19,3M per thread (400 max threads)
Maximum possible memory usage: 8,6G (35% of installed RAM)
Slow queries: 1% (13/10M)
Highest usage of available connections: 8% (32/400)
Key buffer size / total MyISAM indexes: 256,0M/26,6M
Key buffer hit rate: 98% (25M cached / 314K reads)
Query cache efficiency: 67% (4M cached / 6M selects)
Query cache prunes per day: 0
Sorts requiring temporary tables: 0% (0 temp sorts / 354K sorts)
Joins performed without indexes: 113336
Temporary tables created on disk: 34% (111K on disk / 333K total)
Thread cache hit rate: 99% (32 created / 482K connections)
Table cache hit rate: 0% (52 open / 117K opened)
Open file limit used: 0% (14/2K)
Table locks acquired immediately: 99% (5M immediate / 5M locks)
InnoDB data size / buffer pool: 1,1G/64,0M
Run OPTIMIZE TABLE to defragment tables for better performance
Enable the slow query log to troubleshoot bad queries
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
long_query_time (<= 10)
join_buffer_size (> 128,0K, or always use indexes with joins)
table_open_cache (> 524288)
innodb_buffer_pool_size (>= 1G)
Scan Completed at Monday, 8 August 2016 1:58:29 p.m.
Code: Select all
Aborted clientsDokumentation 4
Aborted connectsDokumentation 137
Created tmp disk tablesDokumentation 113,2 k
Handler read rndDokumentation 8,1 M
Handler read rnd nextDokumentation 1,3 G
Innodb buffer pool pages dirtyDokumentation 33
Innodb buffer pool readsDokumentation 337 k
Innodb log waitsDokumentation 10
Innodb row lock time maxDokumentation 1,5 k
Innodb row lock waitsDokumentation 521
Key readsDokumentation 319 k
Opened tablesDokumentation 130,1 k
Select full joinDokumentation 115,3 k
Slow queriesDokumentation 16
Table locks waitedDokumentation 3,7 k
Code: Select all
[MySQLD]
port=3306
default-time-zone=SYSTEM
basedir=C:\Program Files (x86)\Parallels\Plesk\Databases\MySQL51\
datadir=C:\Program Files (x86)\Parallels\Plesk\Databases\MySQL\Data
lower_case_table_names=0
character-set-server=latin1
default-storage-engine=INNODB
read_buffer_size=10M
read_rnd_buffer_size=5M
sort_buffer_size=4M
innodb_additional_mem_pool_size=20M
innodb_flush_log_at_trx_commit=2
innodb_log_buffer_size=1M
innodb_buffer_pool_size=64M
innodb_log_file_size=10M
innodb_thread_concurrency=0
max_connections=400
old_passwords=0
max_user_connections=100
thread_cache_size=40
thread_stack=196608
binlog_cache_size=32768
net_read_timeout=30
net_retry_count=10
net_write_timeout=30
thread_concurrency=10
table_open_cache=39390
open_files_limit=78780
key_buffer=256M
max_allowed_packet=16M
query_cache_limit=512M
query_cache_size=512M
table_cache=256M
tmp_table_size=256M
max_heap_table_size=256M
log-error=mysql.err
[client]
port=3306
Takumi