Huge Pages in Oracle

HugePages is a feature integrated into the Linux kernel from Release 2.6 that allows large SGA memory to be utilized with reduced overhead by ensuring that the memory is not paged to disk. HugePages allows you to use much larger page sizes (for example, 2MB or 4MB) than the default 4K page size, which can be crucial for faster Oracle database performance on Linux, and increasingly so for systems with large RAM and database SGA sizes, as is the case even for small CC deployments.
 
HugePages results in smaller page tables and less CPU time spent on memory management, increasing the performance of large database instances
 
One possible drawback of using HugePages is that you cannot use it in conjunction with Automatic Memory Management (AMM); you must use Automatic Shared Memory Management (ASMM) instead. Therefore, before you decide to implement HugePages, you may want to weigh its advantages against any disadvantages of not being able to enable AMM.

Without HugePages, the operating system keeps each 4KB of memory as a page, and when it is allocated to the SGA, then the lifecycle of that page (dirty, free, mapped to a process, and so on) is kept up to date by the operating system kernel.

With HugePages, the operating system page table (virtual memory to physical memory mapping) is smaller, since each page table entry is pointing to pages from 2MB to 256MB. Also, the kernel has fewer pages whose lifecyle must be monitored.

You cannot use Automatic Memory Management (AMM) while implementing HugePages, because AMM works on dynamic SGA and PGA tuning. For example AMM can unmap the unused SGA space and map it to PGA and back. With HugePages contiguous pages are preallocated and cannot be used for anything else but for System V shared memory (for example, SGA).

When you use AMM, the entire SGA memory is allocated by creating files under /dev/shm. When Oracle Database allocates SGA with AMM, HugePages are not reserved. To use HugePages you must disable AMM.

 Oracle Metadata Link  https://www.oracle.com/ca-en/technical-resources/articles/it-infrastructure/dev-hugepages.html 

 

Aws Metadata Link : https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Oracle.Concepts.HugePages.html

Comments

Popular posts from this blog

Cold Backup Cloning of Database .

Find ALert log Location

FRA Usage and Administration