ITPub博客

首页 > Linux操作系统 > Linux操作系统 > dml操作重做日志分析

dml操作重做日志分析

原创 Linux操作系统 作者:redhouser 时间:2011-06-22 10:52:24 0 删除 编辑

目的:
为了观察dml操作对应重做日志内容以及数据块scn变更,通过dump logfile获取重做日志内容,结合数据块进行分析。

1,测试表:
version:
Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
System name: Linux
Node name: rhel5
Release: 2.6.18-8.el5xen

drop table test_with_pk;
create table test_with_pk(x int,y int,z int);
alter table test_with_pk add constraint pk_test_with_pk primary key(x);
insert into test_with_pk values(3,4,5);
insert into test_with_pk values(4,5,6);
commit;

2,操作过程:
2.1 获取scn方式:
select current_scn,'0x0000.'||ltrim(to_char(current_scn,'xxxxxxxxxxxx')) hexscn from v$database;
302586420,0x0000.12091a34

2.2 inserts
insert into test_with_pk values(7,8,9);
insert into test_with_pk values(8,9,10);
insert into test_with_pk values(9,10,11);
insert into test_with_pk values(10,11,12);

2.3 获取scn方式:
302586436--0x0000.12091a44

2.4 deletes
delete from test_with_pk where x=3;
delete from test_with_pk where x=4;
delete from test_with_pk where x=7;
delete from test_with_pk where x=8;

2.5 获取scn方式:
302586446--0x0000.12091a4e

2.6
commit;

2.7 获取scn方式:
302586468--0x0000.12091a64

2.8 dump logfile:
--确定当前logfile
SELECT lf.MEMBER
  FROM v$log lg, v$logfile lf
 WHERE lg.group# = lf.group#
   AND lg.status = 'CURRENT';
--dump logfile
alter system dump logfile '/oracle/oradata/ora10ctg/redo01.log'
scn min 302586420 scn max 302586468;

2.9对应数据块scn
SELECT dbms_rowid.rowid_relative_fno(ROWID),
       dbms_rowid.rowid_block_number(ROWID)
  FROM test_with_pk
 WHERE x = 10;

alter system dump datafile 4 block 407;
dump记录见附件2。

为了触发块清理(cleanout)操作,使用如下语句。
select * from  test_with_pk for update;
rollback;

alter system dump datafile 4 block 407;
dump记录见附件3。


3 重做日志、数据块分析
通过分析日志(附件1),可以观察到:
(1)一个事务由多个REDO RECORD组成:
*在事务的第一个REDO RECORD中,由OP:5.2操作分配回滚段,确定xid;
*事务的最后一个REDO RECORD中,由OP:5.4操作在回滚段头设置事务结束标志
(2)一个dml操作redo中,包含如下块的redo信息,可能由多个REDO RECORD组成(本次测试中,对数据块修改和对索引块的修改分别对应一个REDO RECORD,而且REDO RECORD上的SCN相同):
*回滚段头
*数据块:只记录后像(after image)
*数据块对应undo块,对undo块的修改按rec(以ktudb redo开头的行中)排序递增:只记录前像(before image)
*索引块
*索引块对应undo块,对undo块的修改按rec(以ktudb redo开头的行中)排序递增
*各段位图维护
(3)一个REDO RECORD由多个change vector组成,各个change SCN可能早于REDO RECORD SCN,并且各个change SCN大小关系不确定(不是按顺序增加)。
(4)通过分析数据块,可以观察到:
*数据块上的scn(Start dump data blocks...后第二行): 是最后影响该块操作的scn
*csc: 0x00.120911e5,为最后一次块清理scn
*事务槽中的fsc,为事务提交时的scn(exact commit scn)
*事务槽中scn,数据更改scn,或块清理后scn(maybe exact/bigger/smaller than commit scn)


附件1:
++++++++++++++++++++++++++++++++++++++++++++++++++++
v$database.current_scn:0x0000.12091a34
insert into test_with_pk values(7,8,9);
++++++++++++++++++++++++++++++++++++++++++++++++++++
REDO RECORD - Thread:1 RBA: 0x00011f.00001e4b.0010 LEN: 0x0234 VLD: 0x05
SCN: 0x0000.12091a37 SUBSCN:  5 11/14/2018 11:19:46
CHANGE #1 TYP:0 CLS:23 AFN:2 DBA:0x00800039 OBJ:4294967295 SCN:0x0000.12091a08 SEQ:  1 OP:5.2 
                                                                      ++++事务开始,分配回滚段,DBA:0x00800039对应回滚段头block地址
              ++++Opcode 5.2 : Update rollback segment header - KTURDH
