• OCP-1Z0-053-V13.02-573题


    573.Upon starting your database, you receive the following error:

    SQL> startup ORACLE instance started.

    Total System Global Area 171581440 bytes Fixed Size 1298640 bytes Variable Size

    146804528 bytes Database Buffers 20971520 bytes Redo Buffers 2506752 bytes Database mounted.

    ORA-00313: open failed for members of log group 1 of thread 1

    ORA-00312: online log 1 thread 1: '/oracle01/oradata/orcl/redo01.log' ORA-00312: online log 1 thread 1:

    '/oracle01/oradata/orcl/redo01a.log'

    You can choose from the following steps:

    Which is the correct order of these steps in this case?

    A. Restore the database datafiles.

    B. Issue the alter database clear unarchived logfile group 1 command.

    C. Issue the alter database open command.

    D. Issue the alter database open resetlogs command.

    E. Recover the database using point-in-time recovery.

    F. Issue the Startup Mount command to mount the database.

    G. Back up the database.

    H. a, f, e, d, g

    I. f, e, d

    J. f, b, c, g

    K. a, f, c

    L. The database cannot be recovered.

    Answer: C

    答案解析:

    参考:http://docs.oracle.com/cd/E11882_01/backup.112/e10642/osadvsce.htm#BRADV90053


    Losing an Inactive Online Redo Log Group

    If all members of an online redo log group with INACTIVE status are damaged, then the procedure depends on whether you can fix the media problem that damaged the inactive redo log group. If the failure is temporary, then fix the problem. The log writer can reuse the redo log group when required. If the failure is permanent, then the damaged inactive online redo log group eventually halts normal database operation. Reinitialize the damaged group manually by issuing the ALTER DATABASE CLEAR LOGFILE statement as described in this section.

    Clearing Inactive, Archived Redo

    You can clear an inactive redo log group when the database is open or closed. The procedure depends on whether the damaged group has been archived.

    To clear an inactive, online redo log group that has been archived:

    1. If the database is shut down, then start a new instance and mount the database:

      STARTUP MOUNT
    2. Reinitialize the damaged log group. For example, to clear redo log group 2, issue the following statement:

      ALTER DATABASE CLEAR LOGFILE GROUP 2;
    Clearing Inactive, Unarchived Redo

    Clearing a not-yet-archived redo log allows it to be reused without archiving it. This action makes backups unusable if they were started before the last change in the log, unless the file was taken offline before the first change in the log. Hence, if you need the cleared log file for recovery of a backup, then you cannot recover that backup. Clearing a not-yet-archived-redo-log, prevents complete recovery from backups due to the missing log.

    To clear an inactive, online redo log group that has not been archived:

    1. If the database is shut down, then start a new instance and mount the database:

      SQL> STARTUP MOUNT
    2. Clear the log using the UNARCHIVED keyword.

      For example, to clear log group 2, issue the following SQL statement:

      SQL> ALTER DATABASE CLEAR UNARCHIVED LOGFILE GROUP 2;

      If there is an offline data file that requires the cleared log to bring it online, then the keywords UNRECOVERABLE DATAFILE are required. The data file must be dropped because the redo logs necessary to bring the data file online are being cleared, and there is no copy of it. For example, enter:

      SQL> ALTER DATABASE CLEAR UNARCHIVED LOGFILE GROUP 2 UNRECOVERABLE DATAFILE;
    3. Immediately back up all data files in the database with an operating system utility, so that you have a backup you can use for complete recovery without relying on the cleared log group. For example, enter:

      % cp /disk1/oracle/dbs/*.dbf /disk2/backup
    4. Back up the database's control file with the ALTER DATABASE statement. For example, enter:

      SQL> ALTER DATABASE BACKUP CONTROLFILE TO '/oracle/dbs/cf_backup.f';
    Failure of CLEAR LOGFILE Operation

    The ALTER DATABASE CLEAR LOGFILE statement can fail with an I/O error due to media failure when it is not possible to:

    • Relocate the redo log file onto alternative media by re-creating it under the currently configured redo log file name

    • Reuse the currently configured log file name to re-create the redo log file because the name itself is invalid or unusable (for example, due to media failure)

    In these cases, the ALTER DATABASE CLEAR LOGFILE statement (before receiving the I/O error) would have successfully informed the control file that the log was being cleared and did not require archiving. The I/O error occurred at the step in which the CLEAR LOGFILE statement attempted to create the new redo log file and write zeros to it. This fact is reflected in V$LOG.CLEARING_CURRENT.


     
  • 相关阅读:
    斯坦福CS231n—深度学习与计算机视觉----学习笔记 课时10
    斯坦福CS231n—深度学习与计算机视觉----学习笔记 课时8&&9
    斯坦福CS231n—深度学习与计算机视觉----学习笔记 课时7
    斯坦福CS231n—深度学习与计算机视觉----学习笔记 课时6
    sprintf()函数用法
    openssl生成签名与验证签名
    PHP_EOL换行 与 base64编码
    grep配置颜色显示
    curl发送json格式数据
    sublime text3作为php开发IDE
  • 原文地址:https://www.cnblogs.com/hzcya1995/p/13316113.html
Copyright © 2020-2023  润新知