½Ã³ª¸®¿À12: ºÒ¿ÏÀüº¹±¸-Time Based: ½Ç¼ö·Î DropÇÑ tableº¹±¸
ÀÛ¼ºÀÚ °ü¸®ÀÚ ÀÛ¼º½Ã°£ 2003-07-24 13:48:25
 

SQL> !date
2003. 07. 24. (¸ñ) 11:52:02 KST

1) ½Ç¼ö·Î tableÀ» DropÇÏ¿´´Ù¸é,

SQL>
SQL>
SQL> drop table hr.emphist cascade constraints;

Table dropped.

SQL> select * from hr.emphist;
select * from hr.emphist
                *
ERROR at line 1:
ORA-00942: table or view does not exist


SQL> shutdown immediate;

2) Recovery ¼öÇà

SQL> !cp $HOME/ONBACKUP/*.dbf $HOME/oradata/HUMAN/
Áß¿äÇÑ TableÀ̹ǷΠDropµÈ ½ÃÁ¡ Á÷ÀüÀ¸·Î DBÀüü¸¦ µÇµ¹¸°´Ù.

SQL> startup
ORACLE instance started.

Total System Global Area                          235999352 bytes
Fixed Size                                          450680 bytes
Variable Size                                    201326592 bytes
Database Buffers                                  33554432 bytes
Redo Buffers                                        667648 bytes
Database mounted.
ORA-01113: file 1 needs media recovery
ORA-01110: data file 1: '/home/human/oradata/HUMAN/system01.dbf'

SQL> set autorecovery on
SQL> recover database until time '2003-07-24:11:52:02'
....
Log applied.
Media recovery complete.

SQL> select * from v$log;

    GROUP#    THREAD#  SEQUENCE#      BYTES    MEMBERS ARC STATUS          FIRST_CHANGE# FIRST_TIM
---------- ---------- ---------- ---------- ---------- --- ---------------- ------------- ---------
        1          1        40  104857600          2 YES INACTIVE                825618 24-JUL-03
        2          1        41  104857600          2 NO  CURRENT                825622 24-JUL-03

SQL> alter database open resetlogs;

Database altered.

SQL> select * from v$log;

    GROUP#    THREAD#  SEQUENCE#      BYTES    MEMBERS ARC STATUS          FIRST_CHANGE# FIRST_TIM
---------- ---------- ---------- ---------- ---------- --- ---------------- ------------- ---------
        1          1          0  104857600          2 YES UNUSED                0
        2          1          1  104857600          2 NO  CURRENT                825651 24-JUL-03


3) log sequence number °¡ Reset µÇ¾úÀ¸¹Ç·Î  Whole-OlinebackupÀ» ¼öÇà

SQL> !rm $HOME/arch/log/*

SQL> @LABS/onlinebackup.sql


¸ñ·Ï | ÀÔ·Â | ¼öÁ¤ | ´äº¯ | »èÁ¦