ktudh redo: slt: 0x0025 sqn: 0x00000346 flg: 0x0012 siz: 132 fbi: 0   ++++确定slot,sqn,-->xid:  0x0004.025.00000346
            uba: 0x008000a6.02ae.0f    pxid:  0x0000.000.00000000     ++++确定uba,seq,rec
CHANGE #2 TYP:0 CLS:24 AFN:2 DBA:0x008000a6 OBJ:4294967295 SCN:0x0000.12091a07 SEQ:  3 OP:5.1 
                                                                      ++++对应uba;Opcode 5.1 : Undo block or undo segment header - KTURDB
ktudb redo: siz: 132 spc: 4074 flg: 0x0012 seq: 0x02ae rec: 0x0f      ++++事务内,rec++
            xid:  0x0004.025.00000346                                 ++++xid
ktubl redo: slt: 37 rci: 0 opc: 11.1 objn: 59751 objd: 59865 tsn: 4   ++++表id
Undo type:  Regular undo        Begin trans    Last buffer split:  No
Temp Object:  No
Tablespace Undo:  No
             0x00000000  prev ctl uba: 0x008000a6.02ae.0c   ++++前一事务uba
prev ctl max cmt scn:  0x0000.12091640  prev tx cmt scn:  0x0000.12091644
txn start scn:  0xffff.ffffffff  logon user: 70  prev brb: 8389818  prev bcl: 0 KDO undo record:
KTB Redo
op: 0x03  ver: 0x01 
op: Z
KDO Op code: DRP row dependencies Disabled                       ++++DRP:delete row piece
  xtype: XA flags: 0x00000000  bdba: 0x01000197  hdba: 0x01000193
itli: 1  ispac: 0  maxfr: 4858
tabn: 0 slot: 0(0x0)
CHANGE #3 TYP:0 CLS: 1 AFN:4 DBA:0x01000197 OBJ:59865 SCN:0x0000.120911e5 SEQ:  1 OP:11.2  
                                                                  ++++数据块,对象id;Opcode 11.2 : Insert Row Piece
KTB Redo
op: 0x01  ver: 0x01 
op: F  xid:  0x0004.025.00000346    uba: 0x008000a6.02ae.0f       ++++对应uba
                                                                  ++++op:F First change to ITL by this TX. Copy redo to ITL
KDO Op code: IRP row dependencies Disabled                        ++++IRP:insert row piece
  xtype: XA flags: 0x00000000  bdba: 0x01000197  hdba: 0x01000193
itli: 1  ispac: 0  maxfr: 4858
tabn: 0 slot: 0(0x0) size/delt: 12
fb: --H-FL-- lb: 0x1  cc: 3
null: ---
col  0: [ 2]  c1 08
col  1: [ 2]  c1 09
col  2: [ 2]  c1 0a
CHANGE #4 MEDIA RECOVERY MARKER SCN:0x0000.00000000 SEQ:  0 OP:5.19    
                                                ++++Opcode 5.19 : Transaction start audit log record
session number   = 143
serial  number   = 95
current username = MH
login   username = MH
client info      =
OS username      = mh
Machine name     = \mh
OS terminal      = mh
OS process id    = 2872:1364
OS program name  = PlSqlDev.exe
transaction name =
version 169869568
audit sessionid 1907
 
REDO RECORD - Thread:1 RBA: 0x00011f.00001e4c.009c LEN: 0x00f0 VLD: 0x01
SCN: 0x0000.12091a37 SUBSCN:  7 11/14/2018 11:19:46
CHANGE #1 TYP:0 CLS:24 AFN:2 DBA:0x008000a6 OBJ:4294967295 SCN:0x0000.12091a37 SEQ:  1 OP:5.1
ktudb redo: siz: 92 spc: 3940 flg: 0x0022 seq: 0x02ae rec: 0x10
            xid:  0x0004.025.00000346 
