zoukankan      html  css  js  c++  java
  • OCP-1Z0-053-V12.02-323题

     323.What is the correct order of the following commands if you wanted to restore datafile 4, which was

    accidentally removed from the file system?

    A. sql 'alter database datafile 4 online';

    B. restore datafile 4;

    C. recover datafile 4;

    D. sql 'alter database datafile 4 offline';

    E. startup

    F. shutdown

    G. a, c, b, d

    H. d, b, c, a

    I. f, d, b, c, a, e

    J. c, a, b, d, f

    K. a, b, d, e

    Answer: B

    答案解析:

    此题的选项有点问题,故从另一套找来正确的题。

    按题意:数据文件4不小心被删除,现在需要恢复,以下是恢复步骤:

    1、实验之前需要先备份:

    RMAN> backup datafile 4;
     
    Starting backup at 23-SEP-13
    using channel ORA_DISK_1
    channel ORA_DISK_1: starting full datafile backup set
    channel ORA_DISK_1: specifying datafile(s) in backup set
    input datafile file number=00004 name=/u01/app/oracle/oradata/test0910/users01.dbf
    channel ORA_DISK_1: starting piece 1 at 23-SEP-13
    channel ORA_DISK_1: finished piece 1 at 23-SEP-13
    piece handle=/u01/app/oracle/fast_recovery_area/TEST0910/backupset/2013_09_23/o1_mf_nnndf_TAG20130923T100457_940ln9o6_.bkp tag=TAG20130923T100457 comment=NONE
    channel ORA_DISK_1: backup set complete, elapsed time: 00:00:01
    Finished backup at 23-SEP-13
     
    2、模拟不小心删除
    [oracle@rtest test0910]$ rm /u01/app/oracle/oradata/test0910/users01.dbf
     
    3、开始恢复
    RMAN> sql 'alter database datafile 4 offline';
     
    using target database control file instead of recovery catalog
    sql statement: alter database datafile 4 offline
     
    RMAN> restore datafile 4;
     
    Starting restore at 23-SEP-13
    allocated channel: ORA_DISK_1
    channel ORA_DISK_1: SID=224 device type=DISK
     
    channel ORA_DISK_1: starting datafile backup set restore
    channel ORA_DISK_1: specifying datafile(s) to restore from backup set
    channel ORA_DISK_1: restoring datafile 00004 to /u01/app/oracle/oradata/test0910/users01.dbf
    channel ORA_DISK_1: reading from backup piece /u01/app/oracle/fast_recovery_area/TEST0910/backupset/2013_09_23/o1_mf_nnndf_TAG20130923T100457_940ln9o6_.bkp
    channel ORA_DISK_1: piece handle=/u01/app/oracle/fast_recovery_area/TEST0910/backupset/2013_09_23/o1_mf_nnndf_TAG20130923T100457_940ln9o6_.bkp tag=TAG20130923T100457
    channel ORA_DISK_1: restored backup piece 1
    channel ORA_DISK_1: restore complete, elapsed time: 00:00:01
    Finished restore at 23-SEP-13
     
    RMAN> recover datafile 4;
     
    Starting recover at 23-SEP-13
    using channel ORA_DISK_1
     
    starting media recovery
    media recovery complete, elapsed time: 00:00:01
     
    Finished recover at 23-SEP-13
     
    RMAN> sql 'alter database datafile 4 online';
     
    sql statement: alter database datafile 4 online
     
  • 相关阅读:
    【Redis】简介与安装
    【JAVA】 Java 连接池的工作原理
    【异常】ORA-01536: space quota exceeded for tablespace
    【Oracle】Oracle 序列步长问题
    【ORACLE】常用脚本
    【ORACLE】特殊的NULL
    【JAVA】Runtime
    【JAVA】Calendar
    出现脚本错误或者未正确调用 Page()
    小程序出现 “2 not found” 解决方案
  • 原文地址:https://www.cnblogs.com/hzcya1995/p/13317193.html
Copyright © 2011-2022 走看看