Ad Widget

Collapse

Tuning MYSQL key_buffer_size

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • jeenam
    Member
    • Oct 2007
    • 43

    #1

    Tuning MYSQL key_buffer_size

    Firstly, server is an Athlon x2 4000+ w/ 2GB RAM and a 7200rpm SATA Seagate 250GB hard disk. OS is Debian Etch v4.0. Zabbix server is v1.4.2, MySQL is v5.0, db engine is MyISAM, but Zabbix db is InnoDB.

    MySQL reports the number of "key_reads" being around 2000x greater than the number of "key_read_requests" after 24 hours or so. Is this normal? Here's a sampling after the server has been up for around 10 minutes. At this point the key_reads already outnumer key_read_requests. It seems the key_buffer is not being used at all.

    | Key_blocks_not_flushed | 0 |
    | Key_blocks_unused | 463920 |
    | Key_blocks_used | 7 |
    | Key_read_requests | 1954 |
    | Key_reads | 3663 |
    | Key_write_requests | 4271 |
    | Key_writes | 9 |

    Here are the pertinent values from /etc/mysql/my.cnf:

    max_heap_table_size = 128M
    tmp_table_size = 96M
    key_buffer_size = 128M

    innodb_file_per_table
    innodb_buffer_pool_size=512M
    innodb_log_buffer_size=64M
    Last edited by jeenam; 25-10-2007, 01:51. Reason: change title
  • Alexei
    Founder, CEO
    Zabbix Certified Trainer
    Zabbix Certified SpecialistZabbix Certified Professional
    • Sep 2004
    • 5654

    #2
    The key_buffer_size is for MyISAM only as far as I remember...
    Alexei Vladishev
    Creator of Zabbix, Product manager
    New York | Tokyo | Riga
    My Twitter

    Comment

    Working...