ktubu redo: slt: 37 rci: 15 opc: 10.22 objn: 59752 objd: 59864 tsn: 4
Undo type:  Regular undo       Undo type:  Last buffer split:  No
Tablespace Undo:  No
             0x00000000
index undo for leaf key operations
KTB Redo
op: 0x04  ver: 0x01 
op: L  itl: xid:  0x0002.01a.0000037a uba: 0x00800289.03d0.21
                      flg: C---    lkc:  0     scn: 0x0000.1209122b
Dump kdilk : itl=2, kdxlkflg=0x1 sdc=0 indexid=0x100019b block=0x0100019c
(kdxlpu): purge leaf row
key :(3):  02 c1 08
CHANGE #2 TYP:0 CLS: 1 AFN:4 DBA:0x0100019c OBJ:59864 SCN:0x0000.12091a37 SEQ:  1 OP:10.2  
                                                               ++++主键索引维护
              ++++Opcode 10.2 : Insert leaf row
index redo (kdxlin):  insert leaf row
KTB Redo
op: 0x01  ver: 0x01 
op: F  xid:  0x0004.025.00000346    uba: 0x008000a6.02ae.10    ++++对应uba
REDO: SINGLE / -- / --
itl: 2, sno: 2, row size 13
insert key: (3):  02 c1 08
keydata: (6):  01 00 01 97 00 00
 
++++++++++++++++++++++++++++++++++++++++++++++++++++
insert into test_with_pk values(8,9,10);
++++++++++++++++++++++++++++++++++++++++++++++++++++
REDO RECORD - Thread:1 RBA: 0x00011f.00001e4d.0010 LEN: 0x0140 VLD: 0x05
SCN: 0x0000.12091a38 SUBSCN:  1 11/14/2018 11:19:49
CHANGE #1 TYP:0 CLS:24 AFN:2 DBA:0x008000a6 OBJ:4294967295 SCN:0x0000.12091a37 SEQ:  2 OP:5.1
ktudb redo: siz: 92 spc: 3846 flg: 0x0022 seq: 0x02ae rec: 0x11
            xid:  0x0004.025.00000346 
ktubu redo: slt: 37 rci: 16 opc: 11.1 objn: 59751 objd: 59865 tsn: 4
Undo type:  Regular undo       Undo type:  Last buffer split:  No
Tablespace Undo:  No
             0x00000000
KDO undo record:
KTB Redo
op: 0x02  ver: 0x01 
op: C  uba: 0x008000a6.02ae.0f
KDO Op code: DRP row dependencies Disabled
  xtype: XA flags: 0x00000000  bdba: 0x01000197  hdba: 0x01000193
itli: 1  ispac: 0  maxfr: 4858
tabn: 0 slot: 1(0x1)
CHANGE #2 TYP:0 CLS: 1 AFN:4 DBA:0x01000197 OBJ:59865 SCN:0x0000.12091a37 SEQ:  1 OP:11.2
KTB Redo
op: 0x02  ver: 0x01 
op: C  uba: 0x008000a6.02ae.11
KDO Op code: IRP row dependencies Disabled
  xtype: XA flags: 0x00000000  bdba: 0x01000197  hdba: 0x01000193
itli: 1  ispac: 0  maxfr: 4858
tabn: 0 slot: 1(0x1) size/delt: 12
fb: --H-FL-- lb: 0x1  cc: 3
null: ---
col  0: [ 2]  c1 09
col  1: [ 2]  c1 0a
col  2: [ 2]  c1 0b
 
REDO RECORD - Thread:1 RBA: 0x00011f.00001e4d.0150 LEN: 0x00d8 VLD: 0x01
SCN: 0x0000.12091a38 SUBSCN:  2 11/14/2018 11:19:49
CHANGE #1 TYP:0 CLS:24 AFN:2 DBA:0x008000a6 OBJ:4294967295 SCN:0x0000.12091a38 SEQ:  1 OP:5.1
ktudb redo: siz: 76 spc: 3752 flg: 0x0022 seq: 0x02ae rec: 0x12
            xid:  0x0004.025.00000346 
ktubu redo: slt: 37 rci: 17 opc: 10.22 objn: 59752 objd: 59864 tsn: 4
Undo type:  Regular undo       Undo type:  Last buffer split:  No
Tablespace Undo:  No
             0x00000000
