oracle 19c数据库W00n进程使用很多PGA内存资源的分析

devtools/2024/9/22 23:28:16/

今天,客户反馈测试环境的数据库PGA资源不足,报错ORA-04036: 实例使用的 PGA 内存超出 PGA_AGGREGATE_LIMIT;分析是多个W00n进程使用大量PGA-触发了BUG,对应解决办法就是打补丁。(民间办法就是KILL进程、重启数据库),如下为分析过程:

报错信息:

java.sql.SQLException: ORA-04036: 实例使用的 PGA 内存超出 PGA_AGGREGATE_LIMIT atoracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:445) atoracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:396) atoracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:879) atoracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:450) atoracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:192) atoracle.jdbc.driver.T4C8Oall.doOALL(T4C8Oall.java:531) at oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.java:207)   oracle@localhost:/u01/app/oracle/diag/rdbms/cdb1/cdb1/trace$oerr ora 4036 04036, 00000, "PGA memory used by the instance exceeds PGA_AGGREGATE_LIMIT" // *Cause: Private memory across the instance exceeded the limit specified // in the PGA_AGGREGATE_LIMIT initialization parameter. The largest // sessions using Program Global Area (PGA) memory were interrupted // to get under the limit. // *Action: Increase the PGA_AGGREGATE_LIMIT initialization parameter or reduce // memory usage.     pga_aggregate_limit limit of aggregate PGA memory consumed by the instance  

问题分析:

查看总的PGA分布:select sum(pga_alloc_mem)/(1024*1024) "Mbytes allocated", sum(pga_used_mem)/(1024*1024) "Mbytes used" from v$process;

查找占用内存多的进程:使用SQL;

SELECT DECODE(TRUNC(SYSDATE - LOGON_TIME), 0, NULL, TRUNC(SYSDATE - LOGON_TIME) || ' Days' || ' + ') ||
TO_CHAR(TO_DATE(TRUNC(MOD(SYSDATE-LOGON_TIME,1) * 86400), 'SSSSS'), 'HH24:MI:SS') LOGON,
SID, v$session.SERIAL#, v$process.SPID , ROUND(v$process.pga_used_mem/(1024*1024), 2) PGA_MB_USED,
v$session.USERNAME, STATUS, OSUSER, MACHINE, v$session.PROGRAM, MODULE
FROM v$session, v$process
WHERE v$session.paddr = v$process.addr ORDER BY 4 DESC ;

数据库版本为默认的19.3,未安装RU补丁包。分析此进程,是触发了BUG:Bug 30098251 - WNNN PROCCESSES CREATE AN EXCESSIVE NUMBER OF OPEN CURSORS investigated the issue where Wnnn process has high number of open cursors and consuming more memory.

关于此BUG的描述是:

Each Wnnn Background Process is consuming around 140MB of pga ( can be more as well) and holding hundreds of opened
cursors causing memory usage of instance to go high.
The sessions appear to remain open (session state ACTIVE), holding these cursors.
The Wnnn and SMCo processes appear to remain active for weeks at a time, as we can seen by logon time.

解决办法是:

1、民间办法:KILL进程、或者定期重启数据库
2、官方办法:SOLUTION:
1. Apply Patch 30098251 available for your release and platform
OR
2. Upgrade to below releases where the fix for 30098251 is first included.
20.1.0
19.6.0.0.200114 (Jan 2020) Database Release Update (DB RU)
18.9.0.0.200114 (Jan 2020) Database Release Update (DB RU)
12.2.0.1.200114 (Jan 2020) Database Release Update (DB RU)
12.1.0.2.200114 (Jan 2020) Database Proactive Bundle Patch
12.2.0.1.200114 (Jan 2020) Bundle Patch for Windows Platforms
There is no workaround for this issue.


http://www.ppmy.cn/devtools/8846.html

相关文章

Vue2 基础四前后端交互

代码下载 前后端交互模式 接口调用方式:原生ajax、基于jQuery的ajax、fetch、axios。 URL 地址格式 传统形式的 URL 格式:schema://host:port/path?query#fragment schema:协议。例如http、https、ftp等host:域名或者IP地址…

完成学校官网页面制作

<!DOCTYPE html> <html lang"en"> <head> <meta charset"UTF-8"> <title>教务系统</title> <style> .wap{ margin:0 auto; width:955px; } .top{ height:150px; padding-left:85px; …

软件测试金三银四招聘季,好公司10大特点VS烂公司10大特点

选择公司&#xff0c;就是在选自己未来的命运。 遇到一家好公司&#xff0c;你未来的职业道路&#xff0c;生活水平&#xff0c;工作热情&#xff0c;技术提升都是积极生长的。 但遇到一家烂公司&#xff0c;你未来的一年甚至几年&#xff0c;都将处在水深火热之中。 有时候仅仅…

FFmpeg合并音视频文件操作备忘(mac版)

利用NDM嗅探插件从B站下载下来的文件是音视频分开的&#xff0c;用剪辑软件合并时发现导出时文件都特别大&#xff0c;于是使用FFmpeg处理 环境&#xff1a; MBP M1芯片版 系统 macOS Sonama 14.4.1 操作步骤&#xff1a; 一、官方下载链接&#xff1a;https://evermeet.cx/…

使用SpringBoot3+Vue3开发公寓管理系统

项目介绍 公寓管理系统可以帮助公寓管理员更方便的进行管理房屋。功能包括系统管理、房间管理、租户管理、收租管理、房间家具管理、家具管理、维修管理、维修师傅管理、退房管理。 功能介绍 系统管理 用户管理 对系统管理员进行管理&#xff0c;新增管理员&#xff0c;修改…

Pytorch实用教程:nn.Linear内部是如何实现的,从哪里可以看到源码?

文章目录 nn.Linear简介nn.Linear 基本介绍nn.Linear 的参数 nn.Linear源码解析查看源码的方法nn.Linear 的核心源码 nn.Linear用法的示例代码示例说明示例代码代码解释 nn.Linear简介 nn.Linear 是 PyTorch 中非常基础的一个模块&#xff0c;用于实现全连接层。下面我会详细解…

mars3d实现禁止地图移动,禁止地图左右平移,但是鼠标可以移动的效果。

new mars3d.layer.GeoJsonLayer({渲染后实现鼠标左键按住不释放拖动时&#xff0c;地图不跟着拖动效果 当前问题&#xff1a; 1.在map初始化&#xff0c;或者是加载效果的时候&#xff0c;整个地球的场景都是一样的。 如果鼠标左键按住不释放&#xff0c;在屏幕上拖动的时候…

ESLlint重大更新后,使用旧版ESLint搭配Prettier的配置方式

概要 就在前几天&#xff0c;ESLint迎来了一次重大更新&#xff0c;9.0.0版本&#xff0c;根据官方文档介绍&#xff0c;使用新版的先决条件是Node.js版本必须是18.18.0、20.9.0&#xff0c;或者是>21.1.0的版本&#xff0c;新版ESLint将不再直接支持以下旧版配置(非扁平化…