When And Why To Use HugePages on Linux x86-64?
Last updated on NOVEMBER 01, 2017
Applies to:Oracle Database - Standard Edition - Version 10.1.0.2 to 126.96.36.199 [Release 10.1 to 12.2]
This document applies only to database with large SGA and / or many sessions.
Many documents describe the usage of HugePages on Linux as a possibility but do not emphasize enough that HugePages becomes a requirement in certain database configurations.
For a database with a small SGA or with a small number of connected users (small 'sessions') configuring HugePages won't give any improvement.
But for a database with large SGA (above 2Gb) and with many connected users (sessions>500) configuring HugePages becomes mandatory in order to diminish the memory usage at the OS level and to improve overall performance of the database.
The following symptoms can be observed on Linux x86-64 systems:
- poor performance of the database, slow sessions, slow queries
- low free physical memory on the system or swapping
All these symptoms happen with no obvious evidence of high memory usage on the instance side: SGA + total PGA used is much less then physical memory.
Looking at OS level we see high 'Filesystem cache', shown as "cache" or "buff/cache" in the output of 'free', despite the fact that database uses directIO (IO with the datafiles bypass Filesystem cache).
A database uses directIO when it has ASM or it has any of the following parameters:
During the problem time, the size of PageTables from /proc/meminfo is high, e.g it can be equal or greater then the entire SGA.
Increased the SGA to a larger value, or increased the number of sessions, or more users started to use this database and started to experience one of the described symptoms.
This is not happening all the time but only during peak hours, when there are many connected sessions at database level.
This document applies only to database with large SGA and/or many connected sessions.
Sign In with your My Oracle Support account
Don't have a My Oracle Support account? Click to get started
Million Knowledge Articles and hundreds of Community platforms