index undo for leaf key operations
KTB Redo
op: 0x02  ver: 0x01 
op: C  uba: 0x008000a6.02ae.10
Dump kdilk : itl=2, kdxlkflg=0x1 sdc=0 indexid=0x100019b block=0x0100019c
(kdxlpu): purge leaf row
key :(3):  02 c1 09
CHANGE #2 TYP:0 CLS: 1 AFN:4 DBA:0x0100019c OBJ:59864 SCN:0x0000.12091a37 SEQ:  2 OP:10.2
index redo (kdxlin):  insert leaf row
KTB Redo
op: 0x02  ver: 0x01 
op: C  uba: 0x008000a6.02ae.12
REDO: SINGLE / -- / --
itl: 2, sno: 3, row size 13
insert key: (3):  02 c1 09
keydata: (6):  01 00 01 97 00 01
 

++++++++++++++++++++++++++++++++++++++++++++++++++++
insert into test_with_pk values(9,10,11);
++++++++++++++++++++++++++++++++++++++++++++++++++++
...

++++++++++++++++++++++++++++++++++++++++++++++++++++
insert into test_with_pk values(10,11,12);
++++++++++++++++++++++++++++++++++++++++++++++++++++
...

++++++++++++++++++++++++++++++++++++++++++++++++++++
v$database.current_scn:0x0000.12091a44
delete from test_with_pk where x=3;
++++++++++++++++++++++++++++++++++++++++++++++++++++
REDO RECORD - Thread:1 RBA: 0x00011f.00001e5d.0010 LEN: 0x015c VLD: 0x05
SCN: 0x0000.12091a46 SUBSCN:  2 11/14/2018 11:20:13
CHANGE #1 TYP:0 CLS:24 AFN:2 DBA:0x008000a6 OBJ:4294967295 SCN:0x0000.12091a40 SEQ:  2 OP:5.1
ktudb redo: siz: 156 spc: 3330 flg: 0x0022 seq: 0x02ae rec: 0x17
            xid:  0x0004.025.00000346 
ktubu redo: slt: 37 rci: 22 opc: 11.1 objn: 59751 objd: 59865 tsn: 4
Undo type:  Regular undo       Undo type:  Last buffer split:  No
Tablespace Undo:  No
             0x00000000
KDO undo record:
KTB Redo
op: 0x04  ver: 0x01 
op: L  itl: xid:  0x0009.01d.000003af uba: 0x00800a9e.03a7.03
                      flg: C---    lkc:  0     scn: 0x0000.12091229
KDO Op code: IRP row dependencies Disabled
  xtype: XA flags: 0x00000000  bdba: 0x01000198  hdba: 0x01000193
itli: 1  ispac: 0  maxfr: 4858
tabn: 0 slot: 2(0x2) size/delt: 12
fb: --H-FL-- lb: 0x0  cc: 3
null: ---
col  0: [ 2]  c1 04
col  1: [ 2]  c1 05
col  2: [ 2]  c1 06
CHANGE #2 TYP:2 CLS: 1 AFN:4 DBA:0x01000198 OBJ:59865 SCN:0x0000.1209122b SEQ:  1 OP:11.3  
                                                           ++++Opcode 11.3 : Drop Row Piece
KTB Redo
op: 0x01  ver: 0x01 
op: F  xid:  0x0004.025.00000346    uba: 0x008000a6.02ae.17
KDO Op code: DRP row dependencies Disabled
  xtype: XA flags: 0x00000000  bdba: 0x01000198  hdba: 0x01000193
itli: 1  ispac: 0  maxfr: 4858
tabn: 0 slot: 2(0x2)
 
REDO RECORD - Thread:1 RBA: 0x00011f.00001e5d.016c LEN: 0x00d4 VLD: 0x01
SCN: 0x0000.12091a46 SUBSCN:  3 11/14/2018 11:20:13
CHANGE #1 TYP:0 CLS:24 AFN:2 DBA:0x008000a6 OBJ:4294967295 SCN:0x0000.12091a46 SEQ:  1 OP:5.1
ktudb redo: siz: 84 spc: 3172 flg: 0x0022 seq: 0x02ae rec: 0x18
            xid:  0x0004.025.00000346 
