RE: clone database use RMAN backup on same server

From: Steve Wales <sjwales_at_comcast.net>
Date: Tue, 7 Feb 2012 08:53:15 -0700
Message-ID: <2BB24EC89F0443BF8DAB3A385D0E5638_at_StevePC>



Try this (at a high level, refer to the documentation for details):
  • Target (Source database) should be up.
  • Login and do: create pfile='/path/to/initclonedb.ora' from spfile;
  • Edit the pfile, change all references from target to clonedb
    • db_name = clonedb
    • instance_name = clonedb
    • setup background_dump_dest, user_dump_dest etc
    • point your control files at the new location
    • setup db_file_name_convert='old','new'
    • setup log_file_name_convert='old','new'
  • Make sure all needed directory structures are created (controlfiles, datafiles, log files etc)
  • If windows, make sure services have been created
  • Login to the clonedb, shut it down
  • Start it up again, nomount, with the modified pfile created above
    • startup nomount pfile=/path/to/initclonedb.ora
  • Configure tnsnames.ora and your listener
  • Login to your target and LIST BACKUP SUMMARY to make sure your backups are there
  • Set ORACLE_SID to be your clone
  • RMAN TARGET /_at_target auxiliary /
  • Should show connected to target (open), clonedb (not mounted)
  • Execute: Run { Allocate auxiliary channel aux1 device type disk; Set until time "to_date('2012-02-07:06:00:00','YYYY-MM-DD:HH24:MI:SS')"; Duplicate target database to CLONEDB; }

Then wait for it to finish.

After it's done, I shut the copy down and set to noarchivelog mode and change the password of a couple of accounts so that the passwords are different in test then prod etc.

That should be the gist of it, but check the RMAN documentation for more details.

Steve

-----Original Message-----
From: oracle-l-bounce_at_freelists.org [mailto:oracle-l-bounce_at_freelists.org] On Behalf Of dba1 mcc
Sent: Tuesday, February 07, 2012 8:20 AM To: oracle-db-backup-l_at_Groups.ITtoolbox.com Cc: oracle-l_at_freelists.org
Subject: clone database use RMAN backup on same server

I tried to clone ORACLE database use one week ago RMAN (10Gr2) database backup. Clone database also on same server but different instance name.

Anyone know how to do it?

Thanks.

--
http://www.freelists.org/webpage/oracle-l


--
http://www.freelists.org/webpage/oracle-l
Received on Tue Feb 07 2012 - 09:53:15 CST

Original text of this message