TEST
Powered by Blogger.
Responsive Ad
Responsive Ad

Author Profile

About Me

Start Sharing

Start Sharing

Drive Traffic on Social Platforms

Blog Archive

Blog Journey

Blog Journey

Learn how to start a perfect Blog

Work Smart, Not Hard - Let's See

Make your Blogging experience faster and easiest …
Work Smart, Not Hard - Let's See
Design by - Blogger Templates | Distributed by Free Blogger Templates

Made with Love by

Material UI Template is Designed Theme for Giving Enhanced look Various Features are available Whic…

Random Posts

Ads Section

HOME > > Restore and recover the Database to a new host with a same directory structure

Restore and recover the Database to a new host with a same directory structure

Anup - Friday, 20 May 2011
Restore and Recover database to a new host with same directory structure

In this case DBID of the database will be the same as of original database.

Source Configuration:

Host Name SUN1
DB Name PROD
Database Location /DB/PROD
Backup Location /RMAN_BKP
Archive Location /archive

Target Configuration:

Host Name SUN2
DB Name PROD
Database Location /DB/PROD
Backup Location /RMAN_BKP
Archive Location /archive



Step 1 Take a full backup of Source Database

RMAN> backup database plus archivelog;
RMAN>backup spfile; - if you are using spfile , other wise take backup of pfile by using os command.

Step 2 Transfer these backup pieces to target machine (/RMAN_BKP location)

Step 3 Determine the DBID of source machine

SQL> select dbid from v$database;

DBID
----------
142618240

Step 4 Now perform task on target machine
First set ORACLE_SID, ORACLE_HOME and PATH then connect to rman

Step 5 Set DBID and restore spfile or pfile.

RMAN> set dbid 142618240
executing command: SET DBID

RMAN> startup nomount

Step 6 Restore pfile.
RMAN> restore spfile to pfile '/export/home/oracle/oracle/product/10.2.0/db_1/dbs/initPROD.ora' from '/RMAN_BKP/c-142618240-20100927-01';

Step 7 Start the instance with pfile.

RMAN> STARTUP FORCE NOMOUNT

Step 8 Restore and Mount the Control file on Target Instance

RMAN> restore controlfile from '/RMAN_BKP/c-142618240-20100927-01';
RMAN> ALTER DATABASE MOUNT;

Step 9 Restore the database

RMAN> restore database;

Step 10 Recover the database

RMAN > recover database;

Step 11 Open the Database resetlogs option.

RMAN> alter database open resetlogs;

Contact me

Get in Touch

Need to get touch with me? Please fill out the form with your enquiry.

Name
Anup Srivastav
Address
Lucknow - Utter Pradesh
Email
myindiandba@gmail.com
Message me