Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-8932

innodb buffer pool hit rate is less than zero

    Details

      Description

      When I set my.cnf like this:

      innodb_buffer_pool_size = 102400M
      innodb_buffer_pool_dump_at_shutdown=1
      innodb_buffer_pool_dump_now=1
      innodb_buffer_pool_load_at_startup=1
      innodb_buffer_pool_load_now=1

      and use (1-Innodb_buffer_pool_reads/Innodb_buffer_pool_read_requests)*100% to calculate innodb buffer pool hit rate ,I got a number less than zero,like

      +----------------------+
      | hit_rate             |
      +----------------------+
      | -0.04231484607035707 |
      +----------------------+

      ,and

      MariaDB [(none)]> show global status like 'innodb_buffer_pool_read%';
      +---------------------------------------+----------+
      | Variable_name                         | Value    |
      +---------------------------------------+----------+
      | Innodb_buffer_pool_read_ahead         | 0        |
      | Innodb_buffer_pool_read_ahead_evicted | 0        |
      | Innodb_buffer_pool_read_ahead_rnd     | 0        |
      | Innodb_buffer_pool_read_requests      | 13973819 |
      | Innodb_buffer_pool_reads              | 13979732 |
      +---------------------------------------+----------+

      I found Innodb_buffer_pool_reads is bigger than Innodb_buffer_pool_read_requests!

      When the server is loading pages at the start time,I execute show engine innodb status ,and I also see a negative number like:

      Buffer pool hit rate 18446744073709549183 / 1000, young-making rate 0 / 1000 not 0 / 1000
      Buffer pool hit rate 18446744073708648991 / 1000, young-making rate 0 / 1000 not 0 / 1000
      Buffer pool hit rate 18446744073709549537 / 1000, young-making rate 0 / 1000 not 0 / 1000
      Buffer pool hit rate 18446744073709551510 / 1000, young-making rate 0 / 1000 not 0 / 1000

      Obviously it's a negative number in unsigned long int.

        Attachments

          Activity

            People

            • Assignee:
              jplindst Jan Lindström
              Reporter:
              linzhoukai Zhoukai Lin
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: