1.320 SGA_TARGET
SGA_TARGET
specifies the total size of all SGA components.
Property | Description |
---|---|
Parameter type |
Big integer |
Syntax |
|
Default value |
|
Modifiable |
|
Modifiable in a PDB |
Yes |
Range of values |
64 MB to operating system-dependent |
Basic |
Yes |
If SGA_TARGET
is specified, then the following memory pools are automatically sized:
-
Buffer cache (
DB_CACHE_SIZE
) -
Shared pool (
SHARED_POOL_SIZE
) -
Large pool (
LARGE_POOL_SIZE
) -
Java pool (
JAVA_POOL_SIZE
) -
Streams pool (
STREAMS_POOL_SIZE
) -
Data transfer cache (
DATA_TRANSFER_CACHE_SIZE
)
If these automatically tuned memory pools are set to nonzero values, then those values are used as minimum levels by Automatic Shared Memory Management. You would set minimum values if an application component needs a minimum amount of memory to function properly.
The following pools are manually sized components and are not affected by Automatic Shared Memory Management:
-
Log buffer
-
Other buffer caches, such as
KEEP
,RECYCLE
, and other block sizes -
Fixed SGA and other internal allocations
The memory allocated to these pools is deducted from the total available for SGA_TARGET
when Automatic Shared Memory Management computes the values of the automatically tuned memory pools.
In the Default value field, IMMEDIATE
mode autotuning requests are necessary to avoid ORA-04031
errors. The DEFERRED
and IMMEDIATE
modes are reflected in the OPER_MODE
column of the V$MEMORY_RESIZE_OPS
view.
If Automatic Memory Management is enabled (MEMORY_TARGET
is set to a positive value) and SGA_TARGET
is also set to a positive value, the SGA_TARGET
value acts as the minimum value for the size of the SGA.
Note:
This parameter is optional for pluggable databases (PDBs). When this parameter is set for a PDB, it specifies the maximum SGA that the PDB can use at any time. When this parameter is not set at the PDB level, the PDB has no limit for the amount of SGA it can use, other than the CDB's SGA size.
To be able to use Resource Manager in a CDB to control the amount of memory each PDB can use:
-
The
NONCDB_COMPATIBLE
initialization parameter must be set toFALSE
at the CDB level (in the root of the CDB). -
The
MEMORY_TARGET
initialization parameter must not be set at the CDB level. -
You must set the
SGA_TARGET
initialization parameter at the CDB level. -
You must set
SGA_TARGET
in a PDB.If you set a PDB’s
SGA_TARGET
value andSGA_TARGET
is not set at the CDB level, you will not receive an error message and the PDB’sSGA_TARGET
value will not be enforced. -
When setting
SGA_TARGET
in a PDB, the following requirements must be met:-
The value of
SGA_TARGET
in the PDB must be less than or equal to theSGA_TARGET
value at the CDB level. -
The value of
SGA_TARGET
in the PDB must be less than or equal to theSGA_MAX_SIZE
value at the CDB level. -
The value of
SGA_TARGET
in the PDB must be twice the PDB’sDB_CACHE_SIZE
value, if the PDB’sDB_CACHE_SIZE
value is set. -
The value of
SGA_TARGET
in the PDB must be twice the PDB’sSHARED_POOL_SIZE
value, if the PDB’sSHARED_POOL_SIZE
value is set. -
The value of
SGA_TARGET
in the PDB must be twice the PDB’sSGA_MIN_SIZE
value, if the PDB’sSGA_MIN_SIZE
value is set.
When you set
SGA_TARGET
in a PDB to a value that does not meet these requirements, you receive an error. -
See Also:
-
Oracle Multitenant Administrator's Guide for more information about the initialization parameters that control the memory usage of PDBs
-
Oracle Database Administrator’s Guide for information on automatic memory management
-
Oracle Database Administrator’s Guide for information on managing the SGA manually