Oracle Enqueue Names Enquences 是为了管理 连续访问数据库资源而设计的一种共享内存结构也叫锁。它们可以与会话或事务相关联。Enquences 名显示在DBA_LOCK和DBA_LOCK_INTERNAL数据字典视图的LOCK_TYPE列中。资源被唯一地标识一个对象,该对象可以被一个实例(本地资源)或多个实例之间(全局资源)的不同会话锁定。每个想试图锁定资源的会话都在该资源上生成一个队列。 下面是Oracle Enqueues对资源申请的锁模式和申请资源Enqueues are usually represented in the format "TYPE-ID1-ID2" where: "TYPE" is a 2 character text string"ID1" is a 4 byte hexadecimal number "ID2" is a 4 byte hexadecimal number Parameters: P1 = Lock Type & Mode P2 = Lock ID1 P3 = Lock ID2 Lock Type & Mode The lock type and requested mode are encoded into P1 thus: Convert P1 into hexadecimal (or use P1RAW) and extract the lock type and requested mode from this by converting the first 2 bytes of the hexadecimal number to ASCII and the second 2 bytes to a number: Eg: 54580006 ^^^^------ Converted to ASCII gives "TX" (0x54 = "T", 0x58 = "X") ^^^^-- 0006 is 6 in decimal so this is a mode 6 request Note that on UNIX, the command 'man ascii' will display the Octal, hexadecimal, and decimal ASCII character sets to help with the hex translation. An alternative way to extract this information is to use SQL thus: SELECT chr(to_char(bitand(p1,-16777216))/16777215)|| chr(to_char(bitand(p1, 16711680))/65535) "Lock", to_char( bitand(p1, 65535) ) "Mode" FROM v$session_wait WHERE event = 'enqueue' ; Lock ID1 P2 represents ID1 of the enqueue name in decimal. P2RAW represents ID1 of the enqueue name in hexadecimal. Lock ID2 P3 represents ID2 of the enqueue name in decimal. P3RAW represents ID2 of the enqueue name in hexadecimal.
Oracle Enqueues Wait Events 一
来源:这里教程网
时间:2026-03-03 16:02:30
作者:
编辑推荐:
- Oracle Enqueues Wait Events 一03-03
- Oracle OCR的备份与恢复03-03
- Oracle 添加OCR镜像盘以及镜像磁盘组03-03
- Oracle OCR/VF磁盘的替换03-03
- oracle RAC 诊断集群状态命令03-03
- Oracle单实例+ASM启动与关闭03-03
- ORA-64219: 遇到无效的 LOB 定位符03-03
- RAC日志收集方式03-03
下一篇:
相关推荐
-
雷神推出 MIX PRO II 迷你主机:基于 Ultra 200H,玻璃上盖 + ARGB 灯效
2 月 9 日消息,雷神 (THUNDEROBOT) 现已宣布推出基于英
-
制造商 Musnap 推出彩色墨水屏电纸书 Ocean C:支持手写笔、第三方安卓应用
2 月 10 日消息,制造商 Musnap 现已在海外推出一款 Oce
热文推荐
- ORA-64219: 遇到无效的 LOB 定位符
ORA-64219: 遇到无效的 LOB 定位符
26-03-03 - 记录一次XTTS迁移碰到的问题
记录一次XTTS迁移碰到的问题
26-03-03 - Oracle 11g RAC + DG安装详解--02
Oracle 11g RAC + DG安装详解--02
26-03-03 - oracle字段长度引起的思考 length()和lengthb()
oracle字段长度引起的思考 length()和lengthb()
26-03-03 - Oracle RPM包安装Oracle19c
Oracle RPM包安装Oracle19c
26-03-03 - 微信小程序直播怎么弄
微信小程序直播怎么弄
26-03-03 - 只有select权限也能锁表?read and select
只有select权限也能锁表?read and select
26-03-03 - 美创科技运维日记|Oracle字段长度引起的思考length()和lengthb()
- Oracle 修改集群的资源属性(依赖关系)
Oracle 修改集群的资源属性(依赖关系)
26-03-03 - Oracle OCR/VF磁盘组的故障恢复
Oracle OCR/VF磁盘组的故障恢复
26-03-03
