Oracle AIX Process Memory tuning
The AIX operating system
provides a robust environment for running processes with a wide variety of
execution characteristics. By taking advantage of the many variables and
features to tune the process environment specifically for the Oracle
application, memory usage of each Oracle process is reduced.
The AIXTHREAD_SCOPE environment variable can be used for control if a
process runs with process-wide contention scope (the default) or with
system-wide contention scope. When using system-wide contention scope, there
is a one-to-one mapping between the user thread and a kernel thread. On
UNIX? systems, Oracle applications are primarily multiprocess and
One of the mechanisms that
enables this multiprocess system to operate effectively is the AIX post/wait
mechanism: thread_post(), thread_post_many(), and thread_wait(). It operates
most effectively with the Oracle application when using system-wide
contention scope (AIXTHREAD_SCOPE=S).
As of AIX V5.2, system-wide
contention scope will also significantly reduce the memory required for each
Oracle process. For these reasons, always export AIXTHREAD_SCOPE=S before
starting all Oracle processes. In Oracle Database 10g a newer, system-wide
contention scope is set internally when the instance and user processes are
Oracle AIX memory pinning
The AIX operating system
allows shared memory to be allocated in pinned memory for improved
performance. Pinned memory is always present in real memory; it is not paged
in and out. The primary advantage of using pinned memory for the Oracle
System Global Area (SGA) is that I/O from pinned memory is optimized for
improved path length.
This is possible because
the asynchronous I/O routines do not need to pin the SGA memory each time it
is used for an I/O operation. Because of this performance improvement, it is
best to use pinned memory to allocate the Oracle SGA.
When the Oracle initialization parameter LOCK_SGA is set to TRUE, Oracle
will allocate shared memory for the SGA using the AIX pinned memory. (Note:
shmget() is called with the SHM_PIN flag set.) In addition to setting the
Oracle LOCK_SGA parameter to TRUE, the AIX operating system must be
configured to allow pinned memory to be used for shared memory.
AIX Oracle large page
Give the Oracle user ID the
CAP_BYPASS_RAC_VMM and CAP_PROPAGATE capabilities by following these steps:
1. First check the current capabilities: #lsuser ?a capabilities oracle
Note: only the root user can display the capabilities attribute.
2. Add the CAP_BYPASS_RAC_VMM and CAP_PROPAGATE capabilities to the list of
capabilities already assigned to this user ID, if any: #chuser capabilities=CAP_BYPASS_RAC_VMM,CAP_PROPAGAE
3. Configure the AIX large page pool by calculating the number of large
pages required for the SGA: num_of_large_pages = INT((total_SGA_size-1)/16MB)+1
4. Configure the number and size of large pages: #vmo -p -o lgpg_regions=num_of_large_pages
Oracle AIX I/O Tuning
Asynchronous I/O allows a
program to initiate I/O and continue execution of useful work, while other
I/O operations are carried out in parallel by the operating system. Because
Oracle applications often require multiple server and user processes at the
same time, they take advantage of asynchronous I/O to overlap program
execution with I/O operations.
Asynchronous I/O is used
with Oracle on the AIX operating system to improve system performance.
In AIX V5.2 and newer versions, two asynchronous I/O subsystems are
supported, the original asynchronous I/O (called Legacy asynchronous I/O),
and the new POSIX asynchronous I/O.
The two types of
asynchronous I/O differ in the way the asynchronous I/O subsystem API is
defined. Their performance characteristics are the same. All Oracle releases
up to and including the current release, Oracle Database 10g, use Legacy