1. 11
  1.  

  2. 3

    On all our servers at work, we disable transparent huge pages too.

    We just add this to rc.local (centos)

    echo 'never' > /sys/kernel/mm/redhat_transparent_hugepage/defrag
    echo 'no' > /sys/kernel/mm/redhat_transparent_hugepage/khugepaged/defrag
    echo 'never' > /sys/kernel/mm/redhat_transparent_hugepage/enabled
    

    We do configure huge pages (not transparent) directly (via sysctls) for our db boxes, and have mysql configured to use it for the innodb buffer pool (128G). That seems to work out ok.

    1. 2

      We did the same for oracle db systems. Hugepages aren’t the same as transparent huge pages. The former won’t get paged out under memory pressure.

      That and the amount of kernel panics we encountered wasn’t worth transparent huge pages. This was on SuSE however but in either case I can’t speak highly of transparent huge pages. The Oracle/Sun JVM will eventually die on memory allocation with them on, its just a question of when.

      If your app can support normal huge pages though it is most definitely a win on high memory systems. Once you’re past 256G of memory and cross beyond 2T to 4T the amount of time spent scanning memory is absurd without them.