9i出现内存分配错误

在9.2.0.8 RAC环境中,告警日志频繁出现内存分配错误的信息。
错误信息如下:

Wed May 2 10:20:43 2012
Trace dumping IS performing id=[cdmp_20120502102043]
There are 1444 memory allocation errors FOR object-level stat
IN the LAST 15 minutes
.
.
.
There are 1605 memory allocation errors FOR object-level stat
IN the LAST 15 minutes

在另外一个节点上则出现了ORA-4031错误:

Sun Apr 29 22:30:52 2012
Errors IN file /oracle/admin/orcl/bdump/orcl2_j000_1204632.trc:
ORA-12012: error ON auto EXECUTE OF job 527
ORA-04031: unable TO allocate 4224 bytes OF shared memory ("shared pool","unknown object","sga heap(2,0)","object level s")
ORA-06512: at "PERFSTAT.STATSPACK", line 2479
ORA-06512: at "PERFSTAT.STATSPACK", line 91
ORA-06512: at line 1
Sun Apr 29 23:03:14 2012
Errors IN file /oracle/admin/orcl/bdump/orcl2_j001_1528536.trc:
ORA-12012: error ON auto EXECUTE OF job 527
ORA-04031: unable TO allocate 4256 bytes OF shared memory ("shared pool","unknown object","sga heap(2,0)","obj stat memor")
ORA-06512: at "PERFSTAT.STATSPACK", line 2479
ORA-06512: at "PERFSTAT.STATSPACK", line 91
ORA-06512: at line 1
There IS 1 memory allocation error FOR object-level stat
IN the LAST 15 minutes
There are 66 memory allocation errors FOR object-level stat
IN the LAST 15 minutes
There are 8 memory allocation errors FOR object-level stat
IN the LAST 15 minutes
Mon Apr 30 00:07:38 2012
Errors IN file /oracle/admin/orcl/bdump/orcl2_j001_942754.trc:
ORA-12012: error ON auto EXECUTE OF job 527
ORA-04031: unable TO allocate 4256 bytes OF shared memory ("shared pool","unknown object","sga heap(2,0)","obj stat memor")
ORA-06512: at "PERFSTAT.STATSPACK", line 2479
ORA-06512: at "PERFSTAT.STATSPACK", line 91
ORA-06512: at line 1
There are 354 memory allocation errors FOR object-level stat
IN the LAST 15 minutes
There are 653 memory allocation errors FOR object-level stat
IN the LAST 15 minutes
Mon Apr 30 02:07:45 2012
Thread 2 advanced TO log SEQUENCE 71531
CURRENT log# 5 seq# 71531 mem# 0: /dev/rlv_redo22_128m
Mon Apr 30 02:07:45 2012
ARC0: Evaluating archive log 4 thread 2 SEQUENCE 71530
ARC0: Beginning TO archive log 4 thread 2 SEQUENCE 71530
Creating archive destination LOG_ARCHIVE_DEST_1: '/archive2/2_71530.dbf'
ARC0: Completed archiving log 4 thread 2 SEQUENCE 71530
There are 41 memory allocation errors FOR object-level stat
IN the LAST 15 minutes

ORA-4031错误比较常见,简单的说就是内存不足所致。从上面的错误信息看,内存不足发生在共享池上。而Memory allocation errors同样是共享池空间不足的表现,可以参考文章Memory Allocation Errors For Object-Level Stat Appearing in the Alert Log File [ID 757895.1]。
针对这个问题,可以通过设置隐含参数_OBJECT_STATISTICS=FALSE来禁用对象级统计信息,但是最彻底的方法还是增加共享池空间。

This entry was posted in BUG and tagged , , , . Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *