1. 程式人生 > >ORA-04031的解決辦法

ORA-04031的解決辦法

status = 4031-ORA-04031: unable to allocate 12312 bytes of shared memory ("shared pool","unknown object","KKSSP^422","kglseshtTable")).


查一下當前shared pool的大小

select sum(bytes)/1024/1024 mb from v$sgastat where pool='shared pool';


解決辦法:

用如下命令修改SGA_MAX_SIZE與SGA_TARGET的值,調大一些,比如調整為5G,資料庫正常。

SQL> alter system set sga_max_size=5G  scope=spfile; 
SQL> alter system set sga_target=5G  scope=spfile;