Recovery File Structures   «Prev  Next»
Lesson 12

Oracle Database File Components Conclusion

In this module we learned the basic Oracle database file components that relate to your backup and recovery strategy. This information extends what we learned about the Oracle instance. By now you should be comfortable with the following:
In the context of an "Oracle 23c instance", the following terms relate to the physical and logical management of the database, particularly with respect to data integrity, recovery, and ongoing instance operations:
  1. Oracle Control Files
    • Definition: A control file is a critical binary file that records the structure and state of the Oracle database.
    • Contents:
      • Database name and ID
      • Names and locations of datafiles and redo log files
      • Tablespace information
      • Checkpoint data
      • Backup information (e.g., RMAN)
      • Archive log history
    • In Oracle 23c: Control files are automatically multiplexed to prevent single points of failure. Oracle recommends having at least two control files on different physical devices.
    • Location: Defined by the initialization parameter CONTROL_FILES.
  2. Redo Log Files
    • Definition: Redo log files are transaction journals that capture all changes made to the database, both committed and uncommitted.
    • Usage: Essential for instance recovery in case of crash or power failure.
    • Structure:
      • Stored in log groups; each group contains one or more members (copies).
      • Managed via views like V$LOG and V$LOGFILE.
    • In Oracle 23c:
      • Still part of the core recovery architecture.
      • More advanced redo transport and logging optimizations exist for Oracle Data Guard and sharded databases.
  3. Archive Log Files
    • Definition: These are offline copies of filled redo log files, created when the database is in ARCHIVELOG mode.
    • Purpose:
      • Enable point-in-time recovery.
      • Required for RMAN backups, Data Guard replication, and logical standby.
    • Location: Controlled by the LOG_ARCHIVE_DEST_n parameters.
    • Management: Use views like V$ARCHIVED_LOG to monitor.
    • In Oracle 23c:
      • Integration with Snapshot Carousel and autonomous backups.
      • Compression and encryption options for archived logs are enhanced.

  • Checkpoint Processing
    • Definition: A checkpoint is the process of writing all dirty buffers in the buffer cache to datafiles and updating the control file and datafile headers with the checkpoint SCN (System Change Number).
    • Purpose:
      • Ensures database consistency.
      • Reduces instance recovery time.
    • Triggered by:
      • Log switches
      • Timed intervals
      • Manual commands (ALTER SYSTEM CHECKPOINT)
    • In Oracle 23c:
      • Checkpoint performance is influenced by parameters like FAST_START_MTTR_TARGET and DB_WRITER_PROCESSES.
  • How to Determine the Current State and Structure of Your Database
    • a. Database State and Status
      • V$INSTANCE: Shows instance name, status, database role.
      • V$DATABASE: Shows database name, open mode, archive log mode.
      • V$SESSION: Lists all sessions and states.
    • b. Datafile and Tablespace Structure
      • DBA_DATA_FILES, V$DATAFILE: Lists all datafiles.
      • DBA_TABLESPACES: Shows tablespace names and properties.
    • c. Control and Redo Log Information
      • V$CONTROLFILE: Lists control file paths.
      • V$LOG, V$LOGFILE: Shows redo log groups and members.
      • V$ARCHIVED_LOG: Provides info about archived logs.
    • d. RMAN Reports
      • Use RMAN commands like:
        RMAN> REPORT SCHEMA;
        RMAN> LIST BACKUP;
        

  • e. SQL*Plus / SQL Developer Diagnostic Queries
    SELECT name, open_mode, log_mode FROM v$database;
    SELECT status FROM v$instance;
    SELECT group#, status, archived, sequence# FROM v$log;
    

  • Management of redo and archive log files is covered in more detail in a subsequent module. Understanding the basics of why and how some of these Oracle processes work will allow you to make more intelligent decisions when creating your backup and recovery strategy.
    If you would like, you can review the init.ora parameters that were covered up to this point in the table below.

    Generate an image summarizing the concepts from the previous prompt.
    Oracle Instance Sum
    Oracle Instance Summary

    init.ora Parameters

    Init.ora parameter Description
    LARGE_POOL_SIZE This is how you create the Large Pool. When the Instance starts, it allocates the requested memory in the SGA.
    LARGE_POOL_MIN_ALLOC This is the smallest chunk that can be allocated.
    ARCH_IO_SLAVES This is the number of I/O slaves used for log archiving.
    BACKUP_DISK_IO_SLAVES This is the number of I/O slaves used by RMAN for copy, backup, and restore.
    BACKUP_TAPE_IO_SLAVES If True, then one I/O slave is used to perform asynchronous I/O to and from tape when doing an RMAN backup and restore.
    LOG_ARCHIVE_DEST This parameter indicates where the archive log files will be written.
    LOG_CHECKPOINT_INTERVAL This parameter causes a checkpoint when the specified number of OS blocks have been written to the redo log files since the last checkpoint.
    LOG_CHECKPOINT_TIMEOUT This parameter causes a checkpoint when the specified number of seconds has elapsed since the last checkpoint.
    USER_DUMP_DEST This is the directory that contains the output from your trace commands.

    Database Installation - Quiz

    Click the Quiz link below to complete a module wrap-up quiz. Database Installation - Quiz

    Document Database Installation - Exercise

    Click the Exercise link below to complete this module's Troubleshooter.
    Document Database Installation - Exercise
    The next module gives an overview of archivelog and noarchivelog.

    SEMrush Software