ORA-04030 out of process memory when trying to allocate 16328 bytes (koh-kghu call ,pmuccst: adt/record)


ORA-04030: out of process memory when trying to allocate 16328 bytes (koh-kghu call ,pmuccst: adt/record)

  we face this issue in our environment when new function created and when it triggered in database level error generated, enthronement was oracle SE edition 11gR2 on linux server.

Errors in file -----------------------------------------------------------------------------_ora_15857.trc  (incident=280769):
ORA-04030: out of process memory when trying to allocate 16328 bytes (koh-kghu call ,pmuccst: adt/record)
Incident details in: -----------------------------------------------------------------------------_ora_15857_i280769.trc
Use ADRCI or Support Workbench to package the incident.
See Note 411.1 at My Oracle Support for error and packaging details.
Errors in file -----------------------------------------------------------------------------_ora_15857.trc  (incident=280770):
ORA-04030: out of process memory when trying to allocate 169040 bytes (pga heap,kgh stack)
ORA-04030: out of process memory when trying to allocate 16328 bytes (koh-kghu call ,pmuccst: adt/record)


some lines removed from above plz note that.

  from initial check we notice that from trace it generated while ran select statement using some function.

when we raise this case to vendor they suggest us to do fallow below for work around,  i just sharing info

-----------------------------
I've reviewed the relevant aspects for this case: 
- from trace file: 

========= Dump for incident 280953 (ORA 4030) ======== 
----- Beginning of Customized Incident Dump(s) ----- 
======================================= 
TOP 10 MEMORY USES FOR THIS PROCESS 
--------------------------------------- 
97% 3950 MB, 253563 chunks: "pmuccst: adt/record " PL/SQL 
koh-kghu call ds=0x7fe9499a1270 dsprt=0xb7cbd20 
3% 125 MB, 8051 chunks: "pmucalm coll " PL/SQL 
koh-kghu call ds=0x7fe9499a1270 dsprt=0xb7cbd20 
0% 161 KB, 22 chunks: "permanent memory " 
pga heap ds=0xb7cbd20 dsprt=(nil) 
0% 113 KB, 12 chunks: "free memory " 
session heap ds=0x7fe9499a66d8 dsprt=0xb7d1780 
0% 64 KB, 16 chunks: "kxsFrame4kPage " 
session heap ds=0x7fe9499a66d8 dsprt=0xb7d1780 
0% 63 KB, 1 chunk : "free memory " 
top uga heap ds=0xb7d1780 dsprt=(nil) 
0% 50 KB, 5 chunks: "permanent memory " 
session heap ds=0x7fe9499a66d8 dsprt=0xb7d1780 
0% 38 KB, 1 chunk : "Fixed Uga " 
Fixed UGA heap ds=0x7fe949e1db88 dsprt=0xb7cbd20 
0% 32 KB, 2 chunks: "permanent memory " 
top call heap ds=0xb7d1560 dsprt=(nil) 
0% 30 KB, 1 chunk : "free memory " 
top call heap ds=0xb7d1560 dsprt=(nil) 

======================================= 
PRIVATE MEMORY SUMMARY FOR THIS PROCESS 
--------------------------------------- 
****************************************************** 
PRIVATE HEAP SUMMARY DUMP 
4087 MB total: 
4086 MB commented, 193 KB permanent <----- here we see the 4G limit being hit 
105 KB free (64 KB in empty extents), 
4086 MB, 1 heap: "koh-kghu call " 3 KB free held 
------------------------------------------------------ 
Summary of subheaps at depth 1 
4076 MB total: 
4076 MB commented, 70 KB permanent 
125 KB free (0 KB in empty extents), 
3950 MB, 253563 chunks: "pmuccst: adt/record " 
... 

------------------------- 
Top 10 processes: 
------------------------- 
(percentage is of 4508 MB total allocated memory) 
91% pid 119: 4087 MB used of 4089 MB allocated <= CURRENT PROC <-- 4gb 
1% pid 20: 25 MB used of 27 MB allocated 
1% pid 21: 25 MB used of 27 MB allocated 
1% pid 22: 25 MB used of 27 MB allocated 
1% pid 23: 25 MB used of 27 MB allocated 
0% pid 103: 7935 KB used of 15 MB allocated (1024 KB freeable) 
... 

The error shows up because of running out of map entries from the OS. There are only 65536 memory map entries per process. 
The solution is to change the upper limit at either the OS or at the database level: 
- Change the page count at the OS level: 
sysctl -w vm.max_map_count=262144 (for example) 
**Please note the above changes will revert upon host reboot unless the changes are permanently made in the /etc/sysctl.conf file ** 
- Adjust the realfree heap pagesize within the database by setting the following parameters in the init/spfile and restart the database. 
For versions 11.2.0.4 and lower: 
_use_realfree_heap=TRUE 
_realfree_heap_pagesize_hint = 262144 

The default realfree allocator pagesize is 64 kB (65536), so 64K entries take up 4GB. With 256kB (262144) pages, the limit goes to 16GB. 

================================================================
my suggestion is most cases application team runs/create wrongly as per need, So better check with them and ask to change/remove those kind of unwanted function as per business needs.
========================================================================
please help to share your suggestions,  or  share your experience on same kind of issue in comment session.

  your sharing or suggestions will helps me to improve in my future posts.


Thanks for the visit!!!
  

Comments

Popular posts from this blog

SQL Tuning Task Creation ORA-13780: SQL statement does not exist.

Shareplex some commands

ORA-1092 : opitsk aborting process