本篇內(nèi)容介紹了“數(shù)據(jù)庫(kù)中ORACLE的啟動(dòng)驗(yàn)證分析”的有關(guān)知識(shí),在實(shí)際案例的操作過(guò)程中,不少人都會(huì)遇到這樣的困境,接下來(lái)就讓小編帶領(lǐng)大家學(xué)習(xí)一下如何處理這些情況吧!希望大家仔細(xì)閱讀,能夠?qū)W有所成!
創(chuàng)新互聯(lián)公司專注于廣陽(yáng)網(wǎng)站建設(shè)服務(wù)及定制,我們擁有豐富的企業(yè)做網(wǎng)站經(jīng)驗(yàn)。 熱誠(chéng)為您提供廣陽(yáng)營(yíng)銷型網(wǎng)站建設(shè),廣陽(yáng)網(wǎng)站制作、廣陽(yáng)網(wǎng)頁(yè)設(shè)計(jì)、廣陽(yáng)網(wǎng)站官網(wǎng)定制、小程序定制開發(fā)服務(wù),打造廣陽(yáng)網(wǎng)絡(luò)公司原創(chuàng)品牌,更為您提供廣陽(yáng)網(wǎng)站排名全網(wǎng)營(yíng)銷落地服務(wù)。
oradebug dump file_hdrs 3 DATA FILE #5: (name #8) /dev/raw/raw12 creation size=64000 block size=8192 status=0xe head=8 tail=8 dup=1 tablespace 5, index=6 krfil=5 prev_file=0 unrecoverable scn: 0x0000.00000000 01/01/1988 00:00:00 Checkpoint cnt:43 scn: 0x0000.000a5310 09/13/2018 06:18:03 Stop scn: 0x0000.000a5310 09/13/2018 06:18:03 Creation Checkpointed at scn: 0x0000.00002249 08/29/2018 09:27:02 thread:1 rba:(0x1.7a18.10) enabled threads: 01000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 Offline scn: 0x0000.00000000 prev_range: 0 Online Checkpointed at scn: 0x0000.00000000 thread:0 rba:(0x0.0.0) enabled threads: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 Hot Backup end marker scn: 0x0000.00000000 aux_file is NOT DEFINED above information from ctl ------------------------------------------------------------------------------------------ V10 STYLE FILE HEADER: Compatibility Vsn = 169870592=0xa200500 Db ID=880153879=0x34761517, Db Name='NGKF' Activation ID=0=0x0 Control Seq=280=0x118, File size=64000=0xfa00 File Number=5, Blksiz=8192, File Type=3 DATA Tablespace #5 - USERS rel_fn:5 Creation at scn: 0x0000.00002249 08/29/2018 09:27:02 Backup taken at scn: 0x0000.00000000 01/01/1988 00:00:00 thread:0 reset logs count:0x3abc6817 scn: 0x0000.00000001 reset logs terminal rcv data:0x0 scn: 0x0000.00000000 prev reset logs count:0x0 scn: 0x0000.00000000 prev reset logs terminal rcv data:0x0 scn: 0x0000.00000000 recovered at 09/13/2018 06:11:32 status:0x0 root dba:0x00000000 chkpt cnt: 43 ctl cnt:42 begin-hot-backup file size: 0 Checkpointed at scn: 0x0000.000a5310 09/13/2018 06:18:03 thread:1 rba:(0xb.185.10) enabled threads: 01100000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 Backup Checkpointed at scn: 0x0000.00000000 thread:0 rba:(0x0.0.0) enabled threads: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 External cache id: 0x0 0x0 0x0 0x0 Absolute fuzzy scn: 0x0000.00000000 Recovery fuzzy scn: 0x0000.00000000 01/01/1988 00:00:00 Terminal Recovery Stamp 01/01/1988 00:00:00 Platform Information: Creation Platform ID: 13 Current Platform ID: 13 Last Platform ID: 13 DUMP OF TEMP FILES: 1 files in database
當(dāng)使用 file_hdrs 事件來(lái)轉(zhuǎn)儲(chǔ)數(shù)據(jù)文件頭信息時(shí),Oracle 會(huì)轉(zhuǎn)儲(chǔ)兩部分信息,一部分來(lái)自控制文件,一部分來(lái)自數(shù)據(jù)文件,在數(shù)據(jù)庫(kù)啟動(dòng)過(guò)程中,這兩部分信息要用來(lái)進(jìn)行啟動(dòng)驗(yàn)證。
驗(yàn)證過(guò)程:
第一次檢查數(shù)據(jù)文件頭中的 Checkpoint cnt 是否與對(duì)應(yīng)控制文件中的 Checkpoint cnt
一致,如果相等,進(jìn)行第二次檢查;
file_hdrs.chkpt.cnt=ctl.chkpt.cnt
第二次檢查數(shù)據(jù)文件頭的開始SCN和對(duì)應(yīng)控制文件中的結(jié)束SCN是否一致如果結(jié)束
SCN 等于開始 SCN,則不需要對(duì)那個(gè)文件進(jìn)行恢復(fù)。
file_hdrs.start_scn = clt.stop.scn
對(duì)每個(gè)數(shù)據(jù)文件都完成檢查后,打開數(shù)據(jù)庫(kù).同時(shí)將每個(gè)數(shù)據(jù)文件的結(jié)束 SCN 設(shè)置為無(wú)窮
大。
以上面的轉(zhuǎn)儲(chǔ)信息為例:
clt中(橫線上半部分中)最重要的幾個(gè)地方
這部分中包含的重要信息有:
檢查點(diǎn)計(jì)數(shù): Checkpoint cnt:檢查點(diǎn) SCN: scn:
Checkpoint cnt:43 scn: 0x0000.000a5310 09/13/2018 06:18:03
數(shù)據(jù)文件 Stop SCN
Stop scn: 0x0000.000a5310 09/13/2018 06:18:03
數(shù)據(jù)文件頭的信息(橫線上半部分中)最重要的幾個(gè)地方
u? 檢查點(diǎn) SCN: Checkpointed at scn
u? 檢查點(diǎn)計(jì)數(shù): chkpt cnt
Checkpointed at scn: 0x0000.000a5310 09/13/2018 06:18:03
chkpt cnt: 43 ctl cnt:42
這兩者都和控制文件中所記錄的一致。如果這兩者一致,數(shù)據(jù)庫(kù)啟動(dòng)時(shí)就能通過(guò)驗(yàn)證,啟動(dòng)數(shù)據(jù)庫(kù)。
如果不一致,啟動(dòng)的時(shí)候,會(huì)有報(bào)錯(cuò)
ERROR at line 1: ORA-01113: file 4 needs media recovery ORA-01110: data file 4: '/opt/oracle/oradata/eygle/eygle01.dbf'
執(zhí)行恢復(fù)
recover datafile 4;
“數(shù)據(jù)庫(kù)中ORACLE的啟動(dòng)驗(yàn)證分析”的內(nèi)容就介紹到這里了,感謝大家的閱讀。如果想了解更多行業(yè)相關(guān)的知識(shí)可以關(guān)注創(chuàng)新互聯(lián)網(wǎng)站,小編將為大家輸出更多高質(zhì)量的實(shí)用文章!