There are 2 different mechanisms of hugepages in Debian/Ubuntu:

  • “standard” hugepages (must be specifically manually configured in apps)
  • transparent hugepages (available to all apps without configuration but it is usually discouraged to use them for databases)

Although Ubuntu and Debian are the “same family” they have different default settings regarding transparent hugepages.

  • You can check it with
    cat /sys/kernel/mm/transparent_hugepage/enabled
    • Ubuntu uses “always”
    • Debian uses “madvise” (=memory adviser)
  • How to use “standard” hugepages with MySQL is described in docu – https://dev.mysql.com/doc/refman/5.7/en/large-page-support.html
  • To check current usage of hugepages use
    cat /proc/meminfo | grep -i huge