Dallas Time: Friday 11th of April 2025 03:12:42 AM

Warning: include(../includedfiles/menu.php): failed to open stream: No such file or directory in /hermes/bosnacweb09/bosnacweb09aq/b1983/sl.lianamon/public_html/dbainfo/notes/db/header.php on line 32

Warning: include(): Failed opening '../includedfiles/menu.php' for inclusion (include_path='.:/usr/share/php') in /hermes/bosnacweb09/bosnacweb09aq/b1983/sl.lianamon/public_html/dbainfo/notes/db/header.php on line 32

home

Rman

recoverTargetdb Cloning A Database Using Rman
Backup and Recovery Plan Using RMAN

 

backup the recovery catalog Rewind a database with flashback database

 

View
V$RMAN_BACKUP_JOB_DETAILS

 

New to 11gR2

DUPLICATE Database Command Enhancements
1. No Target Database
2. No Target Database or Recovery Catalog


Users can DUPLICATE a database without connecting to a target database.
The only requirements to this operation are a connection to a catalog and an auxiliary
 database. 


This new functionality is useful when the target database is not always available.

 

Users can also DUPLICATE a database without connecting to a target database and a recovery catalog
   In this particular scenario, the only requirement is that you
must provide a disk backup location where RMAN can find all the backups,
datafile copies, archived logs, and control file copies for database duplication. 


This database duplication enhancement is helpful when it is not possible to connect to
the target database and the recovery catalog.

When duplicating from a target database, checks are in place to see if any excluded
tablespaces contain SYS-owned objects, materialized views, and identifies
tablespaces that are not self-contained before starting any duplication operations.

 

To query details about past and current RMAN jobs:
V$RMAN_BACKUP_JOB_DETAILS
COL STATUS FORMAT a9
COL hrs FORMAT 999.99
    
SELECT SESSION_KEY
       , INPUT_TYPE
       , STATUS
       , TO_CHAR(START_TIME,'mm/dd/yy hh24:mi') start_time
       , TO_CHAR(END_TIME,'mm/dd/yy hh24:mi') end_time
       ,ELAPSED_SECONDS/3600 hrs
FROM V$RMAN_BACKUP_JOB_DETAILS
ORDER BY SESSION_KEY

 

Query the V$RMAN_BACKUP_JOB_DETAILS view for the rate of backup jobs
V$RMAN_BACKUP_JOB_DETAILS
COL in_sec FORMAT a10
COL out_sec FORMAT a10
COL TIME_TAKEN_DISPLAY FORMAT a10


SELECT SESSION_KEY
       ,OPTIMIZED
       ,COMPRESSION_RATIO
       ,INPUT_BYTES_PER_SEC_DISPLAY in_sec
       ,OUTPUT_BYTES_PER_SEC_DISPLAY out_sec
       ,TIME_TAKEN_DISPLAY
FROM V$RMAN_BACKUP_JOB_DETAILS
ORDER BY SESSION_KEY;

 

Query the V$RMAN_BACKUP_JOB_DETAILS view for the size of the backups in an
 
COL in_size FORMAT a10
COL out_size FORMAT a10


SELECT SESSION_KEY,
       INPUT_TYPE,
       COMPRESSION_RATIO,
       INPUT_BYTES_DISPLAY in_size,
       OUTPUT_BYTES_DISPLAY out_size
FROM V$RMAN_BACKUP_JOB_DETAILS
ORDER BY SESSION_KEY;

 

Rewind a database with flashback database

To rewind a database with Flashback Database:

         1. Start RMAN and connect to a target database.
         2. Ensure that the database is in a mounted state.
             The following commands shut down and then mount the database:
         
              SHUTDOWN IMMEDIATE;
              STARTUP MOUNT;
         3. Run the FLASHBACK DATABASE command.
         
            The following examples illustrate different forms of the command:
            
            FLASHBACK DATABASE TO SCN 861150;
            FLASHBACK DATABASE
            TO RESTORE POINT BEFORE_CHANGES;
            FLASHBACK DATABASE TO TIME "TO_DATE('06/20/07','MM/DD/YY')";
         
         4. After performing the Flashback Database, open the database read-only in
         
            SQL*Plus and run some queries to verify the database contents.
            Open the database read-only as follows:
         
            SQL "ALTER DATABASE OPEN READ ONLY";
         
         5. If satisfied with the results, then issue the following sequence of commands to
             shut down and then open the database:
             SHUTDOWN IMMEDIATE;
             STARTUP MOUNT;
             ALTER DATABASE OPEN RESETLOGS;