救回已經刪除的 table ( Recover Manager )

2016-08-10 13:57

RMAN> list backup of database;


List of Backup Sets
===================


BS Key  Type LV Size       Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
56      Full    1.47G      DISK        00:00:05     09-AUG-16
        BP Key: 56   Status: AVAILABLE  Compressed: NO  Tag: TAG20160809T171101
        Piece Name: /home/oracle/rman/CHEN_2crcr6p6_1_1_CHENxxxx_20160809
  List of Datafiles in backup set 56
  File LV Type Ckp SCN    Ckp Time  Name
  ---- -- ---- ---------- --------- ----
  1       Full 18589931   09-AUG-16 /opt/oracle/oradata/chen/system01.dbf
  2       Full 18589931   09-AUG-16 /opt/oracle/oradata/chen/sysaux01.dbf
  3       Full 18589931   09-AUG-16 /opt/oracle/oradata/chen/undotbs01.dbf
  4       Full 18589931   09-AUG-16 /opt/oracle/oradata/chen/users01.dbf
  5       Full 18589931   09-AUG-16

BS Key  Type LV Size       Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
60      Full    439.03M    DISK        00:00:02     10-AUG-16
        BP Key: 60   Status: AVAILABLE  Compressed: NO  Tag: TAG20160810T092711
        Piece Name: /home/oracle/rman/CHEN_2hrcsvvg_1_1_CHENxxxx_20160810
  List of Datafiles in backup set 60
  File LV Type Ckp SCN    Ckp Time  Name
  ---- -- ---- ---------- --------- ----
  2       Full 18689950   10-AUG-16 /opt/oracle/oradata/chen/sysaux01.dbf
  3       Full 18689950   10-AUG-16 /opt/oracle/oradata/chen/undotbs01.dbf

BS Key  Type LV Size       Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
61      Full    1.01G      DISK        00:00:04     10-AUG-16
        BP Key: 61   Status: AVAILABLE  Compressed: NO  Tag: TAG20160810T092711
        Piece Name: /home/oracle/rman/CHEN_2grcsvvg_1_1_CHENxxxx_20160810
  List of Datafiles in backup set 61
  File LV Type Ckp SCN    Ckp Time  Name
  ---- -- ---- ---------- --------- ----
  1       Full 18689949   10-AUG-16 /opt/oracle/oradata/chen/system01.dbf
  4       Full 18689949   10-AUG-16 /opt/oracle/oradata/chen/users01.dbf
  5       Full 18689949   10-AUG-16

BS Key  Type LV Size       Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
70      Full    1.30M      DISK        00:00:00     10-AUG-16
        BP Key: 70   Status: AVAILABLE  Compressed: NO  Tag: TAG20160810T142257
        Piece Name: /home/oracle/rman/CHEN_2urctha1_1_1_CHENxxxx_20160810
  List of Datafiles in backup set 70
  File LV Type Ckp SCN    Ckp Time  Name
  ---- -- ---- ---------- --------- ----
  4       Full 37477601   10-AUG-16 /opt/oracle/oradata/chen/users01.dbf

BS Key  Type LV Size       Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
71      Full    497.03M    DISK        00:00:03     10-AUG-16
        BP Key: 71   Status: AVAILABLE  Compressed: NO  Tag: TAG20160810T142257
        Piece Name: /home/oracle/rman/CHEN_2trctha1_1_1_CHENxxxx_20160810
  List of Datafiles in backup set 71
  File LV Type Ckp SCN    Ckp Time  Name
  ---- -- ---- ---------- --------- ----
  5       Full 37477600   10-AUG-16 /opt/oracle/oradata/chen/test_dbf

BS Key  Type LV Size       Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
72      Full    439.59M    DISK        00:00:04     10-AUG-16
        BP Key: 72   Status: AVAILABLE  Compressed: NO  Tag: TAG20160810T142257
        Piece Name: /home/oracle/rman/CHEN_2srctha1_1_1_CHENxxxx_20160810
  List of Datafiles in backup set 72
  File LV Type Ckp SCN    Ckp Time  Name
  ---- -- ---- ---------- --------- ----
  2       Full 37477599   10-AUG-16 /opt/oracle/oradata/chen/sysaux01.dbf

BS Key  Type LV Size       Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
73      Full    592.59M    DISK        00:00:05     10-AUG-16
        BP Key: 73   Status: AVAILABLE  Compressed: NO  Tag: TAG20160810T142257
        Piece Name: /home/oracle/rman/CHEN_2rrctha1_1_1_CHENxxxx_20160810
  List of Datafiles in backup set 73
  File LV Type Ckp SCN    Ckp Time  Name
  ---- -- ---- ---------- --------- ----
  1       Full 37477598   10-AUG-16 /opt/oracle/oradata/chen/system01.dbf

BS Key  Type LV Size       Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
74      Full    1.02G      DISK        00:00:06     10-AUG-16
        BP Key: 74   Status: AVAILABLE  Compressed: NO  Tag: TAG20160810T142257
        Piece Name: /home/oracle/rman/CHEN_2qrctha1_1_1_CHENxxxx_20160810
  List of Datafiles in backup set 74
  File LV Type Ckp SCN    Ckp Time  Name
  ---- -- ---- ---------- --------- ----
  3       Full 37477597   10-AUG-16 /opt/oracle/oradata/chen/undotbs01.dbf

RMAN> recover tablespace test_tbs until scn 37477600;

Starting recover at 10-AUG-16
using channel ORA_DISK_1
RMAN-05026: WARNING: presuming following set of tablespaces applies to specified point-in-time

List of tablespaces expected to have UNDO segments
Tablespace SYSTEM
Tablespace UNDOTBS1

Creating automatic instance, with SID='vuDC'

initialization parameters used for automatic instance:
db_name=CHEN
db_unique_name=vuDC_tspitr_CHEN
compatible=11.2.0.0.0
db_block_size=8192
db_files=200
sga_target=280M
processes=50
#No auxiliary destination in use
#No auxiliary parameter file used


starting up automatic instance CHEN

Oracle instance started

Total System Global Area     292278272 bytes

Fixed Size                     2212736 bytes
Variable Size                100666496 bytes
Database Buffers             184549376 bytes
Redo Buffers                   4849664 bytes
Automatic instance created
Running TRANSPORT_SET_CHECK on recovery set tablespaces
TRANSPORT_SET_CHECK completed successfully

Removing automatic instance
shutting down automatic instance
Oracle instance shut down
Automatic instance removed
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of recover command at 08/10/2016 14:49:52
RMAN-05002: aborting Tablespace Point-in-Time Recovery
RMAN-05517: tempfile /opt/oracle/oradata/chen/temp01.dbf conflicts with file used by target database
RMAN-05001: auxiliary file name /opt/oracle/oradata/chen/sysaux01.dbf conflicts with a file used by the target database
RMAN-05001: auxiliary file name /opt/oracle/oradata/chen/undotbs01.dbf conflicts with a file used by the target database
RMAN-05001: auxiliary file name /opt/oracle/oradata/chen/system01.dbf conflicts with a file used by the target database