Hello Yong,
I had participated in "Max SCN - Data dictionary"
thread in revealnet.com. I'm pasting here.
*************
Hi,
You can reach max SCN over x$kcccp.CPODS.
if you interested in details you can read followings:
Change vector:
--------------
it describes to single change to single block. a
sample change vector
from redo logfile dump:
CHANGE #1 TYP:0 CLS:15 AFN:2 DBA:0x0080012e
SCN:0x0000.00053e76
SEQ: 1 OP:5.2
ktudh redo: slt: 0x0005 sqn: 0x00000196 flg: 0x0012
siz: 104 fbi: 0
uba: 0x008000c2.004b.09 pxid: 0x0000.000.00000000
Redo record:
------------
group of change vectors describing single atomic
change. for example, an
insert statment is a redo record consisting of
following change vectors:
- upddating tx table in rbs header
- inserting undo block
- inserting actual data
- media recovery purposes
a transaction consists of redo records. and redo
records are ordered by
SCNs in icreasing order.
a sample of simple insert statement from redolog dump:
------------------------------------------------------
REDO RECORD - Thread:1 RBA: 0x0000be.00000002.0038
LEN: 0x01e0
VLD: 0x01
SCN scn: 0x0000.00053e76 01/19/2001 17:04:00
CHANGE #1 TYP:0 CLS:15 AFN:2 DBA:0x0080012e
SCN:0x0000.00053e76
SEQ: 1 OP:5.2
ktudh redo: slt: 0x0005 sqn: 0x00000196 flg: 0x0012
siz: 104 fbi: 0
uba: 0x008000c2.004b.09 pxid: 0x0000.000.00000000
CHANGE #2 TYP:0 CLS:16 AFN:2 DBA:0x008000c2
SCN:0x0000.00053e6b
SEQ: 1 OP:5.1
ktudb redo: siz: 104 spc: 774 flg: 0x0012 seq: 0x004b
rec: 0x09
xid: 0x0002.005.00000196
ktubl redo: slt: 5 rci: 0 opc: 11.1 objn: 3010 objd:
3010 tsn: 0
Undo type: Regular undo Begin trans Last buffer split:
No
Temp Object: No
Tablespace Undo: No
0x00000000 prev ctl uba: 0x008000c2.004b.08
prev ctl max cmt scn: 0x0000.00040520 prev tx cmt scn:
0x0000.00040524
KDO undo record:
KTB Redo
op: 0x04 ver: 0x01
op: L itl: scn: 0x0001.00b.00000198 uba:
0x0080019e.004a.0c
flg: C--- lkc: 0 scn: 0x0000.00053e71
KDO Op code: DRP xtype: XA bdba: 0x00404a19 hdba:
0x00404a18
itli: 1 ispac: 0 maxfr: 1177
tabn: 0 slot: 1(0x1)
CHANGE #3 TYP:2 CLS: 1 AFN:1 DBA:0x00404a19
SCN:0x0000.00053e71
SEQ: 1 OP:11.2
KTB Redo
op: 0x11 ver: 0x01
op: F xid: 0x0002.005.00000196 uba: 0x008000c2.004b.09
Block cleanout record, scn: 0x0000.00053e76 ver: 0x01,
entries follow...
itli: 1 flg: 2 scn: 0x0000.00053e71
KDO Op code: IRP xtype: XA bdba: 0x00404a19 hdba:
0x00404a18
itli: 1 ispac: 0 maxfr: 1177
tabn: 0 slot: 1(0x1) size/delt: 7
fb: --H-FL-- lb: 0x1 cc: 1
null: -
col 0: [ 3] 61 62 63
CHANGE #4 MEDIA RECOVERY MARKER SCN:0x0000.00000000
SEQ: 0
OP:5.19
session number = 7
serial number = 1
current username = SYS
login username = SYS
client info =
OS username = BILL?GATES
Machine name = DEFAULT
OS terminal = DEFAULT
OS process id = 429453570
OS program name = SVRMGRL.EXE
as you see in dump, insert causes respectivly:
- opcode 5.2 in CHANGE #1 means using tx table in rbs
- opcode 5.1 in CHANGE #2 means using undo block in
rbs
- opcode 11.2 in CHANGE #3 means using actual data
block
- opcode 5.19 in CHANGE #4 means media recovey
porpuses
Redo Byte Adress(RBA):
----------------------
shows the location of redo record.
*************
note that, 'SCN scn' shows redo record's SCN, but SCN
in change vector
shows SCN which will be applied to object.
there is a structure in controlfile. from controlfile
dump(x$kcccp):
***************************************************************************
CHECKPOINT PROGRESS RECORDS
***************************************************************************
(blkno = 0x3, size = 104, max = 1, in-use = 1,
last-recid= 0)
THREAD #1 - status:0x2 flags:0x0 dirty:3
low cache rba:(0xbe.2.0) on disk rba:(0xbe.5.0)
on disk scn: 0x0000.00053e78 01/19/2001 17:04:01
resetlogs scn: 0x0000.00000001 12/25/2000 12:27:05
heartbeat: 419463787 mount id: 2659721494
explanation:
low cache rba: shows which address recovery will start
on disk rba: highest RBA. it's just beyond the last
redo generated. this
points to block has not written yet.
on disk scn: SCN of on disk rba. in other words, after
last statement
generate a redo record, oracle automaticly will create
a redo record at
on disk rba. the SCN of this redo record is the
highest SCN in system. in
our sample, it's 0x0000.00053e78. we can confirm this
by redolog dump.
from last redo record from redo dump:
REDO RECORD - Thread:1 RBA: 0x0000be.00000004.0010
LEN: 0x0050
VLD: 0x01
SCN scn: 0x0000.00053e78 01/19/2001 17:04:01
CHANGE #1 TYP:0 CLS:15 AFN:2 DBA:0x0080012e
SCN:0x0000.00053e76
SEQ: 2 OP:5.4
ktucm redo: slt: 0x0005 sqn: 0x00000196 srt: 0 sta: 9
flg: 0x2
ktucf redo: uba: 0x008000c2.004b.09 ext: 1 spc: 668
fbi: 0
END OF REDO DUMP
SCN scn: 0x0000.00053e78 of redo dump = on disk scn:
0x0000.00053e78 of controlfile dump.
recovery starts from 'low cache rba' until 'on disk
rba'. since all
redo-records are ordered by SCN, no consistency
problem occurs.
if we return your question, SCN of last commit is not
last SCN in system.
Oracle will automaticly create a redo record to show
next redo record in
redolog file. for example, my last commit's SCN is SCN
scn:
0x0000.00053e76(see redo record dump above). but, last
SCN is
0x0000.00053e78.
I attached redolog and control file dumps.
regards..
*************
--- yong huang <[EMAIL PROTECTED]> wrote:
> Hi, Danisment,
>
> The URL gave me an error "WebBoard Error: Board Not
> Found". Could you double
> check and let me know? I'm very interested in it.
>
> Thanks a lot.
>
> Also, where do you get the description of these x$
> tables? I'm compiling a list
> of these cryptic table names at
>
http://www.stormloader.com/yonghuang/computer/x$table.html.
> Please take a look
> at it and give me critique.
>
> Yong Huang
>
> you wrote:
>
> Hello,
>
> x$kcccp shows CHECKPOINT PROGRESS RECORDS in
> controlfile.
>
> If you are interested in internals, see thread in
> http://pipetalk.revealnet.com/read?63845,59
>
> regards...
>
> __________________________________________________
> Do You Yahoo!?
> Yahoo! Auctions - Buy the things you want at great
> prices.
> http://auctions.yahoo.com
=====
---------------------------------------
Danisment Gazi Unal
Web: http://www.geocities.com/danisment
---------------------------------------
__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail - only $35
a year! http://personal.mail.yahoo.com/
--
Please see the official ORACLE-L FAQ: http://www.orafaq.com
--
Author: Danisment UNAL
INET: [EMAIL PROTECTED]
Fat City Network Services -- (858) 538-5051 FAX: (858) 538-5051
San Diego, California -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from). You may
also send the HELP command for other information (like subscribing).