Transparent HugePages Question

Home » CentOS » Transparent HugePages Question
CentOS 4 Comments


I have a CentOS 7 installation on baremetal with 2 CPUs, 10 cores each and HT enabled, 128 GB RAM.

The system has transparent hugetables enabled.

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

The system reports anonymous hugepages pages usage and a size of hugepage of 2048Kb

cat /proc/meminfo |grep -i hugepages|grep AnonHugePages AnonHugePages: 35491840 kB

cat /proc/meminfo |grep -i hugepages|grep Hugepagesize Hugepagesize: 2048 kB

Anyway, checking the /proc//smaps for each and every process on the system, the KernelPageSize reports 4K pages only.

for i in `ls /proc/|egrep ‘[0-9]+’` ; do grep ‘KernelPageSize: ‘
/proc/$i/smaps; done|grep ‘ 4 kB’|wc -l
for i in `ls /proc/|egrep ‘[0-9]+’` ; do grep ‘KernelPageSize: ‘
/proc/$i/smaps; done|grep -v ‘ 4 kB’|wc -l

So it turns out that even is I have the THP enabled the pages still have a size of 4K .

Is there any extra setup in order to get 2MB pages ?

Thanks, Laurentiu

4 thoughts on - Transparent HugePages Question

  • Laurentiu Soica wrote:

    Be aware that with transparent huge pages enabled – I’m trying to remember what error you might get – it may be the “CPU blocked for x 120 seconds”, as it deals with the page.

    mark, back from vacation

  • So basically you’re saying that this THP feature is broken for CentOS 7 ?
    The feature is enabled by default. Is there a thread opened on this issue ?

    În mie., 24 aug. 2016 la 18:13, a scris:

    Laurentiu Soica

  • Laurentiu Soica wrote:

    I’m not sure it’s broken, per se, but rather that something that I don’t know may cause it to do this. It was certainly the case on 6.