易截截图软件、单文件、免安装、纯绿色、仅160KB

关于oracle mutex和latch的问题

关于latch和mutex的问题
from:http://www.itpub.net/thread-1004815-1-1.html
A:
latch是闩锁,是一种串行化机制,用来保护SGA中的内存结构。
mutex是什么,也是一种串行化机制,是互斥锁?
个人对mutex没有什么概念。这个是10G新引进的?9I好像没有啊。
哪位明白人,给帮忙详细解释下mutex,最好还能和latch 做下比较。
谢谢。
B:
BTW, things get more fun in 10.2, you can pin cursors without getting library cache pin latch, using KGX mutexes. Mutexes are new in 10.2 and they enable shared access to objects in somewhat similar manner to shared latche; every successful get of a particular mutex will increment its value and a release will decrement. When the count is zero, no one has the mutex and it is safe to get it in exclusive mode. However, they are more fine-grained than kgl latches and provide a better wait mechanism, as far as I understand.
So if your environment supports atomic compare and swap operation (such as CMPXCHG on Intel), you might get away without cursor_space_for_time setting for ultrahigh execution rates. Otherwise the atomic mutex operations would be achieved using the new KGX latches.
At least on my laptop this feature isn't enabled by default (from an OracleWorld paper I remember that it should become default in 10.2.0.2), but so far you can experiment with it if you set _kks_use_mutex_pin = true and bounce the instance (mutex structures will be stored in the shared pool, so you might need to increase shared pool size).
There are also X$MUTEX_SLEEP and X$MUTEX_SLEEP_HISTORY fixed tables that can show some interesting information if you generate some mutex waits into them.
Now, I don't suggest for a moment that you have to understand this response. It is at an extremely deep technical level, and the practical applications of such understanding are probably few and far between. My point, though, is that you must take the time to study and understand Oracle internal operations if you are to have success in Oracle performance optimization. There are no shortc


相关文档:

oracle 表空间操作

oracle表空间操作详解
  1
  2
  3作者:   来源:    更新日期:2006-01-04 
  5
  6 
  7建立表空间
  8
  9CREATE TABLESPACE data01
 10DATAFILE '/ora ......

oracle 9i on linux AS4

 先root打补丁:p3006854_9204_linux.zip
再设oracle环境变量
安装
安装结束建库之前需要打的补丁有:
p2617419_220_GENERIC.zip
p3119415_9204_linux.zip
具体参考这篇文章:
Redhat Enterprise Linux 4安装oracle
关键字: redhat el4 oracle 安装
一. 安装准备
  1. as4安装完后,需要检查下列软件 ......

SQL Server和Oracle的常用函数比较

---------数学函数 ---------------
  1.绝对值
  S:select abs(-1) value
  O:select abs(-1) value from dual
  2.取整(大)
  S:select ceiling(-1.001) value
  O:select ceil(-1.001) value from dual
  3.取整(小)
  S:select floor(-1.001) value
  O:select floor(-1.001) value from ......

Oracle TRANSLATE用法

语法:TRANSLATE(expr,from,to)
expr: 代表一串字符,from 与 to 是从左到右一一对应的关系,如果不能对应,则视为空值。
举例:
select translate('abcbbaadef','ba','#@') from dual (b将被#替代,a将被@替代)
select translate('abcbbaadef','bad','#@') from dual (b将被#替代,a将被@替代,d对应的值是空 ......

Oracle Package中存储过程返回游标

一、Oracle Package的作用
1、定义与说明
  a. 相关对象(自定义类型、函数、存储过程等)的封装
  b. 程序包的各部分
    - 程序包规格说明
          声明子程序
   - 程序包主体
      &n ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号