ktubu redo: slt: 37 rci: 23 opc: 10.22 objn: 59752 objd: 59864 tsn: 4
Undo type:  Regular undo       Undo type:  Last buffer split:  No
Tablespace Undo:  No
             0x00000000
index undo for leaf key operations
KTB Redo
op: 0x02  ver: 0x01 
op: C  uba: 0x008000a6.02ae.16
Dump kdilk : itl=2, kdxlkflg=0x1 sdc=0 indexid=0x100019b block=0x0100019c
(kdxlre): restore leaf row (clear leaf delete flags)
key :(3):  02 c1 04
keydata/bitmap: (6):  01 00 01 98 00 02
CHANGE #2 TYP:0 CLS: 1 AFN:4 DBA:0x0100019c OBJ:59864 SCN:0x0000.12091a40 SEQ:  1 OP:10.4  
                                                        ++++Opcode 10.4 : Mark leaf row deleted
index redo (kdxlde):  delete leaf row
KTB Redo
op: 0x02  ver: 0x01 
op: C  uba: 0x008000a6.02ae.18
REDO: SINGLE / -- / --
itl: 2, sno: 0, row size 13
 
++++++++++++++++++++++++++++++++++++++++++++++++++++
delete from test_with_pk where x=4;
++++++++++++++++++++++++++++++++++++++++++++++++++++
...

++++++++++++++++++++++++++++++++++++++++++++++++++++
delete from test_with_pk where x=7;
++++++++++++++++++++++++++++++++++++++++++++++++++++
...

++++++++++++++++++++++++++++++++++++++++++++++++++++
delete from test_with_pk where x=8;
++++++++++++++++++++++++++++++++++++++++++++++++++++
REDO RECORD - Thread:1 RBA: 0x00011f.00001e64.0010 LEN: 0x0144 VLD: 0x05
SCN: 0x0000.12091a4c SUBSCN:  1 11/14/2018 11:20:31
CHANGE #1 TYP:0 CLS:24 AFN:2 DBA:0x008000a6 OBJ:4294967295 SCN:0x0000.12091a49 SEQ:  2 OP:5.1
ktudb redo: siz: 140 spc: 2630 flg: 0x0022 seq: 0x02ae rec: 0x1d
            xid:  0x0004.025.00000346 
ktubu redo: slt: 37 rci: 28 opc: 11.1 objn: 59751 objd: 59865 tsn: 4
Undo type:  Regular undo       Undo type:  Last buffer split:  No
Tablespace Undo:  No
             0x00000000
KDO undo record:
KTB Redo
op: 0x02  ver: 0x01 
op: C  uba: 0x008000a6.02ae.1b
KDO Op code: IRP row dependencies Disabled
  xtype: XA flags: 0x00000000  bdba: 0x01000197  hdba: 0x01000193
itli: 1  ispac: 0  maxfr: 4858
tabn: 0 slot: 1(0x1) size/delt: 12
fb: --H-FL-- lb: 0x1  cc: 3
null: ---
col  0: [ 2]  c1 09
col  1: [ 2]  c1 0a
col  2: [ 2]  c1 0b
CHANGE #2 TYP:0 CLS: 1 AFN:4 DBA:0x01000197 OBJ:59865 SCN:0x0000.12091a49 SEQ:  1 OP:11.3
KTB Redo
op: 0x02  ver: 0x01 
op: C  uba: 0x008000a6.02ae.1d
KDO Op code: DRP row dependencies Disabled
  xtype: XA flags: 0x00000000  bdba: 0x01000197  hdba: 0x01000193
itli: 1  ispac: 0  maxfr: 4858
tabn: 0 slot: 1(0x1)
 
REDO RECORD - Thread:1 RBA: 0x00011f.00001e64.0154 LEN: 0x00d4 VLD: 0x01
SCN: 0x0000.12091a4c SUBSCN:  2 11/14/2018 11:20:31
CHANGE #1 TYP:0 CLS:24 AFN:2 DBA:0x008000a6 OBJ:4294967295 SCN:0x0000.12091a4c SEQ:  1 OP:5.1
ktudb redo: siz: 84 spc: 2488 flg: 0x0022 seq: 0x02ae rec: 0x1e
            xid:  0x0004.025.00000346 
