Last encounter a case:
At the customer site when running version 18.104.22.168 utlrp.sql compile the script, the following error:
ORA-12801: error signaled in parallel query server P237
ORA-12853: insufficient memory for PX buffers: current 84352K, max needed 13280400K
ORA-04031: unable to allocate 65560 bytes of shared memory ( "large pool", "unknown object", "large pool", "PX msg pool")
ORA-06512: at "SYS.UTL_RECOMP", line 804
ORA-06512: at line 4
The degree of parallelism used for recompilation is determined automatically based on instance parameters cpu_count and parallel_threads_per_cpu.
On systems with high number of cpus that can lead to high degree of parallelism and lead to high memory usage overall and high memory usage in the large pool since it is used by parallel execution for message buffers.
By default utlrp.sql passes a 0 to utlprp.sql:
From the above explanation we can rely on cpu_count know the value and parallel_threads_per_cpu if more cpu, this will be a high degree of parallelism, resulting in large pool uses more memory
So to solve this problem is simple
Reduce the degree of parallelism value instance
alter system set PARALLEL_MAX_SERVERS = 5 scope = both;
alter system set PARALLEL_SERVERS_TARGET = 2 scope = both;