使用oradebug工具分析完controlfile之后,再来继续日志文件头。
SQL> ALTER SESSION SET EVENTS 'immediate trace name redohdr level 10';
从Trace文件中,我们可以获得如下信息:
*** 2007-05-09 22:44:28.000
*** SESSION ID:(11.12) 2007-05-09 22:44:28.000
DUMP OF LOG FILES: 3 logs in database
LOG FILE #1:
(name #3) F:ORACLEORADATASDUSUNREDO01.LOG
Thread 1 redo log links: forward: 2 backward: 0
siz: 0x32000 seq: 0x00000005 hws: 0x27 bsz: 512 nab: 0x15f81 flg: 0x1 dup: 1
<
siz表明了日志文件的大小:0x32000*512/8192=102MB;
Thread 1 以及 seq: 0x00000005 都可以从以下的select语句得到:
select * from v$log;
bsz: 512说明redo log file的块大小为512 bytes;
>
Archive links: fwrd: 0 back: 0 Prev scn: 0x0000.0018291b
Low scn: 0x0000.001bfcf4 01/26/2007 21:15:40
Next scn: 0x0000.001d9522 04/27/2007 20:31:46
FILE HEADER:
Software vsn=153092096=0x9200000, Compatibility Vsn=153092096=0x9200000
Db ID=3675493804=0xdb1395ac, Db Name='SDUSUN'
Activation ID=3683317778=0xdb8af812
Control Seq=887=0x377, File size=204800=0x32000
File Number=1, Blksiz=512, File Type=2 LOG
descrip:"Thread 0001, Seq# 0000000005, SCN 0x0000001bfcf4-0x0000001d9522"
thread: 1 nab: 0x15f81 seq: 0x00000005 hws: 0x27 eot: 0 dis: 0
reset logs count: 0x2458d9b5 scn: 0x0000.0013262b
Low scn: 0x0000.001bfcf4 01/26/2007 21:15:40
<
注意这里的Low scn: 0x0000.001bfcf4与LOG FILE #3的Next scn相同,
这说明这个日志是由LOG FILE #3切换过来的
>
Next scn: 0x0000.001d9522 04/27/2007 20:31:46
<
注意这里的Next scn: 0x0000.001d9522与LOG FILE #2的Low scn相同,
这说明这个日志切换之后就是LOG FILE #2
>
Enabled scn: 0x0000.0013262b 12/21/2006 21:37:57
Thread closed scn: 0x0000.001d7d21 04/27/2007 17:48:15
Log format vsn: 0x8000000 Disk cksum: 0x2e21 Calc cksum: 0x2e21
Terminal Recovery Stamp scn: 0x0000.00000000 01/01/1988 00:00:00
Most recent redo scn: 0x0000.00000000
Largest LWN: 0 blocks
Miscellaneous flags: 0x0
LOG FILE #2:
(name #2) F:ORACLEORADATASDUSUNREDO02.LOG
Thread 1 redo log links: forward: 3 backward: 1
siz: 0x32000 seq: 0x00000006 hws: 0xd bsz: 512 nab: 0xffffffff flg: 0x8 dup: 1
Archive links: fwrd: 0 back: 0 Prev scn: 0x0000.001bfcf4
Low scn: 0x0000.001d9522 04/27/2007 20:31:46
Next scn: 0xffff.ffffffff 01/01/1988 00:00:00
FILE HEADER:
Software vsn=153092096=0x9200000, Compatibility Vsn=153092096=0x9200000
Db ID=3675493804=0xdb1395ac, Db Name='SDUSUN'
Activation ID=3683317778=0xdb8af812
Control Seq=887=0x377, File size=204800=0x32000
File Number=2, Blksiz=512, File Type=2 LOG
descrip:"Thread 0001, Seq# 0000000006, SCN 0x0000001d9522-0xffffffffffff"
thread: 1 nab: 0xffffffff seq: 0x00000006 hws: 0xd eot: 1 dis: 0
reset logs count: 0x2458d9b5 scn: 0x0000.0013262b
Low scn: 0x0000.001d9522 04/27/2007 20:31:46
Next scn: 0xffff.ffffffff 01/01/1988 00:00:00
Enabled scn: 0x0000.0013262b 12/21/2006 21:37:57
Thread closed scn: 0x0000.002054c1 05/09/2007 22:06:25
Log format vsn: 0x8000000 Disk cksum: 0xac4 Calc cksum: 0xac4
Terminal Recovery Stamp scn: 0x0000.00000000 01/01/1988 00:00:00
Most recent redo scn: 0x0000.00000000
Largest LWN: 0 blocks
Miscellaneous flags: 0x0
LOG FILE #3:
(name #1) F:ORACLEORADATASDUSUNREDO03.LOG
Thread 1 redo log links: forward: 0 backward: 2
siz: 0x32000 seq: 0x00000004 hws: 0x21 bsz: 512 nab: 0x31fff flg: 0x1 dup: 1
Archive links: fwrd: 0 back: 0 Prev scn: 0x0000.001766a3
Low scn: 0x0000.0018291b 01/11/2007 00:01:02
Next scn: 0x0000.001bfcf4 01/26/2007 21:15:40
FILE HEADER:
Software vsn=153092096=0x9200000, Compatibility Vsn=153092096=0x9200000
Db ID=3675493804=0xdb1395ac, Db Name='SDUSUN'
Activation ID=3683317778=0xdb8af812
Control Seq=887=0x377, File size=204800=0x32000
File Number=3, Blksiz=512, File Type=2 LOG
descrip:"Thread 0001, Seq# 0000000004, SCN 0x00000018291b-0x0000001bfcf4"
thread: 1 nab: 0x31fff seq: 0x00000004 hws: 0x21 eot: 0 dis: 0
reset logs count: 0x2458d9b5 scn: 0x0000.0013262b
Low scn: 0x0000.0018291b 01/11/2007 00:01:02
Next scn: 0x0000.001bfcf4 01/26/2007 21:15:40
Enabled scn: 0x0000.0013262b 12/21/2006 21:37:57
Thread closed scn: 0x0000.001b647e 01/24/2007 14:52:59
Log format vsn: 0x8000000 Disk cksum: 0xa886 Calc cksum: 0xa886
Terminal Recovery Stamp scn: 0x0000.00000000 01/01/1988 00:00:00
Most recent redo scn: 0x0000.00000000
Largest LWN: 0 blocks
Miscellaneous flags: 0x0
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/593324/viewspace-376200/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/593324/viewspace-376200/