ktubu redo: slt: 37 rci: 29 opc: 10.22 objn: 59752 objd: 59864 tsn: 4
Undo type:  Regular undo       Undo type:  Last buffer split:  No
Tablespace Undo:  No
             0x00000000
index undo for leaf key operations
KTB Redo
op: 0x02  ver: 0x01 
op: C  uba: 0x008000a6.02ae.1c
Dump kdilk : itl=2, kdxlkflg=0x5 sdc=0 indexid=0x100019b block=0x0100019c
(kdxlre): restore leaf row (clear leaf delete flags)
key :(3):  02 c1 09
keydata/bitmap: (6):  01 00 01 97 00 01
CHANGE #2 TYP:0 CLS: 1 AFN:4 DBA:0x0100019c OBJ:59864 SCN:0x0000.12091a49 SEQ:  1 OP:10.4
index redo (kdxlde):  delete leaf row
KTB Redo
op: 0x02  ver: 0x01 
op: C  uba: 0x008000a6.02ae.1e
REDO: SINGLE / -- / --
itl: 2, sno: 3, row size 13
 
 
++++++++++++++++++++++++++++++++++++++++++++++++++++
v$database.current_scn:0x0000.12091a4e
commit;
++++++++++++++++++++++++++++++++++++++++++++++++++++
REDO RECORD - Thread:1 RBA: 0x00011f.00001e7f.0078 LEN: 0x0060 VLD: 0x01
SCN: 0x0000.12091a62 SUBSCN:  1 11/14/2018 11:21:02
CHANGE #1 TYP:0 CLS:23 AFN:2 DBA:0x00800039 OBJ:4294967295 SCN:0x0000.12091a37 SEQ:  1 OP:5.4 
                                                                           ++++DBA:0x00800039,对应回滚段头DBA
            ++++SCN:0x0000.12091a37,对应本事务首次修改REDO RECORD SCN,非CHANGE# SCN
            ++++Opcode 5.4 : Commit transaction (transaction table update)
ktucm redo: slt: 0x0025 sqn: 0x00000346 srt: 0 sta: 9 flg: 0x2             ++++对应xid:  0x0004.025.00000346
ktucf redo: uba: 0x008000a6.02ae.1e ext: 3 spc: 2402 fbi: 0                ++++0x008000a6.02ae.1e,本事务最后一次改动对应的uba

++++++++++++++++++++++++++++++++++++++++++++++++++++
v$database.current_scn:0x0000.12091a64
++++++++++++++++++++++++++++++++++++++++++++++++++++


附件2
Start dump data blocks tsn: 4 file#: 4 minblk 407 maxblk 407
buffer tsn: 4 rdba: 0x01000197 (4/407)
scn: 0x0000.12091a62 seq: 0x01 flg: 0x06 tail: 0x1a620601     ++++scn: fast cleanout scn(事务提交scn)
frmt: 0x02 chkval: 0x5ed5 type: 0x06=trans data
Hex dump of block: st=0, typ_found=1
Dump of memory from 0x0E4D8A00 to 0x0E4DAA00
...
Block header dump:  0x01000197
 Object id on Block? Y
 seg/obj: 0xe9d9  csc: 0x00.120911e5  itc: 2  flg: E  typ: 1 - DATA   
          ++++csc: 0x00,fast cleanout scn wrap;120911e5,清理(cleanout)scn base,本次测试前5小时scn
     brn: 0  bdba: 0x1000191 ver: 0x01 opc: 0              ++++bdba:level 1 bitmap block
     inc: 0  exflg: 0
 
 Itl           Xid                  Uba         Flag  Lck        Scn/Fsc
0x01   0x0004.025.00000346  0x008000a6.02ae.1d  --U-    4  fsc 0x0014.12091a62 
                                                           ++++xid:对应logfile中xid
          ++++Flag:--U-表示fast cleanout,upper bound scn
          ++++uba:对应xid事务中最后一个dml操作对应的undo block
          ++++fsc:0x0014,free space creidt;12091a62 commit scn base.
          ++++lck:4表示总共锁定4行,fast cleanout没有清理
