Saturday, November 24, 2012

ORA-04031: unable to allocate 4032 bytes of shared memory ("shared pool","oracle/aurora/rdbms/DbmsJavaSYS","joxlod: in ehe","ioc_allocate_pal")


(Oracle 8.1.7 on Windows 2000 cluster)


In  my case,  java_pool_size was 32KB. When increased to 50MB, solved the problem.

***********************************************************************


Doc ID :  Note:19837.1

Error:  ORA 4031 Text:   unable to allocate %s bytes of shared memory (%s,%s,%s)

Cause:  More shared memory is needed than was allocated in the shared   pool.

Action: Either use the dbms_shared_pool package to pin large packages,  reduce your use of shared memory, or increase the amount of  available shared memory by increasing the value of the init.ora parameter "shared_pool_size".

 *** Important: The notes below are for experienced users - See [NOTE:22080.1]

Explanation: Over a period of time the free memory in the shared pool may become fragmented. When any attempt to allocate a large piece of memory in the shared pool fails Oracle first flushes all objects that are not currently in use from the pool and the resulting free memory chunks are merged. If there is still not a single chunk large enough to satisfy the request ORA 4031 is returned.

Note that in 7.3.4 onwards there are 2 parameters to help control this problem:
SHARED_POOL_RESERVED_SIZE and  SHARED_POOL_RESERVED_MIN_ALLOC

In Oracle 8.1.X if trying to use Java functionality and an ORA-4031 may occur.  To resolve this problem increase the init.ora parameter  Java_Pool_Size.

No comments:

Post a Comment