DSI的全称是DATA SERVER INTERNALS

DSI含以下课程:

DSI301:ADVANCED SERVER SUPPORT SKILLS
DSI302:DATA MANAGEMENT
DSI303:DATABASE BACKUP AND RECOVERY
DSI304:QUERY MANAGEMENT
DSI305:DATABASE TUNING
DSI306:VERY LARGE DATABASES
DSI307:DISTRIBUTION AND REPLICATION
DSI308:PARALLEL SERVER
 
DSI401E:ADVANCE SUPPORT SKILLS
DSI401:DUMPS CRASHES AND CORRUPTIONS
DSI402E:DATA TYPE AND BLOCK STRUCTURES
DSI402:SPACE AND TRANSACTION MANAGEMENT
DSI403E:RECOVERY ARCHITECTURE COMPONTS
DSI404E:QUERY OPTIMIZER
DSI405:INSTANCE TUNING
DSI408:REAL APPLICATION CLUSTERS INTERNALS

DSI3X 为8i

DSI4X 为9i



301笔记:

设置event的方法:
1.通过初始化参数event="
< event   name >   < action >  [: < event   name >   < action >  ]"
2.alter session set events '
< event   name >   < action >  [: < event   name >   < action >  ]'
3.alter system set  events '
< event   name >   < action >  [: < event   name >   < action >  ]'
4.exec dbms_system.SET_EV(sid,serial#,event name,level,'action');
5.oradebug 
< command > ;
 
注:event="
< event   name >   < action >  [: < event   name >   < action >  ]"的说明如下:
一.event name:
(1)可以是一个event的名称,如果不是event的名称,就默认为immediate。(但是immediate关键字不能出现在初始化文件中)
(2)可以是event的数字,如10046,10053,范围是10000至10999。每个event号码的含义后续会介绍。
 
二.当设定了event name后,action有可能有3种取值:crash、debugger、trace,其中trace我们比较常用。这里具体说说trace的这种用法:
指定trace时,语法为:
< event   name >  "trace" "name"  < trace   name >   < trace   qualifier > [, < trace   qualifier > ]...
这里
< trace   name > 是一个内部的trace 标记,如context。
这里
< trace   qualifier > 可以是forever、off、level n,一般情况下n是trace的级别,n越高级别越高;但是如果是dump数据块的时候,n指dba(data block address,数据块的地址)。
 
综上,可以写event="10046 trace name context forever:10053 trace name context forever,level 10"
注意,当初始化文件中有2个event="xxxxx",以后面一个为准,前面一个失效。

event的种类:

1.immediate dump:
alter session set events 'immediate trace name 
< dump >  level  < n > '
这里的
< dump > 可以是controlf、redohdr、file_hdrs、systemstate、processstate
如:alter session set events 'immediate trace name controlf level 10';
同理的:oradebug dump controlf 10;
同理的:exec dbms_system.set_ev(7,10,65535,10,'controlf');
上面的65535指immediate。因此:alter session set events '65535 trace name controlf level 10';也是可以的。
 
2.on-error dump:
event="
< errornum >  trace name errorstack level  < n > "
alter session set events '
< errornum >  trace name errorstack level  < n > ';
oradebug event 
< errornum >  trace name errorstack level  < n > ;
注意ora-3113的errornum不适用,ora-3113是"end-of-file on communication channel"
 
on-error dump的level 级别有3个:
1.error stack and function call stack(if implemented)
2. as 1 plus process states
3. as 2 plus context area(all cursor and current cursor highlighted)
 
3.change behavior:
通常用在初始化文件中。
event="
< event >  trace name context forever,level < n > "
 
4.trace events:
event="
< event >  trace name context forever,level  < n > "
alter session set events '
< event >  trace name context forever,level  < n > ';
alter system set events '
< event >  trace name context forever,level  < n > ';
 
trace eventd level 有4个级别:
1.enable standard sql_trace functionality(默认)
4.as 1 plus trace bind values
8.as level 1 plus wait
12.as level 1 plus both bind values and wait
 
hang和loop的区别:
1、hang:
等待的东西never happen.
cpu使用比较低。
用v$session_wait/v$lock/v$latch/v$latchholder来诊断。
 
2、loop:
等待的东西not going to happen。
cpu使用常常100%,且有大量active事务。
也用v$session_wait/v$lock/v$latch/v$latchholder来诊断。
对于hang问题,用v$session_wait来诊断

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/30204651/viewspace-1791830/,如需转载,请注明出处,否则将追究法律责任。

转载于:http://blog.itpub.net/30204651/viewspace-1791830/

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
Improve your ability to develop, manage, and troubleshoot SQL Server solutions by learning how different components work “under the hood,” and how they communicate with each other. The detailed knowledge helps in implementing and maintaining high-throughput databases critical to your business and its customers. You’ll learn how to identify the root cause of each problem and understand how different design and implementation decisions affect performance of your systems. New in this second edition is coverage of SQL Server 2016 Internals, including In-Memory OLTP, columnstore enhancements, Operational Analytics support, Query Store, JSON, temporal tables, stretch databases, security features, and other improvements in the new SQL Server version. The knowledge also can be applied to Microsoft Azure SQL Databases that share the same code with SQL Server 2016. Pro SQL Server Internals is a book for developers and database administrators, and it covers multiple SQL Server versions starting with SQL Server 2005 and going all the way up to the recently released SQL Server 2016. The book provides a solid road map for understanding the depth and power of the SQL Server database server and teaches how to get the most from the platform and keep your databases running at the level needed to support your business. The book: • Provides detailed knowledge of new SQL Server 2016 features and enhancements • Includes revamped coverage of columnstore indexes and In-Memory OLTP • Covers indexing and transaction strategies • Shows how various database objects and technologies are implemented internally, and when they should or should not be used • Demonstrates how SQL Server executes queries and works with data and transaction log What You Will Learn Design and develop database solutions with SQL Server. Troubleshoot design, concurrency, and performance issues. Choose the right database objects and technologies for the job. Reduce costs and improve availability and manageability. Des

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值