通过案例学调优之--RECORDS_PER_BLOCK参数

通过案例学调优之--RECORDS_PER_BLOCK参数

     RECORDS_PER_BLOCK参数用于设定每个BLOCK中记录数的最大值,其先找到当前表所有BLOCK中容纳的最大行数,并会把这个数字记录到数据字典,以后任何导致BLOCK行数超过这个数字的插入都会被拒绝。

RECORDS_PER_BLOCK参数是为位图索引而生的,能够改善位图索引的存储,减小位图索引的长度。这样,利用该位图索引的时候,就能获得比较好的效率了。

    测试案例:

1、表默认的存储分析

15:45:46 [email protected] prod >create table t3 (x int,y int);
Table created.

15:46:03 [email protected] prod >insert into t3 values (1,1);
1 row created.

15:46:12 [email protected] prod >insert into t3 values (2,1);
1 row created.

15:46:27 [email protected] prod >commit;
Commit complete.

15:48:01 [email protected] prod >insert into t3 select rownum+2,1 from all_objects where rownum <=254;
254 rows created.

15:48:37 [email protected] prod >create index t3_indx on t3(x);
Index created.

15:48:57 [email protected] prod >exec dbms_stats.gather_table_stats(user,‘T3‘,cascade=>true);
PL/SQL procedure successfully completed.

15:49:54 [email protected] prod >select count(distinct dbms_rowid.rowid_block_number(rowid)) from t3;
COUNT(DISTINCTDBMS_ROWID.ROWID_BLOCK_NUMBER(ROWID))
---------------------------------------------------
                                                  1

15:53:09 [email protected] prod >col segment_name for a20
15:53:21 [email protected] prod >select segment_name,EXTENTS,BLOCKS,BYTES from user_segments where segment_name=‘T3‘;
SEGMENT_NAME            EXTENTS     BLOCKS      BYTES
-------------------- ---------- ---------- ----------
T3                            1          8      65536

默认值,T3表中的数据存储在一个数据块上。

2、通过RECORDS_PER_BLOCK参数分散数据块的存储

15:57:47 [email protected] prod >drop table t3 purge;
Table dropped.
15:59:59 [email protected] prod >create table t3 (x int,y int);
Table created.

16:00:08 [email protected] prod >insert into t3 values (1,1);
1 row created.

16:00:16 [email protected] prod >insert into t3 values (2,1);
1 row created.

16:00:25 [email protected] prod >commit;
Commit complete.

16:00:37 [email protected] prod >alter table t3 minimize records_per_block;
Table altered.

16:00:54 [email protected] prod >insert into t3 select rownum+2,1 from all_objects where rownum <=254;
254 rows created.

16:01:09 [email protected] prod >commit;
Commit complete.

17:15:14 [email protected] prod >create index t3_indx on t3(x);

Index created.

16:01:12 [email protected] prod >exec dbms_stats.gather_table_stats(user,‘T3‘);
PL/SQL procedure successfully completed.

16:01:58 [email protected] prod >select count(distinct dbms_rowid.rowid_block_number(rowid)) from t3;
COUNT(DISTINCTDBMS_ROWID.ROWID_BLOCK_NUMBER(ROWID))
---------------------------------------------------
                                                128

16:21:29 [email protected] prod >select dbms_rowid.rowid_block_number(rowid),count(0)   from t3
   group by dbms_rowid.rowid_block_number(rowid);

DBMS_ROWID.ROWID_BLOCK_NUMBER(ROWID)   COUNT(0)
------------------------------------ ----------
                                 198          2
                                 138          2
                                 151          2
                                 153          2
                                 167          2
                                 244          2
                                 245          2
                                 247          2
                                 537          2
                                 544          2
                                 134          2
                                 194          2
                                 207          2
                                 147          2
                                 209          2
                                 213          2
                                 155          2
......
                              

128 rows selected.

可以看出,T3表占用了128个数据块!

