RMAN recovery catalog

You can always use controlfile as the primary store for the repository.  However, for large databases, the recovery catalog provides a larger storage capacity and allowing you to keep longer history of backups.  You can also create and store RMAN scripts int he recovery catalog and oracle suggests to create central catalog for all your databases.  I think the RMAN Receipes Oracle Oracle Database 11g (Arup Nanda, Darl Kuhn, Sam Alapati) is a good book for quick reference and solutions for all backup recoveries scenarios.


Anyway, to setup RMAN repository, register, and setup you just follow these simple steps:
  •  Create a blank repository database - RMANDB
  • create tablespace RMANTS datafile '+LAB_DG100' size 8g;
  • create user rman identified by rman123 temporary tablespace temp default tablespace RMANTS quota unlimited on RMANTS;
  • grant recovery_catalog_owner to rman;
Before backup a database, you need to connect and register it with the catalog:


RMAN> connect catalog rman/rman123@RMANDB
RMAN> register database;
RMAN> resync catalog;


Backup database plus archive log and name a tag
RMAN > backup database format '/repos/backup/backup_%U' plus archivelog tag 'gold_backup';


Backup control file and spfile:


RMAN > backup as copy tag='gold_cntr' format '/repos/backup/%d.%s.%p.%t.CTL' current controlfile;
RMAN > backup spfile format '/repos/backup/%d.%s.%p.%t.SPFILE';


Below are some important RMAN views:
rc_rman_status
rc_datafile
rc_database
rc_configuration
, etc..

No comments:

Post a Comment