※ 필수 파일
1. 닫힌 백업한 파일중 복원시킬 데이터 파일 or 열린 백업한 파일중 복원시킬 데이터 파일
2. 백업이후 생성된 아카이브 로그파일
=======================================================================================
SQL> col Datafile format a45
SQL> select v$tablespace.name, v$datafile.name from v$tablespace, v$datafile
2 where v$tablespace.TS# = v$datafile.TS#;
NAME NAME
--------------------------------------------- ---------------------------------------------
SYSTEM /oracle/oradata/ora10g/system01.dbf
UNDOTBS1 /oracle/oradata/ora10g/undotbs01.dbf
SYSAUX /oracle/oradata/ora10g/sysaux01.dbf
USERS /oracle/oradata/ora10g/users01.dbf
EXAMPLE /oracle/oradata/ora10g/example01.dbf
SQL> !rm /oracle/oradata/ora10g/system01.dbf
SQL> connect scott/tiger
ERROR:
ORA-00604: error occurred at recursive SQL level 2
ORA-01116: error in opening database file 1
ORA-01110: data file 1: '/oracle/oradata/ora10g/system01.dbf'
ORA-27041: unable to open file
Linux Error: 2: No such file or directory
Additional information: 3
Warning: You are no longer connected to ORACLE.
SQL> connect /as sysdba
Connected.
SQL> shutdown immediate
ORA-00604: error occurred at recursive SQL level 1
ORA-01116: error in opening database file 1
ORA-01110: data file 1: '/oracle/oradata/ora10g/system01.dbf'
ORA-27041: unable to open file
Linux Error: 2: No such file or directory
Additional information: 3
SQL> connect / as sysdba
Connected.
SQL> shutdown abort
ORACLE instance shut down.
SQL> startup mount
ORA-32004: obsolete and/or deprecated parameter(s) specified
ORACLE instance started.
Total System Global Area 167772160 bytes
Fixed Size 1218316 bytes
Variable Size 96471284 bytes
Database Buffers 67108864 bytes
Redo Buffers 2973696 bytes
Database mounted.
SQL> col tablespace_name format a15
SQL> col name format a45
SQL> col error format a30
SQL> select h.tablespace_name, d.name, h.error
2 from v$datafile d, v$datafile_header h
3 where d.file# = h.file#;
TABLESPACE_NAME NAME ERROR
--------------- --------------------------------------------- ------------------------------
/oracle/oradata/ora10g/system01.dbf FILE NOT FOUND
UNDOTBS1 /oracle/oradata/ora10g/undotbs01.dbf
SYSAUX /oracle/oradata/ora10g/sysaux01.dbf
USERS /oracle/oradata/ora10g/users01.dbf
EXAMPLE /oracle/oradata/ora10g/example01.dbf
SQL> !cp /backup/close/ora10g/system01.dbf /oracle/oradata/ora10g/
혹은
SQL> !cp /backup/open/ora10g/system01.dbf /oracle/oradata/ora10g/
SQL> set autorecovery on
SQL> recover datafile '/oracle/oradata/ora10g/system01.dbf';
ORA-00279: change 4194796 generated at 11/01/2006 11:05:15 needed for thread 1
ORA-00289: suggestion : /oracle/flash_recovery_area/ORA10G/archivelog/2006_11_16/o1_mf_1_121_%u_.arc
ORA-00280: change 4194796 for thread 1 is in sequence #121
ORA-00279: change 4196859 generated at 11/03/2006 17:00:47 needed for thread 1
ORA-00289: suggestion : /oracle/flash_recovery_area/ORA10G/archivelog/2006_11_16/o1_mf_1_122_%u_.arc
ORA-00280: change 4196859 for thread 1 is in sequence #122
ORA-00278: log file '/oracle/flash_recovery_area/ORA10G/archivelog/2006_11_03/o1_mf_1_121_2noxshkx_.arc' no longer
needed for this recovery
.
.
.
.
ORA-00279: change 5178026 generated at 11/15/2006 03:12:47 needed for thread 1
ORA-00289: suggestion : /oracle/flash_recovery_area/ORA10G/archivelog/2006_11_16/o1_mf_1_155_%u_.arc
ORA-00280: change 5178026 for thread 1 is in sequence #155
ORA-00278: log file '/backup/archive2/1_154_601220550.arc' no longer needed for this recovery
Log applied.
Media recovery complete.
SQL> alter database open;
Database altered.
SQL> select h.tablespace_name, d.name, h.error
2 from v$datafile d, v$datafile_header h
3 where d.file# = h.file#;
TABLESPACE_NAME NAME ERROR
--------------- --------------------------------------------- ------------------------------
SYSTEM /oracle/oradata/ora10g/system01.dbf
UNDOTBS1 /oracle/oradata/ora10g/undotbs01.dbf
SYSAUX /oracle/oradata/ora10g/sysaux01.dbf
USERS /oracle/oradata/ora10g/users01.dbf
EXAMPLE /oracle/oradata/ora10g/example01.dbf
SQL>
닫힌상태 - 임의데이터 - 완전 복구(system 손상)
|
2006.11.15 14:21:02
|
2006.11.15 14:21:02
|
857
|
Aiden
Total of Attached file
0.00 Bytes of 0 files
2008.12.12
2006.12.20
2006.11.17
2006.11.16
2006.11.16
2006.11.15
2006.11.02
2006.11.02
2006.10.31
2006.10.30
2006.10.30