Pages

Tuesday, March 15, 2016

Create Recovery Catalog

Create Recovery Catalog

First create a user to hold the recovery catalog:

STEP 1

CONNECT sys/chnangeoninstall@RMAN AS SYSDBA

-- Create tablepsace to hold repository

CREATE TABLESPACE RMAN DATAFILE '/d05/rmancat/rmandata/RMAN01.DBF' SIZE 500M REUSE AUTOEXTEND ON NEXT 64K MAXSIZE 32767M
EXTENT MANAGEMENT LOCAL SEGMENT SPACE MANAGEMENT AUTO;

create temporary tablespace TEMP tempfile '/d05/rmancat/rmandata/temp01.dbf' size 500M reuse autoextend on next 32m maxsize 2048m extent management local;

-- Create rman schema owner

STEP 2
CREATE USER rman IDENTIFIED BY rman
TEMPORARY TABLESPACE temp
DEFAULT TABLESPACE rman
QUOTA UNLIMITED ON rman;

STEP 3

GRANT connect, resource, recovery_catalog_owner TO rman;

STEP 4

Then create the recovery catalog:

$ rman catalog=rman/rman@RMAN

Recovery Manager: Release 9.2.0.3.0 - Production

Copyright (c) 1995, 2002, Oracle Corporation. All rights reserved.

connected to recovery catalog database
recovery catalog is not installed

RMAN> create catalog tablespace "RMAN";

recovery catalog created

RMAN> exit

Recovery Manager complete.

Register Database
Each database to be backed up by RMAN must be registered:

$ rman catalog=rman/rman@RMANCAT target=sys/oracle@TEST
Recovery Manager: Release 9.2.0.3.0 - Production

Copyright (c) 1995, 2002, Oracle Corporation. All rights reserved.

connected to target database: TEST (DBID=1371963417)
connected to recovery catalog database

RMAN> register database;

database registered in recovery catalog
starting full resync of recovery catalog
full resync complete

No comments:

Post a Comment