- 論壇徽章:
- 0
|
恢復(fù)過程如下:
在時間T1把,數(shù)據(jù)庫A,改成歸檔模式,并立即冷備份全部的文件包括(datafile,redolog,controlfile)
在時間T2,數(shù)據(jù)庫A,生成了若干的歸檔日志文件。
時間T3,建立備份數(shù)據(jù)庫B,并將數(shù)據(jù)庫A的冷備份覆蓋掉數(shù)據(jù)庫B。這個時候的數(shù)據(jù)庫B,就變成了數(shù)據(jù)庫A在T1時刻的狀態(tài)
如果,想把數(shù)據(jù)庫B還原成數(shù)據(jù)庫A在T2的狀態(tài),直接運用數(shù)據(jù)庫在時間T1--->T2這段時間的歸檔日志就可以了
問題:
1、因為數(shù)據(jù)庫B在T3時刻是一致狀態(tài)(其實就是數(shù)據(jù)庫A在T1時刻的冷備份),那么系統(tǒng)是怎么確定恢復(fù)的起始位置和終點位置,來運用生成的歸檔日志,是B回到A在T2時刻的狀態(tài)的呢?
我在恢復(fù)的時候過程如下:
SQL> recover database using backup controlfile until cancel;
ORA-00279: change 217428784 generated at 01/19/2008 09:39:23 needed for thread
1
ORA-00289: suggestion : /log/archivelog/ddqtarch/arch_ddqt_1_1567_0001.arc
ORA-00280: change 217428784 for thread 1 is in sequence #1567
Specify log: {<RET>=suggested | filename | AUTO | CANCEL}
ORA-00283: recovery session canceled due to errors
ORA-00355: change numbers out of order
ORA-00353: log corruption near block 38453 change 217428784 time 01/18/2008
22:25:46
ORA-00334: archived log: '/log/archivelog/ddqtarch/arch_ddqt_1_1567_0001.arc'
ORA-01112: media recovery not started
上面的這個錯誤,跟當(dāng)前的redolog有關(guān)系,〔Ora-00355 A change number found in the redo log is lower than a previously encountered change number〕
如果要恢復(fù)的話,是否需要重建日志文件呢?還是必須使用數(shù)據(jù)庫A在T2時間的redolog呢?
然后試圖打開數(shù)據(jù)庫時如下:
SQL> alter database open resetlogs;
alter database open resetlogs
*
ERROR at line 1:
ORA-01196: file 1 is inconsistent due to a failed media recovery session
ORA-01110: data file 1: '/oradata/ddback/ddqtsyst.dat'
[ 本帖最后由 moumoulrc 于 2008-1-19 10:31 編輯 ] |
|