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;