backup corrupted datafile as copy check V$COPY_CORRUPTION

 

Physical datafile block corrupted.Then backup the corrupted datafile:

dba:bk $ rman target /


connected to target database: ORCLA (DBID=3151536598)

RMAN> run {  
2> set maxcorrupt for datafile 17 to 3;
3> backup as copy datafile 17 format '/tmp/valen/bk/corrupt_df_%f_image_%u.bak';       
4> }

executing command: SET MAX CORRUPT
using target database control file instead of recovery catalog

Starting backup at 27-APR-20
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=139 instance=orcla1 device type=DISK
channel ORA_DISK_1: starting datafile copy
input datafile file number=00017 name=+DATA/ORCLA/A441009DCA397D0CE0531136D60A11F0/DATAFILE/undotbs1.357.1038786101
output file name=/tmp/valen/bk/corrupt_df_17_image_1ouullcs.bak tag=TAG20200427T033804 RECID=29 STAMP=1038800288
channel ORA_DISK_1: datafile copy complete, elapsed time: 00:00:07
Finished backup at 27-APR-20

Starting Control File and SPFILE Autobackup at 27-APR-20
piece handle=+DATA/ORCLA/AUTOBACKUP/2020_04_27/s_1038800292.386.1038800293 comment=NONE
Finished Control File and SPFILE Autobackup at 27-APR-20

RMAN> exit



SQL> set lines 1000
SQL> select * from v$copy_corruption;

     RECID      STAMP COPY_RECID COPY_STAMP      FILE#     BLOCK#     BLOCKS CORRUPTION_CHANGE# MAR CORRUPTIO     CON_ID
---------- ---------- ---------- ---------- ---------- ---------- ---------- ------------------ --- --------- ----------
         1 1038800288         29 1038800288         17         11          1                  0 NO  CORRUPT            0

 

 

https://docs.oracle.com/html/E10643_07/rcmsynta2024.htm

https://docs.oracle.com/cd/B14117_01/server.101/b10755/dynviews_1051.htm

V$COPY_CORRUPTION  :

 

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章