测试发现:执行alter table test minimize records_per_block;之后,目前BLOCK中的记录数(的最大值)会应用到以后的新增数据中,也就是,当以后再往表中INSERT数据时,每个BLOCK中可以包含的记录数将与设定records_per_block之前的最大值保持一致。

需要注意的是:

  • 不能对空表设定此参数。
  • 每个BLOCK中可以包含的记录数的最低下限是2。
  • 不能在已经有 bitmap 的表中使用records_per_block参数,也就是说,如果要使用records_per_block参数,必须先alter table xxx minimize records_per_block,然后才能在表上建立索引。

如果字段的类型、大小、个数发生了改变,那么就会导致一个比较差的结果,这就说明了,这项功能只在于使用在静态的环境中,比如数据仓库。

主要用途:

  • 通过减少同一个block中的记录数,使记录分布于更多的数据块中,可以优化等待块类型为data block的Buffer Busy Wait事件。
  • 其主要用途是提高BITMAP INDEX的存储性能

3、对table访问分析

15:44:39 [email protected] prod >alter system flush buffer_cache;
System altered.

16:07:01 [email protected] prod >show parameter mult
NAME                                 TYPE                             VALUE
------------------------------------ -------------------------------- ------------------------------
db_file_multiblock_read_count        integer                          28
parallel_adaptive_multi_user         boolean                          TRUE

17:32:42 [email protected] prod >col object_name for a20
17:32:49 [email protected] prod >select object_name,object_id from user_objects where object_name=‘T3‘;

OBJECT_NAME           OBJECT_ID
-------------------- ----------
T3                        76505

16:22:19 [email protected] prod >alter session set db_file_multiblock_read_count=64;

Session altered.
将数据块以间隔的方式读入内存
16:09:03 [email protected] prod >declare
16:09:20   2  num number;
16:09:25   3  begin
16:09:29   4  for i in 1..64
16:09:34   5  loop
16:09:37   6  select y into num from t3 where x=i*4;
16:09:42   7  end loop;
16:09:48   8  end;
16:09:50   9  /
PL/SQL procedure successfully completed.

17:25:29 [email protected] prod >select file#,block#,status,objd from v$bh where file#=4;

     FILE#     BLOCK# STATUS           OBJD
---------- ---------- ---------- ----------
         4        521 free            76505
         4        521 free            76505
         4        521 free            76505
         4        165 free            76505
         4        165 free            76505
         4        165 free            76505
         4        542 free            76505
         4        542 free            76505
         4        542 free            76505
         4        131 free            76505
         4        131 free            76505
         4        131 free            76505
         4        131 xcur            76505
         4        529 free            76505
         4        529 free            76505
         4        529 free            76505
         4        529 xcur            76505

     FILE#     BLOCK# STATUS           OBJD
---------- ---------- ---------- ----------
         4        550 free            76505
         4        550 free            76505
         4        550 free            76505
         4        139 free            76505
         4        139 free            76505
         4        139 free            76505
         4        139 xcur            76505
         4        537 free            76505
         4        537 free            76505
         4        537 free            76505
         4          3 free       4294967295
         4          3 free       4294967295
         4        147 free            76505
         4        147 free            76505
         4        147 free            76505
         4        524 free            76505
         4        524 free            76505

     FILE#     BLOCK# STATUS           OBJD
---------- ---------- ---------- ----------
         4        524 free            76505
         4        545 free            76505
         4        545 free            76505
         4        545 free            76505
         4        545 xcur            76505
         4        134 free            76505
         4        134 free            76505
         4        134 free            76505
         4        134 xcur            76505
         4        155 free            76505
         4        155 free            76505
         4        155 free            76505
         4        155 xcur            76505
         4        532 free            76505
         4        532 free            76505
         4        532 free            76505
         4        532 xcur            76505

     FILE#     BLOCK# STATUS           OBJD
