To enable large page support in DB2® database
systems on AIX® operating
systems, you must configure some operating system parameters and then
set the DB2_LARGE_PAGE_MEM registry variable.
Before you begin
You
must have root authority to work with the AIX
operating system commands.
About this task
In
addition to the traditional page size of 4 KB, the POWER4 processors (and higher) on System z® also
support a 16 MB page size. Applications such as IBM® DB2 Version 10.1 for AIX,
that require intensive memory access and that use large amounts of
virtual memory can gain performance improvements by using large pages.
Note: - Setting the DB2_LARGE_PAGE_MEM registry variable
also implies that the memory is pinned.
- You should be extremely cautious when configuring your system
for pinning memory and supporting large pages. Pinning too much memory
results in heavy paging activities for the memory pages that are not
pinned. Allocating too much physical memory to large pages degrades
system performance if there is insufficient memory to support the
4 KB pages.
Restrictions
When
large pages are enabled for the database memory area, the self-tuning
memory manager (STMM) does not tune the overall database memory configuration.
Assign a specific setting to DATABASE_MEMORY based on performance
requirements. STMM tunes the internal memory areas (bufferpool, locklist,
shared sort, package cache) to make optimal use of the memory that
is assigned to the database memory area. For more information about
DATABASE MEMORY, see database_memory.
Because
database memory tuning that STMM normally performs is disabled, enabling
large pages should only be considered for well-defined workloads that
have relatively static database memory requirement.
Procedure
To enable large page support in DB2 database
systems on AIX operating
systems:
- Configure your AIX server
for large page support by issuing the vmo command
with the following flags:
vmo -r -o lgpg_size=LargePageSize -o lgpg_regions=LargePages
Where LargePageSize specifies
the size in bytes of the hardware-supported large pages, and LargePages specifies
the number of large pages to reserve. For example,
if you want to allocate 25 GB for large page support, run the command
as follows:
vmo -r -o lgpg_size=16777216 -o lgpg_regions=1600
For
detailed instructions on how to run the vmo command,
refer to your AIX manuals.
- Run the bosboot command so that the vmo command
that you previously ran takes effect following the next system boot.
- After the server comes up, enable it for pinned memory. Issue the vmo command with the following
flags:
vmo -o v_pinshm=1
- Use the db2set command to set the DB2_LARGE_PAGE_MEM registry
variable to DB, then start the DB2 database
manager. For example:
db2set DB2_LARGE_PAGE_MEM=DB
db2start
Results
When
these steps are complete, the
DB2 database
system directs the operating system to use large page memory for the
database shared memory region.