Apr 5, 2009

Clone using Export Dump

create a new database or clone a existing database or recover using oracle export Dump.

1. You must have full backup dump

2. List the content from export dump

Imp file=’/dump/xyz.dmp’ log=’/dump/imp.log’ full=y show=y
It will list all sql statement in log (imp.log)

c. Open the imp.log file, search and find the tablespace and users sql statements

i. Create tablespace .......
ii. Create users ....
iii. Create index..
iv. And what every you want

d. Copy and past it in a file.sql. now u will the script for creating a database.

e. Copy and save ‘create user.. ‘ is seperate file and ‘create tablespace..’ in sepereate sql file.

3. Create required folders (bdump,udump, also oradata)

4. Edit the pfile, use it from backup, if not. copy it from old db alert log or statspack report if u have.
5. Create oracle service

Windows : oradim –new –sid xxx
Solaris : export oracle_sid= xxx

6. Startup the database

Sqlplus “/as sysdba”
Startup nomount pfile=’/pfile.ora’

7. Run the script

$> @ file.sql
It will create all tablespaces

8. Open the database

Alter database mount;
Alter database open;

9. Create the users

Run the script to create users
@users.sql’

10. Import the datas

Imp file=’/dump/xyz.dmp’ log=’/dump/imp.log’ full=y

After import data, update the database metrics using analyze command..

3 comments:

Drunk and Monk said...

i have taken a backup using export utility in oracle 10g & when i try to import it

it throws an error saying :imp-00008-unrecognised statement

can you tell me how to solve this error or issue

if you can please mail me vikramv@maveric-systems.com

Anonymous said...

Amiable fill someone in on and this enter helped me alot in my college assignement. Gratefulness you as your information.

Anonymous said...

may i ask you about file.sql? i can't see any infomation about that on your posting.