4.8. Disable Transparent Huge Pages (THP)

When installing Ambari on CentOS6.x using the Cluster Installer Wizard at the Host Checks step, one or more host checks may fail if you have not disabled Transparent Huge Pages on all hosts. Host Checks warns you when a failure occurs. To disable THP:

  1. Add the following command to your /etc/rc.local file:

    • RHEL6

      if test -f /sys/kernel/mm/redhat_transparent_hugepage/defrag; then echo never > /sys/kernel/mm/redhat_transparent_hugepage/defrag fi
    • SLES

      if test -f /sys/kernel/mm/transparent_hugepage/defrag; then echo never > /sys/kernel/mm/transparent_hugepage/defrag fi
  2. To confirm, reboot the host. Then, run the following command:

    $ cat /sys/kernel/mm/transparent_hugepage/enabled always madvise [never]

loading table of contents...