資料庫不完全恢復。
RMAN> list backup of database SUMMARY;
List of Backups
===============
Key TY LV S Device Type Completion Time #Pieces #Copies Compressed Tag
------- -- -- - ----------- --------------- ------- ------- ---------- ---
2552 B F A DISK 08-DEC-16 1 1 NO Q107
2688 B F A DISK 08-DEC-16 11 1 YES TAG20161208T170624
4415 B F A DISK 22-DEC-16 1 1 NO TAG20161222T093418
RMAN> startup mount
Oracle instance started
database mounted
Total System Global Area 1068937216 bytes
Fixed Size 2260088 bytes
Variable Size 666895240 bytes
Database Buffers 394264576 bytes
Redo Buffers 5517312 bytes
RMAN> list backup of database;
List of Backup Sets
===================
BS Key Type LV Size Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
2552 Full 363.09M DISK 00:00:04 08-DEC-16
BP Key: 2565 Status: AVAILABLE Compressed: NO Tag: Q107
Piece Name: /u01/p1_full_19rmvges_1_1.bak
List of Datafiles in backup set 2552
File LV Type Ckp SCN Ckp Time Name
---- -- ---- ---------- --------- ----
1 Full 599192 08-DEC-16 /opt/PROD2/system01.dbf
2 Full 599192 08-DEC-16 /opt/PROD2/sysaux01.dbf
3 Full 599192 08-DEC-16 /opt/PROD2/undotbs01.dbf
4 Full 599192 08-DEC-16 /opt/PROD2/users01.dbf
BS Key Type LV Size Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
2688 Full 43.35M DISK 00:00:06 08-DEC-16
Keep: BACKUP_LOGS Until: FOREVER
List of Datafiles in backup set 2688
File LV Type Ckp SCN Ckp Time Name
---- -- ---- ---------- --------- ----
1 Full 599607 08-DEC-16 /opt/PROD2/system01.dbf
Backup Set Copy #1 of backup set 2688
Device Type Elapsed Time Completion Time Compressed Tag
----------- ------------ --------------- ---------- ---
DISK 00:00:06 08-DEC-16 YES TAG20161208T170624
List of Backup Pieces for backup set 2688 Copy #1
BP Key Pc# Status Piece Name
------- --- ----------- ----------
2691 1 AVAILABLE /u01/bak/sys_1crmvgkh_1_1.bak
2690 2 AVAILABLE /u01/bak/sys_1crmvgkh_2_1.bak
2693 3 AVAILABLE /u01/bak/sys_1crmvgkh_3_1.bak
2692 4 AVAILABLE /u01/bak/sys_1crmvgkh_4_1.bak
2695 5 AVAILABLE /u01/bak/sys_1crmvgkh_5_1.bak
2694 6 AVAILABLE /u01/bak/sys_1crmvgkh_6_1.bak
2697 7 AVAILABLE /u01/bak/sys_1crmvgkh_7_1.bak
2696 8 AVAILABLE /u01/bak/sys_1crmvgkh_8_1.bak
2699 9 AVAILABLE /u01/bak/sys_1crmvgkh_9_1.bak
2698 10 AVAILABLE /u01/bak/sys_1crmvgkh_10_1.bak
2700 11 AVAILABLE /u01/bak/sys_1crmvgkh_11_1.bak
BS Key Type LV Size Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
4415 Full 471.44M DISK 00:00:09 22-DEC-16
BP Key: 4417 Status: AVAILABLE Compressed: NO Tag: TAG20161222T093418
Piece Name: /opt/p2_1tro3jcq_1_1.bak
List of Datafiles in backup set 4415
File LV Type Ckp SCN Ckp Time Name
---- -- ---- ---------- --------- ----
1 Full 1113425 22-DEC-16 /opt/PROD2/system01.dbf
2 Full 1113425 22-DEC-16 /opt/PROD2/sysaux01.dbf
3 Full 1113425 22-DEC-16 /opt/PROD2/undotbs01.dbf
4 Full 1113425 22-DEC-16 /opt/PROD2/users01.dbf
RMAN> restore database from tag 'Q107';
Starting restore at 22-DEC-16
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=191 device type=DISK
channel ORA_DISK_1: starting datafile backup set restore
channel ORA_DISK_1: specifying datafile(s) to restore from backup set
channel ORA_DISK_1: restoring datafile 00001 to /opt/PROD2/system01.dbf
channel ORA_DISK_1: restoring datafile 00002 to /opt/PROD2/sysaux01.dbf
channel ORA_DISK_1: restoring datafile 00003 to /opt/PROD2/undotbs01.dbf
channel ORA_DISK_1: restoring datafile 00004 to /opt/PROD2/users01.dbf
channel ORA_DISK_1: reading from backup piece /u01/p1_full_19rmvges_1_1.bak
channel ORA_DISK_1: piece handle=/u01/p1_full_19rmvges_1_1.bak tag=Q107
channel ORA_DISK_1: restored backup piece 1
channel ORA_DISK_1: restore complete, elapsed time: 00:00:25
Finished restore at 22-DEC-16
RMAN> run{
set until time "to_date('2016-12-21 17:30:00','yyyy-mm-dd hh24:mi:ss')";
recover database;
}2> 3> 4>
executing command: SET until clause
Starting recover at 22-DEC-16
using channel ORA_DISK_1
starting media recovery
archived log for thread 1 with sequence 12 is already on disk as file /opt/arc/1_12_929193070.dbf
archived log for thread 1 with sequence 13 is already on disk as file /opt/arc/1_13_929193070.dbf
archived log for thread 1 with sequence 14 is already on disk as file /opt/arc/1_14_929193070.dbf
archived log for thread 1 with sequence 15 is already on disk as file /opt/arc/1_15_929193070.dbf
archived log for thread 1 with sequence 16 is already on disk as file /opt/arc/1_16_929193070.dbf
archived log for thread 1 with sequence 17 is already on disk as file /opt/arc/1_17_929193070.dbf
archived log for thread 1 with sequence 18 is already on disk as file /opt/arc/1_18_929193070.dbf
archived log for thread 1 with sequence 19 is already on disk as file /opt/arc/1_19_929193070.dbf
archived log for thread 1 with sequence 1 is already on disk as file /opt/arc/1_1_930580866.dbf
archived log for thread 1 with sequence 2 is already on disk as file /opt/arc/1_2_930580866.dbf
archived log for thread 1 with sequence 3 is already on disk as file /opt/arc/1_3_930580866.dbf
archived log for thread 1 with sequence 4 is already on disk as file /opt/arc/1_4_930580866.dbf
archived log for thread 1 with sequence 5 is already on disk as file /opt/arc/1_5_930580866.dbf
archived log for thread 1 with sequence 6 is already on disk as file /opt/arc/1_6_930580866.dbf
archived log for thread 1 with sequence 1 is already on disk as file /opt/arc/1_1_931094447.dbf
archived log file name=/opt/arc/1_12_929193070.dbf thread=1 sequence=12
archived log file name=/opt/arc/1_13_929193070.dbf thread=1 sequence=13
archived log file name=/opt/arc/1_14_929193070.dbf thread=1 sequence=14
archived log file name=/opt/arc/1_15_929193070.dbf thread=1 sequence=15
archived log file name=/opt/arc/1_16_929193070.dbf thread=1 sequence=16
archived log file name=/opt/arc/1_17_929193070.dbf thread=1 sequence=17
archived log file name=/opt/arc/1_18_929193070.dbf thread=1 sequence=18
archived log file name=/opt/arc/1_19_929193070.dbf thread=1 sequence=19
archived log file name=/opt/arc/1_1_930580866.dbf thread=1 sequence=1
archived log file name=/opt/arc/1_2_930580866.dbf thread=1 sequence=2
archived log file name=/opt/arc/1_3_930580866.dbf thread=1 sequence=3
archived log file name=/opt/arc/1_4_930580866.dbf thread=1 sequence=4
archived log file name=/opt/arc/1_5_930580866.dbf thread=1 sequence=5
archived log file name=/opt/arc/1_6_930580866.dbf thread=1 sequence=6
archived log file name=/opt/arc/1_1_931094447.dbf thread=1 sequence=1
media recovery complete, elapsed time: 00:00:38
Finished recover at 22-DEC-16
RMAN>
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>
List of Backups
===============
Key TY LV S Device Type Completion Time #Pieces #Copies Compressed Tag
------- -- -- - ----------- --------------- ------- ------- ---------- ---
2552 B F A DISK 08-DEC-16 1 1 NO Q107
2688 B F A DISK 08-DEC-16 11 1 YES TAG20161208T170624
4415 B F A DISK 22-DEC-16 1 1 NO TAG20161222T093418
RMAN> startup mount
Oracle instance started
database mounted
Total System Global Area 1068937216 bytes
Fixed Size 2260088 bytes
Variable Size 666895240 bytes
Database Buffers 394264576 bytes
Redo Buffers 5517312 bytes
RMAN> list backup of database;
List of Backup Sets
===================
BS Key Type LV Size Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
2552 Full 363.09M DISK 00:00:04 08-DEC-16
BP Key: 2565 Status: AVAILABLE Compressed: NO Tag: Q107
Piece Name: /u01/p1_full_19rmvges_1_1.bak
List of Datafiles in backup set 2552
File LV Type Ckp SCN Ckp Time Name
---- -- ---- ---------- --------- ----
1 Full 599192 08-DEC-16 /opt/PROD2/system01.dbf
2 Full 599192 08-DEC-16 /opt/PROD2/sysaux01.dbf
3 Full 599192 08-DEC-16 /opt/PROD2/undotbs01.dbf
4 Full 599192 08-DEC-16 /opt/PROD2/users01.dbf
BS Key Type LV Size Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
2688 Full 43.35M DISK 00:00:06 08-DEC-16
Keep: BACKUP_LOGS Until: FOREVER
List of Datafiles in backup set 2688
File LV Type Ckp SCN Ckp Time Name
---- -- ---- ---------- --------- ----
1 Full 599607 08-DEC-16 /opt/PROD2/system01.dbf
Backup Set Copy #1 of backup set 2688
Device Type Elapsed Time Completion Time Compressed Tag
----------- ------------ --------------- ---------- ---
DISK 00:00:06 08-DEC-16 YES TAG20161208T170624
List of Backup Pieces for backup set 2688 Copy #1
BP Key Pc# Status Piece Name
------- --- ----------- ----------
2691 1 AVAILABLE /u01/bak/sys_1crmvgkh_1_1.bak
2690 2 AVAILABLE /u01/bak/sys_1crmvgkh_2_1.bak
2693 3 AVAILABLE /u01/bak/sys_1crmvgkh_3_1.bak
2692 4 AVAILABLE /u01/bak/sys_1crmvgkh_4_1.bak
2695 5 AVAILABLE /u01/bak/sys_1crmvgkh_5_1.bak
2694 6 AVAILABLE /u01/bak/sys_1crmvgkh_6_1.bak
2697 7 AVAILABLE /u01/bak/sys_1crmvgkh_7_1.bak
2696 8 AVAILABLE /u01/bak/sys_1crmvgkh_8_1.bak
2699 9 AVAILABLE /u01/bak/sys_1crmvgkh_9_1.bak
2698 10 AVAILABLE /u01/bak/sys_1crmvgkh_10_1.bak
2700 11 AVAILABLE /u01/bak/sys_1crmvgkh_11_1.bak
BS Key Type LV Size Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
4415 Full 471.44M DISK 00:00:09 22-DEC-16
BP Key: 4417 Status: AVAILABLE Compressed: NO Tag: TAG20161222T093418
Piece Name: /opt/p2_1tro3jcq_1_1.bak
List of Datafiles in backup set 4415
File LV Type Ckp SCN Ckp Time Name
---- -- ---- ---------- --------- ----
1 Full 1113425 22-DEC-16 /opt/PROD2/system01.dbf
2 Full 1113425 22-DEC-16 /opt/PROD2/sysaux01.dbf
3 Full 1113425 22-DEC-16 /opt/PROD2/undotbs01.dbf
4 Full 1113425 22-DEC-16 /opt/PROD2/users01.dbf
RMAN> restore database from tag 'Q107';
Starting restore at 22-DEC-16
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=191 device type=DISK
channel ORA_DISK_1: starting datafile backup set restore
channel ORA_DISK_1: specifying datafile(s) to restore from backup set
channel ORA_DISK_1: restoring datafile 00001 to /opt/PROD2/system01.dbf
channel ORA_DISK_1: restoring datafile 00002 to /opt/PROD2/sysaux01.dbf
channel ORA_DISK_1: restoring datafile 00003 to /opt/PROD2/undotbs01.dbf
channel ORA_DISK_1: restoring datafile 00004 to /opt/PROD2/users01.dbf
channel ORA_DISK_1: reading from backup piece /u01/p1_full_19rmvges_1_1.bak
channel ORA_DISK_1: piece handle=/u01/p1_full_19rmvges_1_1.bak tag=Q107
channel ORA_DISK_1: restored backup piece 1
channel ORA_DISK_1: restore complete, elapsed time: 00:00:25
Finished restore at 22-DEC-16
RMAN> run{
set until time "to_date('2016-12-21 17:30:00','yyyy-mm-dd hh24:mi:ss')";
recover database;
}2> 3> 4>
executing command: SET until clause
Starting recover at 22-DEC-16
using channel ORA_DISK_1
starting media recovery
archived log for thread 1 with sequence 12 is already on disk as file /opt/arc/1_12_929193070.dbf
archived log for thread 1 with sequence 13 is already on disk as file /opt/arc/1_13_929193070.dbf
archived log for thread 1 with sequence 14 is already on disk as file /opt/arc/1_14_929193070.dbf
archived log for thread 1 with sequence 15 is already on disk as file /opt/arc/1_15_929193070.dbf
archived log for thread 1 with sequence 16 is already on disk as file /opt/arc/1_16_929193070.dbf
archived log for thread 1 with sequence 17 is already on disk as file /opt/arc/1_17_929193070.dbf
archived log for thread 1 with sequence 18 is already on disk as file /opt/arc/1_18_929193070.dbf
archived log for thread 1 with sequence 19 is already on disk as file /opt/arc/1_19_929193070.dbf
archived log for thread 1 with sequence 1 is already on disk as file /opt/arc/1_1_930580866.dbf
archived log for thread 1 with sequence 2 is already on disk as file /opt/arc/1_2_930580866.dbf
archived log for thread 1 with sequence 3 is already on disk as file /opt/arc/1_3_930580866.dbf
archived log for thread 1 with sequence 4 is already on disk as file /opt/arc/1_4_930580866.dbf
archived log for thread 1 with sequence 5 is already on disk as file /opt/arc/1_5_930580866.dbf
archived log for thread 1 with sequence 6 is already on disk as file /opt/arc/1_6_930580866.dbf
archived log for thread 1 with sequence 1 is already on disk as file /opt/arc/1_1_931094447.dbf
archived log file name=/opt/arc/1_12_929193070.dbf thread=1 sequence=12
archived log file name=/opt/arc/1_13_929193070.dbf thread=1 sequence=13
archived log file name=/opt/arc/1_14_929193070.dbf thread=1 sequence=14
archived log file name=/opt/arc/1_15_929193070.dbf thread=1 sequence=15
archived log file name=/opt/arc/1_16_929193070.dbf thread=1 sequence=16
archived log file name=/opt/arc/1_17_929193070.dbf thread=1 sequence=17
archived log file name=/opt/arc/1_18_929193070.dbf thread=1 sequence=18
archived log file name=/opt/arc/1_19_929193070.dbf thread=1 sequence=19
archived log file name=/opt/arc/1_1_930580866.dbf thread=1 sequence=1
archived log file name=/opt/arc/1_2_930580866.dbf thread=1 sequence=2
archived log file name=/opt/arc/1_3_930580866.dbf thread=1 sequence=3
archived log file name=/opt/arc/1_4_930580866.dbf thread=1 sequence=4
archived log file name=/opt/arc/1_5_930580866.dbf thread=1 sequence=5
archived log file name=/opt/arc/1_6_930580866.dbf thread=1 sequence=6
archived log file name=/opt/arc/1_1_931094447.dbf thread=1 sequence=1
media recovery complete, elapsed time: 00:00:38
Finished recover at 22-DEC-16
RMAN>
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/20747382/viewspace-2131176/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- 資料庫不完全恢復資料庫
- oracle資料庫不完全恢復Oracle資料庫
- Oracle Rman 資料庫的不完全恢復Oracle資料庫
- 使用bbed完成資料庫的不完全恢復資料庫
- 如何進行Oracle資料庫不完全恢復RBOracle資料庫
- 基於時間執行資料庫不完全恢復資料庫
- RMAN一次RMAN將資料庫不完全恢復資料庫
- 【資料庫資料恢復】SAP資料庫資料恢復案例資料庫資料恢復
- RMAN全庫【完全恢復/不完全恢復brief version】
- 寶塔資料庫恢復 mysql資料庫丟失恢復 mysql資料庫刪除庫恢復 寶塔mysql資料庫恢復資料庫MySql
- ORACLE資料庫基於時間點的不完全恢復Oracle資料庫
- Backup And Recovery User's Guide-執行不完全資料庫恢復-執行Cancel-Based不完全恢復GUIIDE資料庫
- 【資料庫資料恢復】Sql Server資料庫資料恢復案例資料庫資料恢復SQLServer
- 資料庫修復資料恢復資料庫資料恢復
- PG 資料庫的 表的不完全恢復的簡易方法資料庫
- 恢復資料庫資料庫
- 【資料庫資料恢復】透過恢復NDF檔案修復資料庫的資料恢復過程資料庫資料恢復
- 【資料庫資料恢復】如何恢復Oracle資料庫truncate表的資料資料庫資料恢復Oracle
- 【資料庫資料恢復】windows server下SqlServer資料庫的資料恢復資料庫資料恢復WindowsServerSQL
- BBED 修改oracle 資料檔案的 SCN 號來做資料庫不完全恢復。Oracle資料庫
- 使用恢復建議恢復資料庫資料庫
- PostgreSQL從入門到精通 - 第40講:資料庫不完全恢復SQL資料庫
- Backup And Recovery User's Guide-執行不完全資料庫恢復GUIIDE資料庫
- 【資料庫資料恢復】Oracle資料庫誤truncate table的資料恢復案例資料庫資料恢復Oracle
- 【資料庫資料恢復】oracle資料庫誤truncate table怎麼恢復資料?資料庫資料恢復Oracle
- 【資料庫資料恢復】誤truncate table的Oracle資料庫資料恢復方案資料庫資料恢復Oracle
- 伺服器資料恢復—透過拼接資料庫碎片恢復SqlServer資料庫資料的資料恢復案例伺服器資料恢復資料庫SQLServer
- 【資料庫資料恢復】MS SQL資料庫附加資料庫出錯怎麼恢復資料?資料庫資料恢復SQL
- 【Mysql】完全恢復與不完全恢復MySql
- 資料庫恢復方案資料庫
- RMAN恢復資料庫資料庫
- sybase資料庫恢復資料庫
- 【資料庫資料恢復】SqlServer資料庫無法讀取的資料恢復案例資料庫資料恢復SQLServer
- 資料庫資料恢復—NTFS分割槽損壞如何恢復SqlServer資料庫資料資料庫資料恢復SQLServer
- 【資料庫資料恢復】sql server資料庫連線失效的資料恢復案例資料庫資料恢復SQLServer
- 【資料庫資料恢復】linux系統下MYSQL資料庫資料恢復案例資料庫資料恢復LinuxMySql
- 【資料庫資料恢復】MongoDB資料庫檔案損壞的資料恢復案例資料庫資料恢復MongoDB
- 【資料庫資料恢復】Oracle資料庫ASM磁碟組掉線如何恢復資料?資料庫資料恢復OracleASM