Thursday 9 February 2012

Creating RMAN Recovery Catalog

Creating RMAN Recovery Catalog::


Overview:
This article is a comprehensive guide for Creation of RMAN Recovery Catalog.
RMAN can be used either with or without a recovery catalog. A recovery catalog is a schema stored in a database that tracks backups and stores scripts for use in RMAN backup and recovery situations. Generally, RMAN catalog schema be placed on a server separate from the main servers.
Please do keep in mind that this article should not be considered a substitution of the official guide from Oracle (http://www.oracle.com). The below mentioned link can be used to download the official documentation for RMAN Recovery Catalog.



For the screenshots of the steps, please visit the following link::   http://www.sensehaze.com/mydata/resources_section/bck_rec/recv_catalog_rman/index.php




Disk Space Allocation for the Recovery Catalog Database:
If we are creating our recovery catalog in an already-existing database, add enough space to hold the default tablespace to the recovery catalog schema. If we are creating a new database to hold our recovery catalog, then, in addition to the space for the recovery catalog schema itself, we must allow space for other files in the recovery catalog database:
  • SYSTEM tablespace
  • Temporary tablespaces
  • Rollback segment tablespaces
  • Online redo log files
Typical Recovery Catalog Space Requirements for 1 Year
 Type of Space Space Requirement
 SYSTEM tablespace 90 MB
 Temp tablespace 5 MB
 Rollback or undo tablespace 5 MB
 Recovery catalog tablespace 15 MB for each database registered in the recovery catalog
 Online redo logs 1 MB each (3 groups, each with 2 members)
Note : For the purpose of this guide i will use a separate database (Catalog DBName - CATALOG).









 Create a user and schema for Recovery Catalog:
Start SQL*Plus and connect as administrator-privileged-user to the database containing the recovery catalog.
cmd > set ORACLE_SID=CATALOG
cmd > sqlplus sys/sys as sysdba

Create Catalog Tablespace:
SQL> create tablespace reco_cat
datafile 'E:\app\admin\oradata\catalog\reco_cat.dbf' SIZE 100m ;

Create Catalog User:
SQL> CREATE USER rman IDENTIFIED BY rman
DEFAULT TABLESPACE reco_cat
TEMPORARY TABLESPACE temp
QUOTA UNLIMITED ON reco_cat;

Grant RECOVERY_CATALOG_OWNER role to the schema owner:
SQL> GRANT RECOVERY_CATALOG_OWNER, CONNECT, RESOURCE TO rman;




For the screenshots of the steps, please visit the following link::   http://www.sensehaze.com/mydata/resources_section/bck_rec/recv_catalog_rman/index.php






Create the Recovery Catalog:
Connect to the database that will contain the catalog as the catalog owner.
CMD> rman CATALOG rman/rman@catalog
Run the CREATE CATALOG command to create the catalog. The creation of the catalog can take several minutes.
RMAN> CREATE CATALOG ;






Register a Database with RMAN:
After making sure the recovery catalog database is open, connect RMAN to the target database and recovery catalog database.
CMD> rman target sys/sys@mydb CATALOG rman/rman@catalog
If the target database is not mounted, then mount or open it.
RMAN> STARTUP MOUNT ;
-or-
RMAN> STARTUP OPEN ;
Register the target database in the connected recovery catalog.
RMAN> REGISTER DATABASE ;


RMAN creates rows in the catalog tables to contain information about the target database, then copies all pertinent data about the target database from the control file into the catalog, synchronizing the catalog with the control file.
The database can now be operated on using the RMAN utility with catalog option.


For the screenshots of the steps, please visit the following link::   http://www.sensehaze.com/mydata/resources_section/bck_rec/recv_catalog_rman/index.php










No comments:

Post a Comment