單例項恢復RAC資料庫步驟(三)
簡單描述在測試伺服器的單機環境恢復RAC產品資料庫的步驟。
這一篇介紹資料庫恢復過程。
單例項恢復RAC資料庫步驟(一):http://yangtingkun.itpub.net/post/468/514155
單例項恢復RAC資料庫步驟(二):http://yangtingkun.itpub.net/post/468/514246
首先恢復歸檔檔案:
rman target /
Recovery Manager: Release 10.2.0.5.0 - Production on Mon Jan 17 16:15:23 2011
Copyright (c) 1982, 2007, Oracle. All rights reserved.
connected to target database: ORCL (DBID=1264586523, not open)
RMAN> restore archivelog sequence between 13941 and 13942 thread 2;
Starting restore at 17-JAN-11
using target database control file instead of recovery catalog
allocated channel: ORA_DISK_1
channel ORA_DISK_1: sid=1638 devtype=DISK
channel ORA_DISK_1: starting archive log restore to default destination
channel ORA_DISK_1: restoring archive log
archive log thread=2 sequence=13941
channel ORA_DISK_1: reading from backup piece /rman/backup/orcl/5tm2af71_1_1
channel ORA_DISK_1: restored backup piece 1
failover to piece handle=/data/backup/orcl/5tm2af71_1_1 tag=TAG20110117T044518
channel ORA_DISK_1: restore complete, elapsed time: 00:00:02
channel ORA_DISK_1: starting archive log restore to default destination
channel ORA_DISK_1: restoring archive log
archive log thread=2 sequence=13942
channel ORA_DISK_1: reading from backup piece /rman/backup/orcl/60m2an40_1_1
channel ORA_DISK_1: restored backup piece 1
failover to piece handle=/data/backup/orcl/60m2an40_1_1 tag=TAG20110117T070016
channel ORA_DISK_1: restore complete, elapsed time: 00:00:03
Finished restore at 17-JAN-11
RMAN> restore archivelog sequence between 868 and 869 thread 1;
Starting restore at 17-JAN-11
using channel ORA_DISK_1
channel ORA_DISK_1: starting archive log restore to default destination
channel ORA_DISK_1: restoring archive log
archive log thread=1 sequence=868
channel ORA_DISK_1: reading from backup piece /rman/backup/orcl/5um2af72_1_1
channel ORA_DISK_1: restored backup piece 1
failover to piece handle=/data/backup/orcl/5um2af72_1_1 tag=TAG20110117T044518
channel ORA_DISK_1: restore complete, elapsed time: 00:00:01
channel ORA_DISK_1: starting archive log restore to default destination
channel ORA_DISK_1: restoring archive log
archive log thread=1 sequence=869
channel ORA_DISK_1: reading from backup piece /rman/backup/orcl/61m2an40_1_1
channel ORA_DISK_1: restored backup piece 1
failover to piece handle=/data/backup/orcl/61m2an40_1_1 tag=TAG20110117T070016
channel ORA_DISK_1: restore complete, elapsed time: 00:00:01
Finished restore at 17-JAN-11
RMAN> exit
Recovery Manager complete.
利用sqlplus執行日誌檔案重新命名和恢復工作:
$ sqlplus / as sysdba
SQL*Plus: Release 10.2.0.5.0 - Production on Mon Jan 17 16:06:42 2011
Copyright (c) 1982, 2010, Oracle. All Rights Reserved.
Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.5.0 - 64bit Production
With the Partitioning, Data Mining and Real Application Testing options
SQL> ALTER DATABASE RENAME FILE '+DATADG/orcl/onlinelog/group_7.266.740450465' TO '/data/oradata/orcl/redo_7_1_1.log';
Database altered.
SQL> ALTER DATABASE RENAME FILE '+FRADG/orcl/onlinelog/group_7.304.740450465' TO '/data/oradata/orcl/redo_7_1_2.log';
Database altered.
SQL> ALTER DATABASE RENAME FILE '+DATADG/orcl/onlinelog/group_8.302.740450465' TO '/data/oradata/orcl/redo_8_1_1.log';
Database altered.
SQL> ALTER DATABASE RENAME FILE '+FRADG/orcl/onlinelog/group_8.287.740450465' TO '/data/oradata/orcl/redo_8_1_2.log';
Database altered.
SQL> ALTER DATABASE RENAME FILE '+DATADG/orcl/onlinelog/group_9.300.740450467' TO '/data/oradata/orcl/redo_9_1_1.log';
Database altered.
SQL> ALTER DATABASE RENAME FILE '+FRADG/orcl/onlinelog/group_9.275.740450467' TO '/data/oradata/orcl/redo_9_1_2.log';
Database altered.
SQL> ALTER DATABASE RENAME FILE '+DATADG/orcl/onlinelog/group_10.303.740450467' TO '/data/oradata/orcl/redo_10_2_1.log';
Database altered.
SQL> ALTER DATABASE RENAME FILE '+FRADG/orcl/onlinelog/group_10.303.740450469' TO '/data/oradata/orcl/redo_10_2_2.log';
Database altered.
SQL> ALTER DATABASE RENAME FILE '+DATADG/orcl/onlinelog/group_11.301.740450469' TO '/data/oradata/orcl/redo_11_2_1.log';
Database altered.
SQL> ALTER DATABASE RENAME FILE '+FRADG/orcl/onlinelog/group_11.268.740450469' TO '/data/oradata/orcl/redo_11_2_2.log';
Database altered.
SQL> ALTER DATABASE RENAME FILE '+DATADG/orcl/onlinelog/group_12.258.740450471' TO '/data/oradata/orcl/redo_12_2_1.log';
Database altered.
SQL> ALTER DATABASE RENAME FILE '+FRADG/orcl/onlinelog/group_12.310.740450471' TO '/data/oradata/orcl/redo_12_2_2.log';
Database altered.
SQL> RECOVER DATABASE UNTIL CANCEL USING BACKUP CONTROLFILE
ORA-00279: change 913655386 generated at 01/17/2011 04:40:28 needed for thread 2
ORA-00289: suggestion : /data/oradata/orcl/archivelog/2_13941_738351476.dbf
ORA-00280: change 913655386 for thread 2 is in sequence #13941
Specify log: {
ORA-00279: change 913655386 generated at 01/17/2011 04:40:33 needed for thread 1
ORA-00289: suggestion : /data/oradata/orcl/archivelog/1_868_738351476.dbf
ORA-00280: change 913655386 for thread 1 is in sequence #868
Specify log: {
ORA-00279: change 913655567 generated at 01/17/2011 04:45:37 needed for thread 1
ORA-00289: suggestion : /data/oradata/orcl/archivelog/1_869_738351476.dbf
ORA-00280: change 913655567 for thread 1 is in sequence #869
ORA-00278: log file '/data/oradata/orcl/archivelog/1_868_738351476.dbf' no
longer needed for this recovery
Specify log: {
ORA-00279: change 913655570 generated at 01/17/2011 04:45:12 needed for thread 2
ORA-00289: suggestion : /data/oradata/orcl/archivelog/2_13942_738351476.dbf
ORA-00280: change 913655570 for thread 2 is in sequence #13942
ORA-00278: log file '/data/oradata/orcl/archivelog/2_13941_738351476.dbf' no
longer needed for this recovery
Specify log: {
ORA-00279: change 913670182 generated at 01/17/2011 07:00:05 needed for thread 2
ORA-00289: suggestion : /data/oradata/orcl/archivelog/2_13943_738351476.dbf
ORA-00280: change 913670182 for thread 2 is in sequence #13943
ORA-00278: log file '/data/oradata/orcl/archivelog/2_13942_738351476.dbf' no
longer needed for this recovery
Specify log: {
/data/oradata/orcl/archivelog/archive_2_13943.log
ORA-00279: change 913670208 generated at 01/17/2011 07:00:34 needed for thread 1
ORA-00289: suggestion : /data/oradata/orcl/archivelog/1_870_738351476.dbf
ORA-00280: change 913670208 for thread 1 is in sequence #870
ORA-00278: log file '/data/oradata/orcl/archivelog/1_869_738351476.dbf' no
longer needed for this recovery
Specify log: {
/data/oradata/orcl/archivelog/archive_1_870.log
ORA-00279: change 913768457 generated at 01/17/2011 08:36:12 needed for thread 2
ORA-00289: suggestion : /data/oradata/orcl/archivelog/2_13944_738351476.dbf
ORA-00280: change 913768457 for thread 2 is in sequence #13944
ORA-00278: log file '/data/oradata/orcl/archivelog/archive_2_13943.log' no
longer needed for this recovery
Specify log: {
/data/oradata/orcl/archivelog/archive_2_13944.log
ORA-00279: change 913891849 generated at 01/17/2011 09:27:57 needed for thread 2
ORA-00289: suggestion : /data/oradata/orcl/archivelog/2_13945_738351476.dbf
ORA-00280: change 913891849 for thread 2 is in sequence #13945
ORA-00278: log file '/data/oradata/orcl/archivelog/archive_2_13944.log' no
longer needed for this recovery
Specify log: {
/data/oradata/orcl/archivelog/archive_2_13945.log
ORA-00279: change 913979720 generated at 01/17/2011 10:06:52 needed for thread 2
ORA-00289: suggestion : /data/oradata/orcl/archivelog/2_13946_738351476.dbf
ORA-00280: change 913979720 for thread 2 is in sequence #13946
ORA-00278: log file '/data/oradata/orcl/archivelog/archive_2_13945.log' no
longer needed for this recovery
Specify log: {
/data/oradata/orcl/archivelog/archive_2_13946.log
ORA-00279: change 913979790 generated at 01/17/2011 10:07:20 needed for thread 1
ORA-00289: suggestion : /data/oradata/orcl/archivelog/1_871_738351476.dbf
ORA-00280: change 913979790 for thread 1 is in sequence #871
ORA-00278: log file '/data/oradata/orcl/archivelog/archive_1_870.log' no longer
needed for this recovery
Specify log: {
cancel
Media recovery cancelled.
SQL> SELECT NAME FROM V$TEMPFILE;
NAME
--------------------------------------------------------------------------------
+DATADG/orcl/tempfile/temp.263.736805823
SQL> ALTER DATABASE RENAME FILE '+DATADG/orcl/tempfile/temp.263.736805823' TO '/data/oradata/orcl/temp01.dbf';
Database altered.
SQL> ALTER DATABASE TEMPFILE '/data/oradata/orcl/temp01.dbf' DROP;
Database altered.
SQL> ALTER DATABASE OPEN RESETLOGS;
Database altered.
SQL> ALTER TABLESPACE TEMP ADD TEMPFILE '/data/oradata/orcl/temp01.dbf' SIZE 4G;
Tablespace altered.
重建臨時檔案,然後將資料庫開啟,至此資料庫恢復完畢。
如果資料庫打算長期適用,可以根據現有的pfile建立SPFILE,方便以後的管理操作。
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/4227/viewspace-688150/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- 單例項恢復RAC資料庫步驟(二)單例資料庫
- 單例項恢復RAC資料庫步驟(一)單例資料庫
- RAC資料庫恢復到單例項資料庫資料庫單例
- 恢復RAC資料庫到單例項(ASM)資料庫單例ASM
- 單例項環境利用備份恢復RAC資料庫(三)單例資料庫
- 【RAC】將單例項備份集恢復為rac資料庫單例資料庫
- 【RAC】將RAC備份集恢復為單例項資料庫單例資料庫
- 將RAC備份集恢復為單例項資料庫單例資料庫
- 單例項環境利用備份恢復RAC資料庫(四)單例資料庫
- 單例項環境利用備份恢復RAC資料庫(二)單例資料庫
- 單例項環境利用備份恢復RAC資料庫(一)單例資料庫
- rac恢復到單例項單例
- 單例項恢復至RAC單例
- 自己理解的例項恢復步驟
- RAC 資料庫恢復到單例項下並且基於時間點恢復資料庫單例
- RAC從帶庫到單例項的恢復單例
- 【kingsql分享】將RAC資料庫異機恢復到單例項(Ⅰ)SQL資料庫單例
- RAC asm恢復到單例項ASM單例
- rac到單例項的rman恢復單例
- 單例項備份恢復成RAC單例
- rac asm 恢復到 單例項 1ASM單例
- rac asm 恢復到 單例項 2ASM單例
- RMAN異機恢復:RAC到單例項單例
- RAC恢復到單例項節點上單例
- 恢復rac db(raw)到單例項下單例
- 單例項備份集恢復到RAC單例
- Oracle資料庫例項啟動步驟分析Oracle資料庫
- 用rman進行恢復資料,簡單步驟!
- oracle資料庫跨平臺(AIX)從RAC恢復至(linux)下的單例項Oracle資料庫AILinux單例
- 用友財務軟體資料庫恢復步驟資料庫
- 單例項資料庫expdp遷移到RAC庫單例資料庫
- RAC環境利用備份恢復RAC資料庫(三)資料庫
- 【ASK_ORACLE】Relink ASM單例項資料庫詳細步驟OracleASM單例資料庫
- 【資料庫資料恢復】ASM例項不能掛載的Oracle資料庫資料恢復案例資料庫資料恢復ASMOracle
- 資料塊恢復例項
- Oracle RAC恢復成單節點資料庫Oracle資料庫
- 從nub備份恢復(同平臺)恢復RAC至單例項單例
- 判斷資料庫是否需要例項恢復資料庫