Rate This Document
Findability
Accuracy
Completeness
Readability

Disabling Transparent Huge Pages

Purpose

Disable transparent huge pages to avoid memory allocation delay.

Procedure

Method 1:

  1. Open the grub2-efi.cfg file.
    1
    vim /etc/grub2-efi.cfg
    
  2. Search for the vmlinuz-4.14.0-115.el7a.0.1.aarch64 field and add the following field to the end of the line. Separate the two fields with a space.
    "transparent_hugepage=never" 
  3. Save the configuration and exit. Then, restart the server.
  4. Check whether the configuration takes effect.
    1
    cat /proc/cmdline
    

    If the command output contains the transparent_hugepage=never field, the transparent huge pages are successfully disabled.

Method 2:

  1. Enter the value of transparent_hugepage in the command line.
    1
    echo never > /sys/kernel/mm/transparent_hugepage/enabled