Oracle dblink 发现Network 等待事件的分析 enq: KO - fast object checkpoint
所有的sql 通过dblink 查询全部等待中,

同一个SQL 20多个session 在跑,等待事件network,可能怀疑是不是网络断开了,导致没有返回

执行sql 如下:
BEGIN X@dblink ; END;
去到dblink 所在的db,发现20多个sql在执行一个sql,等待事件fast object check point

发现同一个sql的两个执行计划,最终发现PK index失效导致。




The following SELECT Statement shows different elapsed time from the original database to the coloning database.
For the excution plan, database parameters and rows of table are same on two databases.
SELECT *
FROM xxx MMT
WHERE mmt.xxx_id = 1661
1. On Original database: elapsed time is 10s.
2. On cloning database: elapsed time is 72s.
The direct path read wait event from cloning database consumes 65s in the below 10046 trace.
call count cpu elapsed disk query current rows
------- ------ -------- ---------- ---------- ---------- ---------- ----------
Parse 1 0.04 0.03 0 0 0 0
Execute 1 0.00 0.00 0 0 0 0
Fetch 2 7.75 72.17 611660 612506 0 1
------- ------ -------- ---------- ---------- ---------- ---------- ----------
total 4 7.79 72.21 611660 612506 0 1
Misses in library cache during parse: 1
Optimizer mode: ALL_ROWS
Parsing user id: 173
Number of plan statistics captured: 1
Rows (1st) Rows (avg) Rows (max) Row Source Operation
---------- ---------- ---------- ---------------------------------------------------
1 1 1 TABLE ACCESS FULL xxx (cr=612506 pr=611660 pw=0 time=0 us cost=167711 size=277 card=1)
Elapsed times include waiting on following events:
Event waited on Times Max. Wait Total Waited
---------------------------------------- Waited ---------- ------------
SQL*Net message to client 2 0.00 0.00
SQL*Net more data to client 1 0.00 0.00
enq: KO - fast object checkpoint 1 0.00 0.00
direct path read 38390 0.45 65.02 <<<<<<<<<<<<<<< direct path read : 65s
SQL*Net message from client 2 37.56 37.56
enq: KO - fast object checkpoint 1 0.00 0.00 --SGA 压力 不足
1.
"enq: KO - fast object checkpoint" is a wait event that is waiting until the checkpoints finishes in a particular object level.
At checkpoints, dirty buffers(updated buffers) on the buffer cache has to be written out to the disk by DBWR.
This checkpoint occurs by object level so if the process is not related to this particular object, the client should not have a delay from it.
However when DBWR process is under high load, it might affect to the performance.
2.
All reporting queries are doing full table scans concurrently. Oracle uses direct path reads instead of db file scattered reads. And direct path reads require a checkpoint
SOLUTION
"_serial_direct_read"=NEVER
WARNING: This solution is for non-Exadata system only. On Exadata system please don't disable direct path reads as it is critical to SmartIO benefits.
3. 就是cache不足, keep为0 所以不停的读盘
- EM displays a huge amount of 'Application' and 'Other' on the 'Average active sessions' chart compared to normal
- CKPT process consistently high in the process list
- AWR top 5 wait events show :
- "enq: KO - fast object checkpoint"
- "reliable message"
- ASH report Top SQL with Top Events shows queries with high waits on "enq: KO - fast object checkpoint"
- A review of the tables in the query revealed that the table is defined to use the keep cache:
...
STORAGE(INITIAL 327680 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645
PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1
BUFFER_POOL KEEP FLASH_CACHE <<<######
DEFAULT CELL_FLASH_CACHE DEFAULT) - The Initialization parameters section in AWR report indicate that DB_KEEP_CACHE_SIZE was not set,
CAUSE
Tables involved in the process that is waiting on these events have buffer_pool = keep but the keep buffer pool was not configured on these instances.
Altering these tables to use the default buffer pool resolved the issue.
This issue was due to the excessive direct path reads that occurred as a result of the misconfiguration explained above and is dealt with in:
Bug 12530276 High 'direct path read' waits when buffer pools are not setup.
SOLUTION
1. The bug is fixed in 11.2.0.3
2. Workarounds:
- Change the object definitions with keep buffer cache to use the default buffer cache
- Allocate a keep buffer pool by setting parameter DB_KEEP_CACHE_SIZE to a non-zero value
CHANGES
CAUSE
It's due to buffer cache overflow on cloning database. So, the query become slow when data reads from the disk.
Note : The SGA_SIZE is 32G. However the the current usage of buffer cache(__db_cache_size) reaches to 30G. So, It indicted that buffer cache was almost fully used by other hot data.
SOLUTION
Options:
1. Flush buffer cache only when it's a test server.
sqlplus / as sysdba
SQL> alter system flush buffer_cache;
- or -
2. keep the data of table into keep buffer cache
-- Check the table size
select BYTES/1024/1024 as SIZE_MB , table_name, owner from dba_segments where table_name = '<TABLE_NAME>';
-- Check KEEP buffer cache size
select component, current_size
from v$memory_dynamic_components
where component = 'KEEP buffer cache';
-- Increase keep buffer cache size if needed
alter system set db_keep_cache_size = 500m scope=both;
Note: the size 500m is an example.
-- Keep whole data of table into keep buffere cache
alter table <TABLE_NAME> storage( buffer_pool keep);
-- Check the table whether in keep buffer cache
select buffer_pool
from dba_tables
where table_name = '<TABLE_NAME>';
相关文章:
Oracle dblink 发现Network 等待事件的分析 enq: KO - fast object checkpoint
所有的sql 通过dblink 查询全部等待中, 同一个SQL 20多个session 在跑,等待事件network,可能怀疑是不是网络断开了,导致没有返回 执行sql 如下: BEGIN Xdblink ; END; 去到dblink 所在的db,发现20多个sql在…...
SpringMVC:向三大域对象存数据
1. 简介 Servlet中的三个域对象 请求域:request会话域:session应用域:application 主要是通过:setAttribute getAttribute方法来完成在域中数据的传递和共享。 点击跳转Servlet详细概念 // 向域中存储数据 void setAttribute(St…...
如何用python做一个用户登录界面——浔川python社
1 需解决的问题: 1.1如何用python做一个用户登录界面? 1.2需要用到哪些库、模块? 2 问题解决: 2.1 回答 1.1 :合理即可,无标准回答。 2.2 回答 1.2 :tk库(缩写)、GUL界面…...
Python知识点9---推导式
提前说一点:如果你是专注于Python开发,那么本系列知识点只是带你入个门再详细的开发点就要去看其他资料了,而如果你和作者一样只是操作其他技术的Python API那就足够了。 Python提供的推导式,只对列表、字典、集合三种数据类型生…...
用C++做一个跑酷游戏
要用C创建一个跑酷游戏是一个相对复杂的任务,因为它涉及到图形渲染、用户输入处理、物理模拟等多个方面。由于C本身并不直接支持图形渲染,我们通常需要使用一个图形库来帮助我们实现这一点。 一个常用的选择是使用SFML(Simple and Fast Mult…...
基于字典树可视化 COCA20000 词汇
COCA20000 是美国当代语料库中最常见的 20000 个词汇,不过实际上有一些重复,去重之后大概是 17600 个,这些单词是很有用,如果能掌握这些单词,相信会对英语的能力有一个较大的提升。我很早就下载了这些单词,…...
TypeScript 中的命名空间
1. 命名空间的概念 命名空间是 TypeScript 提供的一种组织代码的方式,它类似于其他编程语言中的模块化系统,但有一些不同之处。命名空间可以包含变量、函数、类等,并且可以嵌套使用,从而更好地组织和管理代码。 2. 定义命名空间…...
[C++] 小游戏 斗破苍穹 2.2.1至2.11.5全部版本(上) zty出品
大家好,今天zty整合了斗破苍穹2.2.1到2.11.5的所有版本 我这么辛苦,就要50个赞吧 2.2.1 #include<stdio.h> #include<ctime> #include<time.h> //suiji #include<windows.h> //SLEEP函数 struct Player //玩家结构体,并初始化player { char name[…...
单元测试的心法分享
大家好,我是G探险者! 今天我们简单聊聊单元测试的哪些事儿~ 两天时间我玩明白了单元测试的套路。 这里我分享一下思路。 在我眼里单元测试室什么? 请看这张草图: 单元测试主要关注单个代码单元(通常是类或方法&am…...
【python】多线程(3)queue队列之不同延时时长的参数调用问题
链接1:【python】多线程(笔记)(1) 链接2:【python】多线程(笔记)(2)Queue队列 0.问题描述 两个线程,但是不同延时时长,导致数据输出…...
Java开发常见基础问题
Java开发的多个方面,包括但不限于Java基础知识、多线程并发、JVM、框架使用、数据库、设计模式、网络编程等。 以下是一些常见的问题以及回答的方向: Java 开发技术常见问题(一) Java 基础知识 对象和类的区别是什么࿱…...
大数据组件doc
1.flink Apache Flink Documentation | Apache Flink 2.kafka Apache Kafka 3.hbase Apache HBase ™ Reference Guide 4.zookeeper ZooKeeper: Because Coordinating Distributed Systems is a Zoo 5.spark Overview - Spark 3.5.1 Documentation 6.idea组件(…...
Docker Hub 国内镜像源配置
Docker Hub 国内镜像源配置 Docker Hub 国内镜像源是指在国内境内提供 Docker 镜像服务的镜像源。由于国际网络带宽等问题,国内用户下载 Docker 镜像通常速度较慢。因此,为了解决这个问题,一些国内的公司和组织提供了 Docker 镜像的国内镜像…...
持续总结中!2024年面试必问 20 道 Kafka面试题(一)
一、Kafka 的基础概念有哪些? Kafka 是一个分布式流处理平台,由 LinkedIn 开发,并于 2011 年成为 Apache 软件基金会的一部分。以下是 Kafka 的一些基础概念: Broker: Kafka 集群由多个 Broker 组成,每个 Broker 存储…...
Linux共享内存创建和删除
最近项目中使用到了共享内存记录下 创建共享内存: 删除共享内存: 代码: #include <stdio.h> #include <stdlib.h> #include <string.h> #include <fcntl.h> #include <sys/mman.h> #include <sys/stat.h> #include <u…...
微信小程序如何自定义tabbar
微信小程序自定义底部tabbar是一个提升用户体验和增加小程序个性化的重要功能。以下是自定义底部tabbar的步骤,以供参考: 一、自定义tabbar的重要性 微信小程序默认的底部导航栏(tabbar)样式和布局是固定的,开发者无…...
【并发程序设计】15.信号灯(信号量)
15.信号灯(信号量) Linux中的信号灯即信号量是一种用于进程间同步或互斥的机制,它主要用于控制对共享资源的访问。 在Linux系统中,信号灯作为一种进程间通信(IPC)的方式,与其他如管道、FIFO或共享内存等IPC方式不同&…...
【操作与配置】VS2017与MFC环境配置
【操作与配置】VS2017与MFC环境配置 概述 Visual Studio 是一款强大且多功能的集成开发环境(IDE),适用于软件开发人员和团队。使用此应用程序,您可以构建和调试现代Web应用程序,并利用扩展帮助探索几乎任何编程语言。…...
遥感影像信息提取
刘老师(副教授),来自双一流重点高校,长期从事GIS/RS/3S技术及其生态环境领域中的应用等方面的研究和教学工作,并参与GIS的二次开发,发表多篇sci论文,具有资深的技术底蕴和专业背景。 专题一&am…...
LRU算法
文章目录 LRU算法LRU 如何实现LinkedHashMap来实现的LRU算法的缓存HashMap实现LRU算法的缓存 LRU算法 LRU(Least Recently Used)算法可以使用哈希表和双向链表来实现。哈希表用于快速查找数据,双向链表用于记录数据的访问顺序。以下是LRU算法…...
AMD Ryzen SMU Debug Tool完整指南:轻松掌握硬件级调试的5个关键步骤
AMD Ryzen SMU Debug Tool完整指南:轻松掌握硬件级调试的5个关键步骤 【免费下载链接】SMUDebugTool A dedicated tool to help write/read various parameters of Ryzen-based systems, such as manual overclock, SMU, PCI, CPUID, MSR and Power Table. 项目地…...
如何轻松地将数据从Android传输到 iPhone ?
从Android切换到 iPhone可能会让人不知所措,尤其是当你想在不重置新设备的情况下保持数据完整时。许多指南都侧重于恢复出厂设置,但在本文中,我们将探讨一些方法,让你能够无缝转移宝贵的数据,而无需清除 iPhone 上的所…...
【ElevenLabs丹麦文语音实战指南】:20年AI语音工程师亲测的5大本地化避坑法则与自然度调优秘籍
更多请点击: https://intelliparadigm.com 第一章:ElevenLabs丹麦文语音本地化实战的底层逻辑与认知重构 ElevenLabs 的语音合成能力并非仅依赖于多语言模型堆叠,其丹麦文(da-DK)本地化本质是声学特征解耦、韵律迁移与…...
武汉大学等高校联手揭露AI助手的“记忆盲区“:它们真的记得你吗?
这项由武汉大学、香港中文大学和香港科技大学联合开展的研究以预印本形式于2026年5月发表,论文编号为arXiv:2605.06527,有兴趣深入了解的读者可以通过该编号查询完整论文。你有没有试过这样一件事:你和手机里的AI助手聊了很久,告诉…...
独立开发者如何利用Taotoken的透明计费规避项目超支风险
🚀 告别海外账号与网络限制!稳定直连全球优质大模型,限时半价接入中。 👉 点击领取海量免费额度 独立开发者如何利用Taotoken的透明计费规避项目超支风险 对于独立开发者而言,项目预算的控制是决定项目能否持续、健康…...
5步打造你的英雄联盟智能游戏助手:从零到效率革命的完整指南
5步打造你的英雄联盟智能游戏助手:从零到效率革命的完整指南 【免费下载链接】League-Toolkit An all-in-one toolkit for LeagueClient. Gathering power 🚀. 项目地址: https://gitcode.com/gh_mirrors/le/League-Toolkit 还在为英雄联盟中繁琐…...
微信小程序互助交流
微信小程序互助群 你开发了一个微信小程序, 准备接广告, 卡在了 500 个 UV 这里, 想找大佬帮忙,结果大佬说要收一张费—— 于是我建了一个微信群, 大家互助,免费入群,入群条件: 每人…...
如何查阅与分析Taotoken平台提供的详细用量账单
🚀 告别海外账号与网络限制!稳定直连全球优质大模型,限时半价接入中。 👉 点击领取海量免费额度 如何查阅与分析Taotoken平台提供的详细用量账单 对于使用大模型API的开发者与团队而言,清晰、准确地掌握资源消耗与成本…...
使用Taotoken CLI工具一键为团队所有网站项目配置统一API接入点
🚀 告别海外账号与网络限制!稳定直连全球优质大模型,限时半价接入中。 👉 点击领取海量免费额度 使用Taotoken CLI工具一键为团队所有网站项目配置统一API接入点 在团队协作开发中,确保所有成员使用统一的大模型API接…...
GHelper:华硕笔记本性能调优的轻量级革命
GHelper:华硕笔记本性能调优的轻量级革命 【免费下载链接】g-helper Lightweight Armoury Crate alternative for Asus laptops with nearly the same functionality. Works with ROG Zephyrus, Flow, TUF, Strix, Scar, ProArt, Vivobook, Zenbook, Expertbook, RO…...
