Solved

Clone databases using RMAN backup

Posted on 2013-11-25
8
548 Views
Last Modified: 2014-02-01
Hi, need some assistance, have to clone 2 dbs; one RAC/2 nodes & one standalone from rman backup of another & different db/s (RAC & standalone) running on different Solaris box.

Do update, if able to assist or can provide some steps/hints/links or any kind of assistance, will be highly appreciated.

Thanks in advance.
0
Comment
Question by:mkhandba
  • 4
  • 3
8 Comments
 
LVL 8

Assisted Solution

by:Pepe2323
Pepe2323 earned 250 total points
ID: 39676284
Hi I hope this help with your tasks

what ia have done when i'm doing data guard to replicate the database is this:

rman target / log=/path/you/want/rman_backup.log
run{
ALLOCATE CHANNEL c1 DEVICE TYPE DISK FORMAT '/path-of-the-backup/date/%U';
BACKUP FULL DATABASE PLUS ARCHIVELOG;
BACKUP CURRENT CONTROLFILE ;
}


and for the restore:

Be sure to have a  copy of the pfile where you want  to restore, if you only have spfile then create an pfile, and while you are restoring be sure have the cluster parameter as false into the pfile.

rman nocatalog

  connect target /

shutdown abort;
startup nomount;

    alter database mount;
    CROSSCHECK ARCHIVELOG ALL;
    CROSSCHECK BACKUP;
    CATALOG START WITH '/path/where-is the backup/' NOPROMPT;
    restore database;
    recover database;

Note:probably you will need to restore control files first before do all restore, check on you log what is the name of that backup of control files.


after finish the restore then:

shutdown immediate;

sqlplus  / as sysdba
startup
0
 
LVL 29

Accepted Solution

by:
MikeOM_DBA earned 250 total points
ID: 39678303
Perhaps you would get better instructions if you Read The Fine Manual:
Oracle® Database Backup and Recovery User's Guide
0
 

Author Comment

by:mkhandba
ID: 39690125
thanks folks, I was able to restore, using RMAN, basically I left it in the night and when got back in morning, saw that something got failed due to 100% file system error.

Can you please advice/suggest, how to fix/correct this or do I need to start from scratch again ... ;-(

Please assist/guide ... thanks.
0
 
LVL 29

Expert Comment

by:MikeOM_DBA
ID: 39693491
You may need to make space or re-locate some files using the "SET NEWNAME FOR ..."

When you restart the restore, rman will detect and skip files already restored...

Good luck!

PS: Make sure you do not move files already restored!!!
0
Complete VMware vSphere® ESX(i) & Hyper-V Backup

Capture your entire system, including the host, with patented disk imaging integrated with VMware VADP / Microsoft VSS and RCT. RTOs is as low as 15 seconds with Acronis Active Restore™. You can enjoy unlimited P2V/V2V migrations from any source (even from a different hypervisor)

 

Author Comment

by:mkhandba
ID: 39698699
Was able to fix all these and now the clone/refresh got completed, need one assistance here, how to update db links, because they are pointing to wrong database now, is there any way to figure it out and correct/update all of the db links?
0
 
LVL 29

Expert Comment

by:MikeOM_DBA
ID: 39698958
You will need to re-create them.
Query the DBA_DB_LINKS view and/or using SQL Developer (or TOAD) generate the code to replace them.
0
 

Author Comment

by:mkhandba
ID: 39699318
Thanks for this MikeOM_DBA, but this not about recreating, basically they are linking to a different db; e.g., we clone RAC2 to RAC1, but the db links are still linking to RAC2, where as they should be RAC1, task is to find out how many of db links are still targeting to RAC2 and update/correct or even recreate them linking to RAC1 ... is this clarify the situation.

Please do update, if requires any more info and thanks a lot.
0
 

Author Comment

by:mkhandba
ID: 39699394
got it too:

select * from dba_synonyms
where db_link is not null
0

Featured Post

Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

Join & Write a Comment

A quick step-by-step overview of installing and configuring Carbonite Server Backup.
By default, Carbonite Server Backup manages your encryption key for you using Advanced Encryption Standard (AES) 128-bit encryption. If you choose to manage your private encryption key, your backups will be encrypted using AES 256-bit encryption.
This video explains what a user managed backup is and shows how to take one, providing a couple of simple example scripts.
This tutorial will show how to configure a single USB drive with a separate folder for each day of the week. This will allow each of the backups to be kept separate preventing the previous day’s backup from being overwritten. The USB drive must be s…

706 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now