rapor : Top Sat Mar 31 01:17:49 EEST 2007 [H[2J[m(Btop - 01:17:50 up 3 days, 5:32, 1 user, load average: 1.72, 1.13, 1.91[m(B[39;49m[K Tasks:[m(B[39;49m[m(B 95 [m(B[39;49mtotal,[m(B[39;49m[m(B 1 [m(B[39;49mrunning,[m(B[39;49m[m(B 94 [m(B[39;49msleeping,[m(B[39;49m[m(B 0 [m(B[39;49mstopped,[m(B[39;49m[m(B 0 [m(B[39;49mzombie[m(B[39;49m[K Cpu :[m(B[39;49m[m(B 54.3% [m(B[39;49mus,[m(B[39;49m[m(B 8.0% [m(B[39;49msy,[m(B[39;49m[m(B 0.0% [m(B[39;49mni,[m(B[39;49m[m(B 37.4% [m(B[39;49mid,[m(B[39;49m[m(B 0.2% [m(B[39;49mwa,[m(B[39;49m[m(B 0.0% [m(B[39;49mhi,[m(B[39;49m[m(B 0.0% [m(B[39;49msi[m(B[39;49m[K Mem: [m(B[39;49m[m(B 483476k [m(B[39;49mtotal,[m(B[39;49m[m(B 456728k [m(B[39;49mused,[m(B[39;49m[m(B 26748k [m(B[39;49mfree,[m(B[39;49m[m(B 28860k [m(B[39;49mbuffers[m(B[39;49m[K Swap:[m(B[39;49m[m(B 1052248k [m(B[39;49mtotal,[m(B[39;49m[m(B 60872k [m(B[39;49mused,[m(B[39;49m[m(B 991376k [m(B[39;49mfree,[m(B[39;49m[m(B 194872k [m(B[39;49mcached[m(B[39;49m[K [6;1H [7m PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND [m(B[39;49m[K [m(B11410 apache 15 0 34684 16m 4644 S 3.1 3.4 1:55.02 /usr/sbin/httpd [m(B[39;49m [m(B21908 mysql 16 0 149m 38m 4048 S 1.6 8.2 44:44.70 /usr/libexec/mysqld[m(B[39;49m [m(B16790 apache 15 0 34668 15m 4376 S 1.6 3.4 1:03.63 /usr/sbin/httpd [m(B[39;49m [m(B19030 apache 15 0 34648 15m 4380 S 1.6 3.4 0:44.69 /usr/sbin/httpd [m(B[39;49m [m(B20152 apache 15 0 34668 15m 4376 S 1.6 3.4 0:36.56 /usr/sbin/httpd [m(B[39;49m [m(B21302 apache 15 0 34380 15m 4360 S 1.6 3.3 0:31.88 /usr/sbin/httpd [m(B[39;49m [m(B[m(B23936 root 16 0 2360 880 692 R 1.6 0.2 0:00.02 top -c -n1 [m(B[39;49m [m(B 1 root 16 0 2292 456 428 S 0.0 0.1 0:00.87 init [m(B[39;49m [m(B 2 root 34 19 0 0 0 S 0.0 0.0 0:00.04 [m(B[39;49m [m(B 3 root 5 -10 0 0 0 S 0.0 0.0 0:00.06 [m(B[39;49m [m(B 4 root 6 -10 0 0 0 S 0.0 0.0 0:00.01 [m(B[39;49m [m(B 5 root 15 -10 0 0 0 S 0.0 0.0 0:00.00 [m(B[39;49m [m(B 19 root 5 -10 0 0 0 S 0.0 0.0 0:00.00 [m(B[39;49m [m(B 38 root 15 0 0 0 0 S 0.0 0.0 0:02.28 [m(B[39;49m [m(B 40 root 12 -10 0 0 0 S 0.0 0.0 0:00.00 [m(B[39;49m [m(B 20 root 15 0 0 0 0 S 0.0 0.0 0:00.00 [m(B[39;49m [m(B 39 root 15 0 0 0 0 S 0.0 0.0 0:26.98 [m(B[39;49m[6;1H[K[25;1H[?12l[?25h my. cnf Sat Mar 31 01:17:50 EEST 2007 set-variable=local-infile=0 datadir=/var/lib/mysql socket=/var/lib/mysql/mysql. sock # Default to using old password format for compatibility with mysql 3. x # clients (those using the mysqlclient10 compatibility package). old_passwords=1 user=mysql basedir=/var/lib err-log=/var/log/mysqld. log pid-file=/var/run/mysqld/mysqld. pid show status Sat Mar 31 01:17:50 EEST 2007

1. Serverinizda root ile ssh ekranina geciniz. 2. vi yada pico ile yeni mysql_raporu. sh dosyasini aciniz. 3. Asagidaki satirlarin tumunu bu dosya icine kaydederek saklayiniz. echo &quot;Top&quot; echo &quot; &quot; date; top -c -n1 # echo &quot;my. cnf&quot; echo &quot; &quot; date; cat /etc/my. cnf # echo &quot;show status&quot; echo &quot; &quot; date; echo &quot;show status&quot; | mysql -u kullanici_adi -p sifre

Şöyle 2 raporum var. ilgilenen olursa yazayım: # ./tuning-primer. sh -- MYSQL PERFORMANCE TUNING PRIMER -- - By: Matthew Montgomery - MySQL Version 5.0.77 i686 Uptime = 9 days 3 hrs 22 min 35 sec Avg. qps = 117 Total Questions = 92831398 Threads Connected = 2 Server has been running for over 48hrs. It should be safe to follow these recommendations To find out more information on how each of these runtime variables effects performance visit: http://dev.mysql.com/doc/refman/5.0/en/server-system-variables.html Visit http://www.mysql.com/products/enterprise/advisors.html for info about MySQL's Enterprise Monitoring and Advisory Service SLOW QUERIES The slow query log is NOT enabled. Current long_query_time = 10 sec. You have 908 out of 92831426 that take longer than 10 sec. to complete Your long_query_time seems to be fine BINARY UPDATE LOG The binary update log is NOT enabled. You will not be able to do point in time recovery See http://dev.mysql.com/doc/refman/5.0/en/point-in-time-recovery.html WORKER THREADS Current thread_cache_size = 4 Current threads_cached = 3 Current threads_per_sec = 2 Historic threads_per_sec = 1 Threads created per/sec are overrunning threads cached You should raise thread_cache_size MAX CONNECTIONS Current max_connections = 170 Current threads_connected = 3 Historic max_used_connections = 162 The number of used connections is 95% of the configured maximum. You should raise max_connections INNODB STATUS Current InnoDB index space = 1 M Current InnoDB data space = 2 M Current InnoDB buffer pool free = 40 % Current innodb_buffer_pool_size = 8 M Depending on how much space your innodb indexes take up it may be safe to increase this value to up to 2 / 3 of total system memory MEMORY USAGE Max Memory Ever Allocated : 462 M Configured Max Per-thread Buffers : 456 M Configured Max Global Buffers : 26 M Configured Max Memory Limit : 483 M Physical Memory : 3.46 G Max memory limit seem to be within acceptable norms KEY BUFFER Current MyISAM index space = 827 M Current key_buffer_size = 7 M Key cache miss rate is 1 : 181 Key buffer free ratio = 36 % Your key_buffer_size seems to be too high. Perhaps you can use these resources elsewhere QUERY CACHE Query cache is enabled Current query_cache_size = 9 M Current query_cache_used = 6 M Current query_cache_limit = 1 M Current Query cache Memory fill ratio = 73.98 % Current query_cache_min_res_unit = 4 K MySQL won't cache query results that are larger than query_cache_limit in size SORT OPERATIONS Current sort_buffer_size = 2 M Current read_rnd_buffer_size = 256 K Sort buffer seems to be fine JOINS Current join_buffer_size = 132.00 K You have had 5729 queries where a join could not use an index properly You should enable &quot;log-queries-not-using-indexes&quot; Then look for non indexed joins in the slow query log. If you are unable to optimize your queries you may want to increase your join_buffer_size to accommodate larger joins in one pass. Note! This script will still suggest raising the join_buffer_size when ANY joins not using indexes are found. OPEN FILES LIMIT Current open_files_limit = 1604 files The open_files_limit should typically be set to at least 2x-3x that of table_cache if you have heavy MyISAM usage. Your open_files_limit value seems to be fine TABLE CACHE Current table_cache value = 712 tables You have a total of 1188 tables You have 712 open tables. Current table_cache hit rate is 1% , while 100% of your table cache is in use You should probably increase your table_cache TEMP TABLES Current max_heap_table_size = 16 M Current tmp_table_size = 32 M Of 2296731 temp tables, 11% were created on disk Effective in-memory tmp_table_size is limited to max_heap_table_size. Created disk tmp tables ratio seems fine TABLE SCANS Current read_buffer_size = 128 K Current table scan ratio = 160 : 1 read_buffer_size seems to be fine TABLE LOCKING Current Lock Wait ratio = 1 : 236 You may benefit from selective use of InnoDB. If you have long running SELECT's against MyISAM tables and perform frequent updates consider setting 'low_priority_updates=1' If you have a high concurrency of inserts on Dynamic row-length tables consider setting 'concurrent_insert=2'. # # perl mysqltuner. pl &gt;&gt; MySQLTuner 1.2.0 - Major Hayden &lt; &gt; &gt;&gt; Bug reports, feature requests, and downloads at http://mysqltuner.com/ &gt;&gt; Run with '--help' for additional options and output filtering General Statistics Skipped version check for MySQLTuner script Currently running supported MySQL version 5.0.77 Switch to 64-bit OS - MySQL cannot currently use all of your RAM Storage Engine Statistics Status: -Archive +BDB -Federated +InnoDB -ISAM -NDBCluster Data in MyISAM tables: 2G (Tables: 1032) Data in InnoDB tables: 2M (Tables: 133) Data in MEMORY tables: 378K (Tables: 6) BDB is enabled but isn't being used Total fragmented tables: 86 Security Recommendations All database users have passwords assigned Performance Metrics Up for: 9d 3h 23m 51s (92M q , 8M conn, TX: 2B, RX: 1B) Reads / Writes: 75% / 25% Total buffers: 43.0M global + 2.7M per thread (170 max threads) Maximum possible memory usage: 499.9M (14% of installed RAM) Slow queries: 0% (908/92M) Highest connection usage: 95% (162/170) Key buffer size / total MyISAM indexes: 8.0M/827.0M Key buffer hit rate: 99.4% (13B cached / 72M reads) Query cache efficiency: 52.0% (27M cached / 52M selects) Query cache prunes per day: 876567 Sorts requiring temporary tables: 0% (844 temp sorts / 10M sorts) Joins performed without indexes: 5729 Temporary tables created on disk: 11% (293K on disk / 2M total) Thread cache hit rate: 89% (863K created / 8M connections) Table cache hit rate: 1% (712 open / 69K opened) Open file limit used: 70% (1K/1K) Table locks acquired immediately: 99% (66M immediate / 67M locks) InnoDB data size / buffer pool: 2.2M/8.0M Recommendations General recommendations: Add skip-bdb to MySQL configuration to disable BDB Run OPTIMIZE TABLE to defragment tables for better performance Enable the slow query log to troubleshoot bad queries Reduce or eliminate persistent connections to reduce connection usage Adjust your join queries to always utilize indexes Increase table_cache gradually to avoid file descriptor limits Variables to adjust: max_connections (&gt; 170) wait_timeout (&lt; 14400) interactive_timeout (&lt; 14400) query_cache_size (&gt; 9M) join_buffer_size (&gt; 128.0K, or always use indexes with joins) table_cache (&gt; 712) # ram-&gt; 4gb cpu-&gt; 6 my. cnf dosyam: set-variable=local-infile=0 datadir=/var/lib/mysql socket=/var/lib/mysql/mysql. sock user=mysql max_allowed_packet=32M max_connections=170 wait_timeout = 14400 interactive_timeout = 14400 query_cache_size = 9M thread_cache_size = 4 table_cache = 712 # Default to using old password format for compatibility with mysql 3. x # clients (those using the mysqlclient10 compatibility package). old_passwords=1 # Disabling symbolic-links is recommended to prevent assorted security risks; # to do so, uncomment this line: # symbolic-links=0 log-error=/var/log/mysqld. log pid-file=/var/run/mysqld/mysqld. pid set-variable=local-infile=0 datadir=/var/lib/mysql socket=/var/lib/mysql/mysql. sock user=mysql # Default to using old password format for compatibility with mysql 3. x # clients (those using the mysqlclient10 compatibility package). old_passwords=1 # Disabling symbolic-links is recommended to prevent assorted security risks; # to do so, uncomment this line: # symbolic-links=0 log-error=/var/log/mysqld. log pid-file=/var/run/mysqld/mysqld. pid my. cnf dosyamı nasıl değiştirirsem bir kat daha olumlu sonuç elde edebilirim?