---------- ---------- ---------- ----------
         4        553 free            76506
         4        142 free            76505
         4        142 free            76505
         4        142 free            76505
         4        163 free            76505
         4        163 free            76505
         4        163 free            76505
         4        540 free            76505
         4        540 free            76505
         4        540 free            76505
         4        129 free            76505
         4        129 free            76505
         4        129 free            76505
         4        150 free            76505
         4        150 free            76505
         4        150 free            76505
         4        150 xcur            76505

     FILE#     BLOCK# STATUS           OBJD
---------- ---------- ---------- ----------
         4        527 free            76505
         4        527 free            76505
         4        527 free            76505
         4        527 xcur            76505
         4        548 free            76505
         4        548 free            76505
         4        548 free            76505
         4        137 free            76505
         4        137 free            76505
         4        158 free            76505
         4        158 free            76505
         4        535 free            76505
         4        535 free            76505
         4        145 free            76505
         4        145 free            76505
         4        145 xcur            76505
         4        522 free            76505

     FILE#     BLOCK# STATUS           OBJD
---------- ---------- ---------- ----------
         4        522 free            76505
         4        522 xcur            76505
         4        166 free            76505
         4        166 free            76505
         4        166 xcur            76505
         4        543 free            76505
         4        543 free            76505
         4        543 xcur            76505
         4        132 free            76505
         4        132 free            76505
         4        153 free            76505
         4        153 free            76505
         4        530 free            76505
         4        530 free            76505
         4        551 free            76505
         4        551 free            76505
         4        551 xcur            76505

     FILE#     BLOCK# STATUS           OBJD
---------- ---------- ---------- ----------
         4        140 free            76505
         4        140 free            76505
         4        161 free            76505
         4        161 free            76505
         4        161 xcur            76505
         4        538 free            76505
         4        538 free            76505
         4        538 xcur            76505
         4        148 free            76505
         4        148 free            76505
         4        148 xcur            76505
         4        525 free            76505
         4        525 free            76505
         4        525 xcur            76505
         4        546 free            76505
         4        546 free            76505
         4        135 free            76505

     FILE#     BLOCK# STATUS           OBJD
---------- ---------- ---------- ----------
         4        135 free            76505
         4        156 free            76505
         4        156 free            76505
         4        533 free            76505
         4        533 free            76505
         4        554 free            76506
         4        143 free            76505
         4        143 free            76505
         4        143 xcur            76505
         4        164 free            76505
         4        164 free            76505
         4        164 xcur            76505
         4        541 free            76505
         4        541 free            76505
         4        541 xcur            76505
         4        130 free            76505
         4        130 free            76505

     FILE#     BLOCK# STATUS           OBJD
---------- ---------- ---------- ----------
         4        151 free            76505
         4        151 free            76505
         4        549 free            76505
         4        549 free            76505
         4        549 xcur            76505
         4        138 free            76505
         4        138 free            76505
         4        138 xcur            76505
         4        159 free            76505
         4        159 free            76505
         4        159 xcur            76505
         4          2 free       4294967295
         4        146 free            76505
         4        146 free            76505
         4        523 free            76505
         4        523 free            76505
         4        523 xcur            76505

     FILE#     BLOCK# STATUS           OBJD
---------- ---------- ---------- ----------
         4        167 free            76505
         4        167 free            76505
         4        544 free            76505
         4        544 free            76505
         4        133 free            76505
         4        133 free            76505
         4        154 free            76505
         4        154 free            76505
         4        154 xcur            76505
         4        531 free            76505
         4        531 free            76505
         4        552 free            76506
         4        141 free            76505
         4        141 free            76505
         4        141 xcur            76505
         4        162 free            76505
         4        162 free            76505

     FILE#     BLOCK# STATUS           OBJD
---------- ---------- ---------- ----------
         4        539 free            76505
         4        539 free            76505
         4        539 xcur            76505
         4        149 free            76505
         4        149 free            76505
         4        526 free            76505
         4        526 free            76505
         4        547 free            76505
         4        547 free            76505
         4        547 xcur            76505
         4        157 free            76505
         4        157 free            76505
         4        157 xcur            76505
         4        534 free            76505
         4        534 free            76505
         4        534 xcur            76505
         4        555 free            76506

     FILE#     BLOCK# STATUS           OBJD
