Mysql Performance Tuning on 32 GB system

I have a Dell Poweredge server with 2*2 Proc. with 32GB of ram.
mysql is running on a RAID5 with 6 15k disks OS is on a separate partition. We have about 85GB worth a databases running on that server all using MyIsam storage engine

The server constantly has really high %IOwait and is causing the server performance to suffer badly… It doesn’t seem like Mysql is utilizing as much RAM as it should be… here is the output for the MySQL tuning primer that was run on that server.


– MYSQL PERFORMANCE TUNING PRIMER –

MySQL Version 5.1.36-community-log x86_64

Uptime = 34 days 19 hrs 2 min 25 sec
Avg. qps = 91
Total Questions = 275812556
Threads Connected = 7

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.1/en/server-system-variabl es.html

SLOW QUERIES
Current long_query_time = 10.000000 sec.
You have 33328 out of 275812574 that take longer than 10.000000 sec. to complete
The slow query log is enabled.
./tuning-primer.sh: line 484: [: 10.000000: integer expression expected
Your long_query_time seems to be fine

WORKER THREADS
Current thread_cache_size = 128
Current threads_cached = 119
Current threads_per_sec = 0
Historic threads_per_sec = 0
Your thread_cache_size is fine

MAX CONNECTIONS
Current max_connections = 700
Current threads_connected = 10
Historic max_used_connections = 578
The number of used connections is 82% of the configured maximum.
Your max_connections variable seems to be fine.

MEMORY USAGE
Max Memory Ever Allocated : 22 G
Configured Max Per-thread Buffers : 24 G
Configured Max Global Buffers : 2 G
Configured Max Memory Limit : 26 G
Total System Memory : 33 G
Max memory limit seem to be within acceptable norms

KEY BUFFER
Current MyISAM index space = 83 G
Current key_buffer_size = 2 G
Key cache miss rate is 1 : 122
Key buffer fill ratio = 100.00 %
You could increase key_buffer_size
It is safe to raise this up to 1/4 of total system memory;
assuming this is a dedicated database server.

QUERY CACHE
Query cache is enabled
Current query_cache_size = 50 M
Current query_cache_used = 38 M
Current query_cach_limit = 10 M
Current Query cache fill ratio = 77.61 %
MySQL won’t cache query results that are larger than query_cache_limit in size

SORT OPERATIONS
Current sort_buffer_size = 12 M
Current record/read_rnd_buffer_size = 12 M
Sort buffer seems to be fine

JOINS
Current join_buffer_size = 4.00 M
You have had 331656 queries where a join could not use an index properly
join_buffer_size >= 4 M
This is not advised
You should enable “log-queries-not-using-indexes”
Then look for non indexed joins in the slow query log.

OPEN FILES LIMIT
Current open_files_limit = 8902 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_open_cache = 4096 tables
Current table_definition_cache = 256 tables
You have a total of 2317 tables
You have 4014 open tables.
Current table_cache hit rate is 0%, while 97% of your table cache is in use
You should probably increase your table_cache
You should probably increase your table_definition_cache value.

TEMP TABLES
Current max_heap_table_size = 256 M
Current tmp_table_size = 256 M
Of 24543701 temp tables, 73% were created on disk
Perhaps you should increase your max_heap_table_size and/or tmp_table_size.
to reduce the number of disk-based temporary tables

TABLE SCANS
Current read_buffer_size = 8 M
Current table scan ratio = 941 : 1
read_buffer_size seems to be fine

TABLE LOCKING
Current Lock Wait ratio = 1 : 1013
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 concurrentcy of inserts on Dynamic row-length tables
consider setting ‘concurrent_insert=2’.


I am kind of new to MySql tuning any help would be much appreciated!

I think you can gain more from optimizing table schemes.