RMAN Catalog環境下異機全庫恢復例項
Step0 建立初始環境: 建立Linux 環境 安裝Oracle 10.2.0.1並打補丁到10.2.0.4 建立掛載點,並掛載NFS卷 mount -o rw,bg,hard,nointr,rsize=32768,wsize=32768,tcp,vers=3,timeo=600,actimeo=0 10.192.28.245:/data/rmandata /rmandata/ Step1 建立密碼檔案與初始化檔案: rmancd \u01\product\oracle\dbs rman$orapwd file=orapwytedi password=password entries=5 rman$cat > initytedi.ora db_name=ytedi rman$cat initytedi.ora db_name=ytedi step2 恢復spfile: rman$rman target / catalog rmaner/rmaner@catalog Recovery Manager: Release 10.2.0.4.0 - Production on Tue Apr 10 17:12:18 2012 Copyright (c) 1982, 2007, Oracle. All rights reserved. connected to target database (not started) connected to recovery catalog database RMAN> startup nomount; Oracle instance started Total System Global Area 113246208 bytes Fixed Size 1266080 bytes Variable Size 58723936 bytes Database Buffers 50331648 bytes Redo Buffers 2924544 bytes RMAN> RMAN> restore spfile; Starting restore at 10-APR-12 allocated channel: ORA_DISK_1 channel ORA_DISK_1: sid=36 devtype=DISK channel ORA_DISK_1: starting datafile backupset restore channel ORA_DISK_1: restoring SPFILE output filename=/u01/product/oracle/dbs/spfileytedi.ora channel ORA_DISK_1: reading from backup piece /rmandata/10.192.29.56/ytedi_l2_201204090310_c-480066880-20120409-00 channel ORA_DISK_1: restored backup piece 1 piece handle=/rmandata/10.192.29.56/ytedi_l2_201204090310_c-480066880-20120409-00 tag=TAG20120409T150631 channel ORA_DISK_1: restore complete, elapsed time: 00:00:02 Finished restore at 10-APR-12 RMAN> exit Recovery Manager complete. Step3 重新使用spfile啟動到nomount狀態: rman$sqlplus / as sysdba SQL*Plus: Release 10.2.0.4.0 - Production on Tue Apr 10 17:19:56 2012 Copyright (c) 1982, 2007, Oracle. All Rights Reserved. Connected to: Oracle Database Enterprise Edition Release 10.2.0.4.0 - Production With the Partitioning, Oracle Label Security, OLAP, Mining Scoring Engine and Real Application Testing options SQL> shutdown abort ORACLE instance shut down. SQL> startup nomount ORACLE instance started. Total System Global Area 608174080 bytes Fixed Size 1268920 bytes Variable Size 176161608 bytes Database Buffers 427819008 bytes Redo Buffers 2924544 bytes SQL> Step4 根據spfile內容建立所需的目錄: SQL> create pfile from spfile SQL> ! rman$cd /u01/product/oracle/dbs/ rman$cat initytedi.ora ytedi.__db_cache_size=427819008 ytedi.__java_pool_size=4194304 ytedi.__large_pool_size=4194304 ytedi.__shared_pool_size=159383552 ytedi.__streams_pool_size=8388608 *.audit_file_dest='/u01/product/admin/ytedi/adump' *.audit_trail='DB' *.background_dump_dest='/u01/product/admin/ytedi/bdump' *.compatible='10.2.0.3.0' *.control_files='/u01/product/oradata/ytedi/control01.ctl','/u01/product/oradata/ytedi/control02.ctl','/u01/product/oradata/ytedi/control03.ctl','/data/ytedi/control04.ctl'#RestoreControlfile *.core_dump_dest='/u01/product/admin/ytedi/cdump' *.db_block_size=8192 *.db_domain='' *.db_file_multiblock_read_count=16 *.db_name='ytedi' *.db_recovery_file_dest='/u01/product/flash_recovery_area' *.db_recovery_file_dest_size=2147483648 *.dg_broker_start=FALSE *.dispatchers='(PROTOCOL=TCP) (SERVICE=ytediXDB)' *.job_queue_processes=10 *.log_archive_dest_1='LOCATION=/data/ytedi/arch' *.log_archive_dest_2='' *.log_archive_format='%t_%s_%r.arc' *.open_cursors=300 *.pga_aggregate_target=201326592 *.processes=500 *.remote_login_passwordfile='EXCLUSIVE' *.sessions=555 *.sga_target=605028352 *.undo_management='AUTO' *.undo_retention=10800 *.undo_tablespace='UNDOTBS1' *.user_dump_dest='/u01/product/admin/ytedi/udump' rman$ rman$mkdir -p /u01/product/oradata/ytedi/ rman$mkdir -p /u01/product/admin/ytedi/bdump/ rman$mkdir -p /u01/product/admin/ytedi/adump/ rman$mkdir -p /u01/product/admin/ytedi/cdump/ rman$mkdir -p /u01/product/flash_recovery_area rman$mkdir -p /data/ytedi rman$exit exit SQL> exit Step5 控制檔案: rman$rman target / catalog rmaner/rmaner@catalog Recovery Manager: Release 10.2.0.4.0 - Production on Tue Apr 10 17:24:20 2012 Copyright (c) 1982, 2007, Oracle. All rights reserved. connected to target database: ytedi (not mounted) connected to recovery catalog database RMAN> restore controlfile; Starting restore at 10-APR-12 allocated channel: ORA_DISK_1 channel ORA_DISK_1: sid=541 devtype=DISK channel ORA_DISK_1: starting datafile backupset restore channel ORA_DISK_1: restoring control file channel ORA_DISK_1: reading from backup piece /rmandata/10.192.29.56/ytedi_l2_201204100310_c-480066880-20120410-00 channel ORA_DISK_1: restored backup piece 1 piece handle=/rmandata/10.192.29.56/ytedi_l2_201204100310_c-480066880-20120410-00 tag=TAG20120410T033015 channel ORA_DISK_1: restore complete, elapsed time: 00:00:15 output filename=/u01/product/oradata/ytedi/control01.ctl output filename=/u01/product/oradata/ytedi/control02.ctl output filename=/u01/product/oradata/ytedi/control03.ctl output filename=/data/ytedi/control04.ctl Finished restore at 10-APR-12 RMAN> Step6 使用新恢復的控制檔案mount資料庫: RMAN> alter database mount; database mounted released channel: ORA_DISK_1 RMAN> Step7 Restore資料庫: RMAN> restore database; Starting restore at 10-APR-12 Starting implicit crosscheck backup at 10-APR-12 allocated channel: ORA_DISK_1 channel ORA_DISK_1: sid=541 devtype=DISK Crosschecked 94 objects Finished implicit crosscheck backup at 10-APR-12 Starting implicit crosscheck copy at 10-APR-12 using channel ORA_DISK_1 Finished implicit crosscheck copy at 10-APR-12 searching for all files in the recovery area cataloging files... no files cataloged using channel ORA_DISK_1 channel ORA_DISK_1: starting datafile backupset restore channel ORA_DISK_1: specifying datafile(s) to restore from backup set restoring datafile 00001 to /u01/product/oradata/ytedi/system01.dbf restoring datafile 00003 to /u01/product/oradata/ytedi/sysaux01.dbf restoring datafile 00004 to /u01/product/oradata/ytedi/users01.dbf restoring datafile 00005 to /data/ytedi/edibase_data01.dbf restoring datafile 00007 to /data/ytedi/edilog_index01.dbf channel ORA_DISK_1: reading from backup piece /rmandata/10.192.29.56/ytedi_l0_201204080310_p2n7skl7 ...... piece handle=/rmandata/10.192.29.56/ytedi_l0_201204080310_p8n7slmo tag=YTEDI_L0_201204080310 channel ORA_DISK_1: restore complete, elapsed time: 00:02:56 channel ORA_DISK_1: starting datafile backupset restore channel ORA_DISK_1: specifying datafile(s) to restore from backup set restoring datafile 00002 to /u01/product/oradata/ytedi/undotbs01.dbf restoring datafile 00006 to /data/ytedi/edibase_data02.dbf channel ORA_DISK_1: reading from backup piece /rmandata/10.192.29.56/ytedi_l0_201204080310_p9n7slt5 channel ORA_DISK_1: restored backup piece 1 piece handle=/rmandata/10.192.29.56/ytedi_l0_201204080310_p9n7slt5 tag=YTEDI_L0_201204080310 channel ORA_DISK_1: restore complete, elapsed time: 00:00:37 Finished restore at 10-APR-12 Step8 Recover資料庫: RMAN> recover database; Starting recover at 10-APR-12 using channel ORA_DISK_1 channel ORA_DISK_1: starting incremental datafile backupset restore channel ORA_DISK_1: specifying datafile(s) to restore from backup set destination for restore of datafile 00001: /u01/product/oradata/ytedi/system01.dbf destination for restore of datafile 00003: /u01/product/oradata/ytedi/sysaux01.dbf destination for restore of datafile 00004: /u01/product/oradata/ytedi/users01.dbf destination for restore of datafile 00005: /data/ytedi/edibase_data01.dbf destination for restore of datafile 00007: /data/ytedi/edilog_index01.dbf ...... channel ORA_DISK_1: starting archive log restore to default destination channel ORA_DISK_1: restoring archive log archive log thread=1 sequence=7910 channel ORA_DISK_1: reading from backup piece /rmandata/10.192.29.56/ytedi_l2_201204100310_arc_q0n81ui4 channel ORA_DISK_1: restored backup piece 1 piece handle=/rmandata/10.192.29.56/ytedi_l2_201204100310_arc_q0n81ui4 tag=YTEDI_ARC_201204100310 channel ORA_DISK_1: restore complete, elapsed time: 00:00:02 archive log filename=/data/ytedi/arch1_7910_708618624.arc thread=1 sequence=7910 unable to find archive log archive log thread=1 sequence=7911 RMAN-00571: =========================================================== RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS =============== RMAN-00571: =========================================================== RMAN-03002: failure of recover command at 04/10/2012 20:16:40 RMAN-06054: media recovery requesting unknown log: thread 1 seq 7911 lowscn 11859098336858 RMAN> Step9 使用Resetlogs選項開啟資料庫: RMAN> alter database open resetlogs; database opened new incarnation of database registered in recovery catalog starting full resync of recovery catalog full resync complete RMAN> |
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/196700/viewspace-739826/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- RMAN異機恢復:RAC到單例項單例
- Rman 單例項filesystem(Windows)恢復到ASM環境(Linux)單例WindowsASMLinux
- standby全庫rman備份檔案恢復到異機
- catalog損壞情況下的資料庫恢復例項資料庫
- Oracle 11.2.0.4 從單例項,使用RMAN 異機恢復到RACOracle單例
- Oracle RMAN異機恢復Oracle
- oracle 9I 資料庫異機恢復( Catalog 庫 )Oracle資料庫
- 【備份恢復】RMAN catalog 恢復目錄資料庫資料庫
- 使用catalog的方式下,全庫恢復的步驟
- rman恢復方案和oracle異機恢復Oracle
- 【RMAN】RAC資料恢復至單機環境資料恢復
- 在windows系統環境下實現NBU異機恢復Windows
- oracle的RMAN異機恢復Oracle
- RMAN異機恢復總結
- 單例項環境利用備份恢復RAC資料庫(四)單例資料庫
- 單例項環境利用備份恢復RAC資料庫(三)單例資料庫
- 單例項環境利用備份恢復RAC資料庫(二)單例資料庫
- 單例項環境利用備份恢復RAC資料庫(一)單例資料庫
- ORACLE RMAN異機異目錄恢復Oracle
- rman 全庫恢復asm資料庫ASM資料庫
- rac到單例項的rman恢復單例
- 【kingsql分享】將RAC資料庫異機恢復到單例項(Ⅰ)SQL資料庫單例
- RMAN全庫【完全恢復/不完全恢復brief version】
- 使用RMAN恢復目錄(catalog)解析
- 生產環境資料庫恢復一例資料庫
- rman之同平臺異機恢復
- Oracle 12c RMAN 異機恢復Oracle
- Oracle 11g RMAN 異機恢復Oracle
- RMAN例項備份與恢復詳解
- rman資料庫全庫備份與恢復資料庫
- Oracle例項恢復機制Oracle
- Oracle 備份恢復篇之RMAN catalogOracle
- oracle實驗記錄 (恢復-rman catalog)Oracle
- 異機恢復RMAN-05517解決方法
- RMAN備份異機恢復流程總結
- RMAN備份恢復——RAC環境資料庫的備份(zt)資料庫
- RMAN備份恢復--RAC環境資料庫的備份(十)資料庫
- RMAN備份恢復——RAC環境資料庫的備份(一)資料庫