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

Behavior upon too small aria_pagecache_buffer_size in case of multiple segments is not very user-friendly

    XMLWordPrintable

Details

    • Not for Release Notes

    Description

      If the combination of aria_pagecache_buffer_size and aria_pagecache_segments is such that one segment size is less than 128K (the current minimal value allowed for aria_pagecache_buffer_size, the server aborts on startup with "Not enough memory" error:

      bb-MDEV-24-monty e2e0a3a3575249bb635fa0415427d4a416278126

      $ perl ./mtr main.1st --mysqld=--aria_pagecache_segments=32 --mysqld=--aria_pagecache_buffer_size=1M
      ...
      2025-05-25  2:19:18 0 [ERROR] mariadbd: Not enough memory to allocate 8 pagecache pages
      2025-05-25  2:19:18 0 [ERROR] Plugin 'Aria' registration as a STORAGE ENGINE failed.
      ...
      2025-05-25  2:19:18 0 [ERROR] Aborting
      Warning: Memory not freed: 536
      Memory report from safemalloc
      

      It could have instead adjust one of the values, as it adjusts the size of the pagecache in case of one segment:

      $ perl ./mtr main.1st --mysqld=--aria_pagecache_segments=1 --mysqld=--aria_pagecache_buffer_size=32K
      ...
      2025-05-25  2:22:05 0 [Warning] option 'aria-pagecache-buffer-size': unsigned value 32768 adjusted to 131072
      

      or at least complain about an incompatible combination of parameters and shut down more gracefully.

      Attachments

        Issue Links

          Activity

            People

              monty Michael Widenius
              elenst Elena Stepanova
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Git Integration

                  Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.