transparent_hugepages
WARNING
Rule IDs: os_003
Overview
- Purpose
- Linux memory feature that can interact poorly with database latency; often reported from host diagnostics.
- Dynamic (MySQL 8.4 reference)
- OS configuration — not a MySQL variable.
- Default value
- Distribution-dependent.
- Version and product notes
- Applies to Linux hosts only.
- Documentation
- Primary reference depends on product (MySQL, MariaDB, Percona, or OS documentation).
What is checked
Rules that reference this variable, with their severity and what each rule detects:
- WARNING
os_003: Set THP to madvise or never: echo madvise > /sys/kernel/mm/transparent_hugepage/enabled
Tuning guidance
- Recommended actions:
- Set THP to madvise or never: echo madvise > /sys/kernel/mm/transparent_hugepage/enabled
- Trade-offs: OS tuning (swap, THP, NUMA, I/O scheduler) operates outside MySQL but directly affects database performance. Changes require root access and may need a reboot.
Example
echo madvise > /sys/kernel/mm/transparent_hugepage/enabled -- Persist via systemd service or tuned profile