List:General Discussion« Previous MessageNext Message »
From:Martijn van den Burg Date:September 15 2005 11:18am
Subject:Many Key_blocks_unused - why?
View as plain text  
Hi list,

I have noticed that the key buffer usage (defined in MySQL Administrator
as Key_blocks_used *key_cache_block_size) always stays the same, and
that I have a large amount of Key_blocks_unused, which seems to me
there's a potential performance gain somewhere:

> show variables like 'key%';

+--------------------------+-----------+
| Variable_name            | Value     |
+--------------------------+-----------+
| key_buffer_size          | 134217728 |
| key_cache_age_threshold  | 300       |
| key_cache_block_size     | 1024      |
| key_cache_division_limit | 100       |
+--------------------------+-----------+

> show status like 'key%';

+------------------------+------------+
| Variable_name          | Value      |
+------------------------+------------+
| Key_blocks_not_flushed | 0          |
| Key_blocks_unused      | 113335     |
| Key_blocks_used        | 114777     |
| Key_read_requests      | 1355363461 |
| Key_reads              | 27384734   |
| Key_write_requests     | 146025506  |
| Key_writes             | 128187590  |
+------------------------+------------+


The maximum number of blocks that can be allocated is: key_buffer_size /
key_cache_block_size = 131072, right? Which means most blocks are
unused!

Also, the quotient of Key_reads over Key_read_requests is 0.02, above
the recommended max. of 0.01.

How can I make use of the unused key blocks, and improve performance?

FWIW: using MySQL 4.1.10 on Solaris 8.


Kind regards,

Martijn


-- 
The information contained in this communication and any attachments is confidential and
may be privileged, and is for the sole use of the intended recipient(s). Any unauthorized
review, use, disclosure or distribution is prohibited. If you are not the intended
recipient, please notify the sender immediately by replying to this message and destroy
all copies of this message and any attachments. ASML is neither liable for the proper and
complete transmission of the information contained in this communication, nor for any
delay in its receipt.
Thread
Many Key_blocks_unused - why?Martijn van den Burg15 Sep