---------- ---------- ---------- ----------
         4        555 xcur            76506
188 rows selected.
16:14:20 [email protected] prod >grant alter session to scott;
Grant succeeded.

16:14:39 [email protected] prod >conn scott/tiger
Connected.
16:14:42 [email protected] prod >alter session set events ‘10046 trace name context forever,level 12‘;
Session altered.

16:15:31 [email protected] prod >set autotrace trace
16:15:37 [email protected] prod >select * from t3 ;
256 rows selected.
Elapsed: 00:00:00.02
Execution Plan
----------------------------------------------------------
Plan hash value: 4161002650
--------------------------------------------------------------------------
| Id  | Operation         | Name | Rows  | Bytes | Cost (%CPU)| Time     |
--------------------------------------------------------------------------
|   0 | SELECT STATEMENT  |      |   256 |  1792 |    68   (0)| 00:00:01 |
|   1 |  TABLE ACCESS FULL| T3   |   256 |  1792 |    68   (0)| 00:00:01 |
--------------------------------------------------------------------------
Statistics
----------------------------------------------------------
          1  recursive calls
          0  db block gets
        196  consistent gets
          0  physical reads
          0  redo size
       4829  bytes sent via SQL*Net to client
        606  bytes received via SQL*Net from client
         19  SQL*Net roundtrips to/from client
          0  sorts (memory)
          0  sorts (disk)
        256  rows processed
        
[[email protected] ~]$ ls -lt /u01/app/oracle/diag/rdbms/prod/prod/trace/|more
total 12056
-rw-r----- 1 oracle oinstall  51244 Nov 19 17:28 prod_ora_3681.trc
-rw-r----- 1 oracle oinstall    199 Nov 19 17:28 prod_ora_3681.trm
-rw-r--r-- 1 oracle oinstall 430401 Nov 19 17:22 alert_prod.log
-rw-r----- 1 oracle oinstall   8230 Nov 19 17:18 prod_ora_3629.trc