0x02   0x0000.000.00000000  0x00000000.0000.00  ----    0  fsc 0x0000.00000000
 
data_block_dump,data header at 0xe4d8a64
===============
tsiz: 0x1f98
hsiz: 0x1a
pbl: 0x0e4d8a64
bdba: 0x01000197
     76543210
flag=--------
ntab=1
nrow=4
frre=-1
fsbo=0x1a
fseo=0x1f68
avsp=0x1f4e
tosp=0x1f66
0xe:pti[0] nrow=4 offs=0
0x12:pri[0] offs=0x1f8c
0x14:pri[1] offs=0x1f80
0x16:pri[2] offs=0x1f74
0x18:pri[3] offs=0x1f68
block_row_dump:
tab 0, row 0, @0x1f8c
tl: 2 fb: --HDFL-- lb: 0x1
tab 0, row 1, @0x1f80
tl: 2 fb: --HDFL-- lb: 0x1
tab 0, row 2, @0x1f74
tl: 12 fb: --H-FL-- lb: 0x1  cc: 3
col  0: [ 2]  c1 0a
col  1: [ 2]  c1 0b
col  2: [ 2]  c1 0c
tab 0, row 3, @0x1f68
tl: 12 fb: --H-FL-- lb: 0x1  cc: 3
col  0: [ 2]  c1 0b
col  1: [ 2]  c1 0c
col  2: [ 2]  c1 0d
end_of_block_dump
End dump data blocks tsn: 4 file#: 4 minblk 407 maxblk 407

 


附件3
Start dump data blocks tsn: 4 file#: 4 minblk 407 maxblk 407
buffer tsn: 4 rdba: 0x01000197 (4/407)
scn: 0x0000.12094bd5 seq: 0x02 flg: 0x00 tail: 0x4bd50602          ++++scn:csc SCN,csc: 0x00.12094bd3
                                                                   ++++seq:seq++
frmt: 0x02 chkval: 0x0000 type: 0x06=trans data
Hex dump of block: st=0, typ_found=1
Dump of memory from 0x0E417A00 to 0x0E419A00
...
Block header dump:  0x01000197
 Object id on Block? Y
 seg/obj: 0xe9d9  csc: 0x00.12094bd3  itc: 2  flg: E  typ: 1 - DATA    ++++csc:无活跃事务时max(cleanout scn,scn_tx) or 有活跃事务时min(hitime_scn)
     brn: 0  bdba: 0x1000191 ver: 0x01 opc: 0
     inc: 0  exflg: 0
 
 Itl           Xid                  Uba         Flag  Lck        Scn/Fsc
0x01   0x0004.025.00000346  0x008000a6.02ae.1d  C---    0  scn 0x0000.12091a62  
                                                                              ++++Flag:C-commit
                                                                              ++++Lck:0
0x02   0x0000.000.00000000  0x00000000.0000.00  ----    0  fsc 0x0000.00000000
 
data_block_dump,data header at 0xe417a64
===============
tsiz: 0x1f98
hsiz: 0x1a
pbl: 0x0e417a64
bdba: 0x01000197
     76543210
flag=--------
ntab=1
nrow=4
frre=0
fsbo=0x1a
fseo=0x1f68
avsp=0x1f66
tosp=0x1f66
0xe:pti[0] nrow=4 offs=0         ++++nrows,仍然为4
0x12:pri[0] sfll=1
0x14:pri[1] sfll=-1
0x16:pri[2] offs=0x1f74
0x18:pri[3] offs=0x1f68
block_row_dump:
tab 0, row 2, @0x1f74
tl: 12 fb: --H-FL-- lb: 0x0  cc: 3     ++++锁已清除
col  0: [ 2]  c1 0a
col  1: [ 2]  c1 0b
col  2: [ 2]  c1 0c
tab 0, row 3, @0x1f68
tl: 12 fb: --H-FL-- lb: 0x0  cc: 3
col  0: [ 2]  c1 0b
col  1: [ 2]  c1 0c
col  2: [ 2]  c1 0d
end_of_block_dump
End dump data blocks tsn: 4 file#: 4 minblk 407 maxblk 407

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

上一篇: AWR集中管理
请登录后发表评论 登录
全部评论

注册时间:2011-05-26

  • 博文量
    211
  • 访问量
    809968