반응형
1. Full backup 본으로 Recovery 수행
1) backup list 확인
RMAN> list backupset;
List of Backup Sets
===================
BS Key Type LV Size Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
9 Full 346.03M DISK 00:00:36 13-JUN-22
BP Key: 9 Status: AVAILABLE Compressed: YES Tag: TAG20220613T111152
Piece Name: /home/oracle/rman_backup/dbf_090vuovo_1_1_20220613
List of Datafiles in backup set 9
File LV Type Ckp SCN Ckp Time Name
---- -- ---- ---------- --------- ----
1 Full 1851194 13-JUN-22 /home/oracle/oradata/oracle12/system01.dbf
2 Full 1851194 13-JUN-22 /home/oracle/oradata/oracle12/TBS_IMSI01.dbf
3 Full 1851194 13-JUN-22 /home/oracle/oradata/oracle12/sysaux01.dbf
4 Full 1851194 13-JUN-22 /home/oracle/oradata/oracle12/undotbs01.dbf
5 Full 1851194 13-JUN-22 /home/oracle/oradata/oracle12/example01.dbf
6 Full 1851194 13-JUN-22 /home/oracle/oradata/oracle12/users01.dbf
BS Key Type LV Size Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
10 Full 1.03M DISK 00:00:01 13-JUN-22
BP Key: 10 Status: AVAILABLE Compressed: YES Tag: TAG20220613T111152
Piece Name: /home/oracle/rman_backup/dbf_0a0vup15_1_1_20220613
SPFILE Included: Modification time: 13-JUN-22
SPFILE db_unique_name: ORACLE12
Control File Included: Ckp SCN: 1851208 Ckp time: 13-JUN-22
2) Control file, Spfile, Datafile 모두 유실된 상태
3) shutdown abort
4) rman target /
-> RMAN접속
5) startup force nomount;
6) restore spfile from autobackup; [경로주고 직접파일을 먹여줌]
RMAN> restore spfile to '/app/oracle/product/12/db/dbs/initoracle12.ora' from '/home/oracle/rman_backup/dbf_0a0vup15_1_1_20220613'
2> ;
Starting restore at 13-JUN-22
using channel ORA_DISK_1
channel ORA_DISK_1: restoring spfile from AUTOBACKUP /home/oracle/rman_backup/dbf_0a0vup15_1_1_20220613
channel ORA_DISK_1: SPFILE restore from AUTOBACKUP complete
Finished restore at 13-JUN-22
7) restore controlfile from autobackup [경로주고 직접파일을 먹여줌]
RMAN> restore controlfile from autobackup
2> ;
Starting restore at 13-JUN-22
using channel ORA_DISK_1
recovery area destination: /app/oracle/fast_recovery_area
database name (or database unique name) used for search: ORACLE12
channel ORA_DISK_1: no AUTOBACKUPS found in the recovery area
AUTOBACKUP search with format "%F" not attempted because DBID was not set
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of restore command at 06/13/2022 14:50:45
RMAN-06172: no AUTOBACKUP found or specified handle is not a valid copy or piece
###############################################################################################
RMAN> restore controlfile from '/home/oracle/rman_backup/dbf_0a0vup15_1_1_20220613';
Starting restore at 13-JUN-22
using channel ORA_DISK_1
channel ORA_DISK_1: restoring control file
channel ORA_DISK_1: restore complete, elapsed time: 00:00:01
output file name=/home/oracle/oradata/oracle12/control01.ctl
Finished restore at 13-JUN-22
###############################################################################################
8) alter database mount;
9) restore database;
10) recover database;
-> 읽을수 있는 Archive log까지 모두 읽는다.
RMAN> recover database;
Starting recover at 13-JUN-22
using channel ORA_DISK_1
starting media recovery
archived log file name=/home/oracle/arch_dest/1_5_1106948742.dbf thread=1 sequence=5
archived log file name=/home/oracle/arch_dest/1_6_1106948742.dbf thread=1 sequence=6
archived log file name=/home/oracle/arch_dest/1_7_1106948742.dbf thread=1 sequence=7
archived log file name=/home/oracle/arch_dest/1_8_1106948742.dbf thread=1 sequence=8
archived log file name=/home/oracle/arch_dest/1_9_1106948742.dbf thread=1 sequence=9
archived log file name=/home/oracle/arch_dest/1_10_1106948742.dbf thread=1 sequence=10
archived log file name=/home/oracle/arch_dest/1_11_1106948742.dbf thread=1 sequence=11
unable to find archived log
archived log thread=1 sequence=12
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of recover command at 06/13/2022 14:56:47
RMAN-06054: media recovery requesting unknown archived log for thread 1 with sequence 12 and starting SCN of 1852306
11) alter database open resetlogs;
-> resetlogs로 DB기동해야한다.
반응형
'Database > Oracle' 카테고리의 다른 글
[ORACLE] ASM 접속 및 용량 조회 (0) | 2022.06.13 |
---|---|
[ORACLE] RAC SCAN (0) | 2022.06.13 |
[ORACLE] RMAN Recovery (Datafile 삭제되었을 경우) (0) | 2022.06.13 |
[ORACLE] RMAN Script example (0) | 2022.06.13 |
[ORACLE] RMAN 명령어 (0) | 2022.06.13 |