You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
MDEV-38936 Proactive handling of InnoDB tablespace full condition
InnoDB write failures occur when tablespace files exceed filesystem size
limits. Current behavior logs errors but continues accepting
transactions, causing repeated failures and potential data integrity
issues.
Add proactive monitoring by emitting warnings when InnoDB tablespaces
approach a configurable size threshold. Warnings use a tiered frequency
approach to balance early notification with log spam prevention.
Key features:
- Three new system variables:
* innodb_tablespace_size_warning_threshold (default 16TB): Maximum
tablespace size in bytes before warnings begin
* innodb_tablespace_size_warning_pct (default 70%): Percentage of
threshold at which to start emitting warnings
* innodb_tablespace_size_warning_enabled (default ON): Andon cord to
enable/disable the warning feature
- Tiered warning frequency:
* Below warning_pct: No warnings
* Between warning_pct and 90%: At most twice per 10% interval with
minimum 5% gap (e.g., 70%, 77%, 81%, 89%)
* Above 90%: Every 1% increase (90%, 91%, 92%, etc.)
- Per-tablespace tracking with automatic reset on TRUNCATE/DROP or
threshold changes
- Zero overhead when disabled
- Progressive warnings capped at 100%
Implementation hooks into fsp_try_extend_data_file() for O(1) size
checking during tablespace extension. Adds 11 bytes per tablespace
(m_last_size_warning_pct, m_last_warning_threshold,
m_warning_count_in_decade) to fil_space_t structure.
All new code of the whole pull request, including one or several files
that are either new files or modified ones, are contributed under the
BSD-new license. I am contributing on behalf of my employer Amazon Web
Services, Inc.
0 commit comments