[[email protected] ~]$ grep sequen /u01/app/oracle/diag/rdbms/prod/prod/trace/prod_ora_3681.trc
WAIT #10: nam=‘db file sequential read‘ ela= 13 file#=4 block#=130 blocks=1 obj#=76505 tim=1416389324098217
WAIT #10: nam=‘db file sequential read‘ ela= 7 file#=4 block#=135 blocks=1 obj#=76505 tim=1416389324098716
WAIT #10: nam=‘db file sequential read‘ ela= 7 file#=6 block#=193 blocks=1 obj#=76505 tim=1416389324098758
WAIT #10: nam=‘db file sequential read‘ ela= 0 file#=6 block#=195 blocks=1 obj#=76505 tim=1416389324098837
WAIT #10: nam=‘db file sequential read‘ ela= 0 file#=6 block#=197 blocks=1 obj#=76505 tim=1416389324098837
WAIT #10: nam=‘db file sequential read‘ ela= 8 file#=6 block#=199 blocks=1 obj#=76505 tim=1416389324098874
WAIT #10: nam=‘db file sequential read‘ ela= 9 file#=4 block#=137 blocks=1 obj#=76505 tim=1416389324098917
WAIT #10: nam=‘db file sequential read‘ ela= 8 file#=4 block#=140 blocks=1 obj#=76505 tim=1416389324099100
WAIT #10: nam=‘db file sequential read‘ ela= 8 file#=4 block#=142 blocks=1 obj#=76505 tim=1416389324099144
WAIT #10: nam=‘db file sequential read‘ ela= 8 file#=6 block#=200 blocks=1 obj#=76505 tim=1416389324099188
WAIT #10: nam=‘db file sequential read‘ ela= 8 file#=6 block#=202 blocks=1 obj#=76505 tim=1416389324099230
WAIT #10: nam=‘db file sequential read‘ ela= 8 file#=6 block#=204 blocks=1 obj#=76505 tim=1416389324099395
WAIT #10: nam=‘db file sequential read‘ ela= 7 file#=6 block#=206 blocks=1 obj#=76505 tim=1416389324099439
WAIT #10: nam=‘db file sequential read‘ ela= 223 file#=4 block#=149 blocks=1 obj#=76505 tim=1416389324100699
WAIT #10: nam=‘db file sequential read‘ ela= 13 file#=4 block#=151 blocks=1 obj#=76505 tim=1416389324100962
WAIT #10: nam=‘db file sequential read‘ ela= 9 file#=6 block#=209 blocks=1 obj#=76505 tim=1416389324101019
WAIT #10: nam=‘db file sequential read‘ ela= 9 file#=6 block#=211 blocks=1 obj#=76505 tim=1416389324101319
WAIT #10: nam=‘db file sequential read‘ ela= 7 file#=6 block#=213 blocks=1 obj#=76505 tim=1416389324101384
WAIT #10: nam=‘db file sequential read‘ ela= 8 file#=6 block#=215 blocks=1 obj#=76505 tim=1416389324101418
WAIT #10: nam=‘db file sequential read‘ ela= 8 file#=4 block#=153 blocks=1 obj#=76505 tim=1416389324101459
WAIT #10: nam=‘db file sequential read‘ ela= 10 file#=4 block#=156 blocks=1 obj#=76505 tim=1416389324101664
WAIT #10: nam=‘db file sequential read‘ ela= 9 file#=4 block#=158 blocks=1 obj#=76505 tim=1416389324101716
WAIT #10: nam=‘db file sequential read‘ ela= 8 file#=6 block#=216 blocks=1 obj#=76505 tim=1416389324101770
WAIT #10: nam=‘db file sequential read‘ ela= 8 file#=6 block#=218 blocks=1 obj#=76505 tim=1416389324101813
WAIT #10: nam=‘db file sequential read‘ ela= 9 file#=6 block#=220 blocks=1 obj#=76505 tim=1416389324101992
WAIT #10: nam=‘db file sequential read‘ ela= 8 file#=6 block#=222 blocks=1 obj#=76505 tim=1416389324102036
WAIT #10: nam=‘db file sequential read‘ ela= 9 file#=4 block#=165 blocks=1 obj#=76505 tim=1416389324102276
WAIT #10: nam=‘db file sequential read‘ ela= 7 file#=4 block#=167 blocks=1 obj#=76505 tim=1416389324102309
WAIT #10: nam=‘db file sequential read‘ ela= 9 file#=6 block#=233 blocks=1 obj#=76505 tim=1416389324102355
WAIT #10: nam=‘db file sequential read‘ ela= 32 file#=6 block#=235 blocks=1 obj#=76505 tim=1416389324102705
WAIT #10: nam=‘db file sequential read‘ ela= 9 file#=6 block#=237 blocks=1 obj#=76505 tim=1416389324102931
WAIT #10: nam=‘db file sequential read‘ ela= 27 file#=6 block#=239 blocks=1 obj#=76505 tim=1416389324103182
WAIT #10: nam=‘db file sequential read‘ ela= 10 file#=6 block#=256 blocks=1 obj#=76505 tim=1416389324103344
WAIT #10: nam=‘db file sequential read‘ ela= 8 file#=4 block#=129 blocks=1 obj#=76505 tim=1416389324103389
WAIT #10: nam=‘db file sequential read‘ ela= 8 file#=6 block#=257 blocks=1 obj#=76505 tim=1416389324103423
WAIT #10: nam=‘db file sequential read‘ ela= 8 file#=4 block#=521 blocks=1 obj#=76505 tim=1416389324103466
WAIT #10: nam=‘db file sequential read‘ ela= 8 file#=4 block#=524 blocks=1 obj#=76505 tim=1416389324103678
WAIT #10: nam=‘db file sequential read‘ ela= 7 file#=4 block#=526 blocks=1 obj#=76505 tim=1416389324103722
WAIT #10: nam=‘db file sequential read‘ ela= 8 file#=6 block#=240 blocks=1 obj#=76505 tim=1416389324103766
WAIT #10: nam=‘db file sequential read‘ ela= 8 file#=6 block#=242 blocks=1 obj#=76505 tim=1416389324103808
WAIT #10: nam=‘db file sequential read‘ ela= 9 file#=6 block#=244 blocks=1 obj#=76505 tim=1416389324103872
WAIT #10: nam=‘db file sequential read‘ ela= 8 file#=6 block#=246 blocks=1 obj#=76505 tim=1416389324103918
WAIT #10: nam=‘db file sequential read‘ ela= 8 file#=4 block#=533 blocks=1 obj#=76505 tim=1416389324104170
WAIT #10: nam=‘db file sequential read‘ ela= 7 file#=4 block#=535 blocks=1 obj#=76505 tim=1416389324104206
WAIT #10: nam=‘db file sequential read‘ ela= 8 file#=6 block#=249 blocks=1 obj#=76505 tim=1416389324104250
WAIT #10: nam=‘db file sequential read‘ ela= 9 file#=6 block#=251 blocks=1 obj#=76505 tim=1416389324104449
WAIT #10: nam=‘db file sequential read‘ ela= 8 file#=6 block#=253 blocks=1 obj#=76505 tim=1416389324104512
WAIT #10: nam=‘db file sequential read‘ ela= 8 file#=6 block#=255 blocks=1 obj#=76505 tim=1416389324104544
WAIT #10: nam=‘db file sequential read‘ ela= 8 file#=4 block#=537 blocks=1 obj#=76505 tim=1416389324104584
WAIT #10: nam=‘db file sequential read‘ ela= 9 file#=4 block#=540 blocks=1 obj#=76505 tim=1416389324104759
WAIT #10: nam=‘db file sequential read‘ ela= 7 file#=4 block#=542 blocks=1 obj#=76505 tim=1416389324104802
WAIT #10: nam=‘db file sequential read‘ ela= 8 file#=4 block#=544 blocks=1 obj#=76505 tim=1416389324104845
WAIT #10: nam=‘db file sequential read‘ ela= 76 file#=4 block#=546 blocks=1 obj#=76505 tim=1416389324105604
WAIT #10: nam=‘db file sequential read‘ ela= 7 file#=4 block#=548 blocks=1 obj#=76505 tim=1416389324105805
WAIT #10: nam=‘db file sequential read‘ ela= 6 file#=4 block#=550 blocks=1 obj#=76505 tim=1416389324105834
......

     以上向我们展示了Oracle多个数据块读取的工作机制,当内存中已经有了某个数据块时,Oracle将不再从磁盘中读取它。这里使用一个循环来通过索引块访问的方式(每次读取一个数据块),将间隔的数据块读入到内存中。这样,当我们对T3表执行全表扫描时,尽管设置了参数:

16:22:19 [email protected] prod >alter session set db_file_multiblock_read_count=64;

但是由于没有连续的数据块可以读取了,所以Oracle每次也只能将一个数据块读取到内存。在等待事件中每一个WAIT#中 blocks=1说明每次I/O读取的数据块都为1,而且数据块的序号正好间隔为1,说明她们之间的那个数据块已经读取到内存中了。因为需要读取的数据块不再连续,所以此时不能一次读取多个数据块。

    多数据块读取一般发生在:

FTS(FULL TABLE SCAN)

      INDEX_FFS(INDEX FAST FULL SCAN)


时间: 2024-08-05 19:32:46

通过案例学调优之--RECORDS_PER_BLOCK参数的相关文章

通过案例学调优之--Oracle参数(db_file_multiblock_read_count)

通过案例学调优之--Oracle参数(db_file_multiblock_read_count) 应用环境: 操作系统: RedHat EL55 Oracle:   Oracle 10gR2   Oracle DB_FILE_MULTIBLOCK_READ_COUNT是Oracle比较重要的一个全局性参数,可以影响系统级别及sessioin级别.主要是用于设置最小化表扫描时Oracle一次按顺序能够读取的数据块数.通常情况下,我们看到top events中的等待事件db file scatte

通过案例学调优之--AWR BaseLine管理

