Duplicate Database With RMAN Without Connecting To Target Database – from metalink Id 732624.1
How to do duplicate database without connecting to target database using backups taken from RMAN on alternate host.
Solution
Follow the below steps
1)Export ORACLE_SID=
create init.ora file and give db_name= and control_files=
want controlfile to be restored>
2)Startup nomount pfile=;
3)Connect to RMAN and issue command :
RMAN>restore controlfile from ‘;
controlfile should be restored.
4) Issue “alter database mount”
Make sure that backuppieces are on the same location where it were there on production db. If you
dont have the same location, then make RMAN aware of the changed location using “catalog” command.
RMAN>catalog backuppiece;
If there are more backuppieces, than they can be cataloged using command :
RMAN>catalog start with;
5) After catalogging backuppiece, issue “restore database” command. If you need to restore datafiles to a location different to the one recorded in controlfile, use SET NEWNAME command as below:
run {
set newname for datafile 1 to ‘/newLocation/system.dbf’;
set newname for datafile 2 to ‘/newLocation/undotbs.dbf’;
…
restore database;
switch datafile all;
How to do duplicate database without connecting to target database using backups taken from RMAN on alternate host.
Solution
Follow the below steps
1)Export ORACLE_SID=
create init.ora file and give db_name=
2)Startup nomount pfile=
3)Connect to RMAN and issue command :
RMAN>restore controlfile from ‘
controlfile should be restored.
4) Issue “alter database mount”
Make sure that backuppieces are on the same location where it were there on production db. If you
dont have the same location, then make RMAN aware of the changed location using “catalog” command.
RMAN>catalog backuppiece
If there are more backuppieces, than they can be cataloged using command :
RMAN>catalog start with
5) After catalogging backuppiece, issue “restore database” command. If you need to restore datafiles to a location different to the one recorded in controlfile, use SET NEWNAME command as below:
run {
set newname for datafile 1 to ‘/newLocation/system.dbf’;
set newname for datafile 2 to ‘/newLocation/undotbs.dbf’;
…
restore database;
switch datafile all;
No comments :
Post a Comment