Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Mailing Lists -> Oracle-L -> Re: easiest way to clone an existing database on a different (unix) h
!#/ start of shameless plug
NOTE: This is copied, step by step, from Oracle SQL & PL/SQL Annotated Archives. I use a similar method, with a hot backup, instead of a cold backup, to copy a database and rename it, on the same machine.
!#/ end of shameless plug
Well, on the assumption that you can shut down database1 and do a cold backup...
This will generate the commands
recover database using backup controlfile
and
alter database open resetlogs
in the trace file.
3. Copy the backup files and the trace file to the other system
4. Edit the trace file and init.ora etc files to change the database name
(listener.ora, tnsnames. ora etc)
5. If you want to move the locations of the datafiles or rename the files,
edit the trace file with the new information, and make sure that the files
are named that name and in the new locations.
6. in SVRMGR (on the new system)... run the trace file
7. if you are using global names run
alter database rename global_name to <newname> 8. Rename the init.ora and config.ora files to reflect the new name 9. Edit instance name specific files: oratab, listener.ora, tnsnames.ora
If you are not ABSOLUTELY certain that database1 has been shutdown normally and you have a cold backup of all the redo logs and datafiles, then replace "resetlogs" in step 2 with "noresetlogs". This will generate the commands
recover database
and
alter database open
in the trace file.
>From: Carmen Rusu <crusu_at_clearcommerce.com>
>Reply-To: ORACLE-L_at_fatcity.com
>To: Multiple recipients of list ORACLE-L <ORACLE-L_at_fatcity.com>
>Subject: easiest way to clone an existing database on a different (unix) h
>Date: Wed, 05 Jul 2000 14:44:52 -0800
>
>Hi Oracle gurus!
>
>I have an oracle 8.1.5 database1 on sunos 2.7 sun1.
>Would like to create a clone of database1, named database2 on another sunos
>2.7 host, sun2.
>How do you do this in a reasonable efficient way ?
>
>Thanks,
>
>Carmen Rusu
>Sr Database Engineer
>--
>Author: Carmen Rusu
> INET: crusu_at_clearcommerce.com
>
>Fat City Network Services -- (858) 538-5051 FAX: (858) 538-5051
>San Diego, California -- Public Internet access / Mailing Lists
>--------------------------------------------------------------------
>To REMOVE yourself from this mailing list, send an E-Mail message
>to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
>the message BODY, include a line containing: UNSUB ORACLE-L
>(or the name of mailing list you want to be removed from). You may
>also send the HELP command for other information (like subscribing).
![]() |
![]() |