通过案例学调优之--AWR BaseLine管理 BaseLine Baseline 是指一个特定时间段内的性能数据,保留这些数据是为了在性能问题产生时与其他类似的工作负载时间段进行比较.Baseline 中包含的快照将从自动 AWR 清理进程中排除,并无限期的保留. 在 Oracle Database 中存在多种类型的 baseline:      Fixed Baseline:fixed baseline 表示的是您指定的一个固定的.连续的时间段.在创建 fixed baseline 之前,

通过案例学调优之--SQL Profile

通过案例学调优之--SQL Profile 一.什么是SQL Profile(概要) SQL Profile在性能优化中占有一个重要的位置. MOS里这么描述SQL Profile: SQL Profile是10g中的新特性,作为自动SQL调整过程的一部分,由Oracle企业管理器来管理.除了OEM,SQL Profile可以通过DBMS_SQLTUNE包来进行管理. 查询优化器有时候会因为缺乏足够的信息,而对一条SQL语句做出错误的估计,生成糟糕的执行计划.而自动SQL调整通过SQL概要分析来

通过案例学调优之--AWR基本概念

通过案例学调优之--AWR基本概念 一.Automatic Workload Repository 概念详解 Automatic Workload Repository (AWR) 收集.处理和维护用于问题诊断的性能统计信息.该数据既存在于数据块中,也存在于内存中.AWR 收集的数据可以通过报告和视图进行查看. AWR 处理和收集的统计信息包括: 1.确定数据块 segment 访问路径和使用情况的对象统计信息 2.基于数据库活动的时间使用情况的时间模型统计信息,可在 V$SYS_TIME_MO

通过案例学调优之--Oracle Cluster Table

通过案例学调优之--Oracle Cluster Table About Clusters A cluster provides an optional method of storing table data. A cluster is made up of a group of tables that share the same data blocks. The tables are grouped together because they share common columns an

通过案例学调优之--和 LOG BUFFER 相关的主要 Latch

通过案例学调优之--和 LOG BUFFER 相关的主要 Latch  4.1.和 LOG BUFFER 相关的主要 Latch  有:  Latch:Redo Copy      Latch:Redo Allocation Latch 4.2 当一个进程在修改数据时候将会产生 Redo,这个 Redo 首先在 PGA 中保存. 然后进程需要 获取Redo Copy Latch(这个Latch的个数由隐含参数_log_simultaneous_copies决定),当获 得 Redo Copy L

通过案例学调优之--Oracle 全文索引

通过案例学调优之--Oracle 全文索引 全文检索(oracle text)  Oracle Text使Oracle9i具备了强大的文本检索能力和智能化的文本管理能力,Oracle Text 是 Oracle9i 采用的新名称,在 oracle8/8i 中被称为 oracle intermedia text,oracle8 以前是 oracle context cartridge.Oracle Text 的索引和查找功能并不局限于存储在数据库中的数据. 它可以对存储于文件系统中的文档进行检索和

通过案例学调优之--AWR baseline对比生成AWR报告

通过案例学调优之--AWR Baseline对比生成AWR报告 一.建立Baseline 查看snapshot: 16:46:08 [email protected] prod >select SNAP_ID,BEGIN_INTERVAL_TIME from dba_hist_snapshot;    SNAP_ID BEGIN_INTERVAL_TIME ---------- -----------------------------------------------------------

通过案例学调优之--模拟buffer busy waits事件

通过案例学调优之--模拟buffer busy waits事件 buffer busy waits等待事件     Wait occurs when a session attempts to access a block in memory, is denied and must wait until the buffer becomes available. This event happens because a buffer is either being read into the b