Home » RDBMS Server » Backup & Recovery » The doubt about full db recovery via exp/imp (oracle 8i)
The doubt about full db recovery via exp/imp [message #605129] Tue, 07 January 2014 08:54 Go to next message
lylklb
Messages: 12
Registered: January 2014
Junior Member
http://docs.oracle.com/cd/A87860_01/doc/server.817/a76955/ch02.htm#26295

To restore a set of objects, you must first import the most recent incremental export file to import the system objects (i.e. specify INCTYPE=SYSTEM for the export). Then you must import the export files in chronological order, based on their export time (i.e. specify INCTYPE=RESTORE for the import).

An incremental export extracts only tables that have changed since the last incremental, cumulative, or complete export. Therefore, an import from an incremental export file imports the table definition and all of its data, not just the changed rows.

It is important to note that, because importing an incremental export file imports new versions of existing objects, existing objects are dropped before new ones are imported. This behavior differs from a normal import. During a normal import, objects are not dropped and an error is usually generated if the object already exists.

1. Import the most recent incremental export file (specify INCTYPE=SYSTEM for the export) or cumulative export file, if no incremental exports have been taken.
2. Import the most recent complete export file.
3. Import all cumulative export files after the last complete export.
4. Import all incremental export files after the last cumulative export.
For example, if you have:
one complete export called X1
two cumulative exports called C1 and C2
three incremental exports called I1, I2, and I3
then you should import in the following order:
IMP system/manager INCTYPE=SYSTEM FULL=Y FILE=I3
IMP system/manager INCTYPE=RESTORE FULL=Y FILE=X1
IMP system/manager INCTYPE=RESTORE FULL=Y FILE=C1
IMP system/manager INCTYPE=RESTORE FULL=Y FILE=C2
IMP system/manager INCTYPE=RESTORE FULL=Y FILE=I1
IMP system/manager INCTYPE=RESTORE FULL=Y FILE=I2
IMP system/manager INCTYPE=RESTORE FULL=Y FILE=I3

Notes:
1)You import the last incremental export file twice; once at the beginning to import the most recent version of the system objects, and once at the end to apply the most recent changes made to the user data and objects.
2)When restoring tables with this method, you should drop the tables from the database (if they exist) before starting the import sequence. This step prevents you from importing duplicate rows.


The following questions are my doubt:
1)Why must firstly & individually recovery system objects (but not import both system objects and user objects at the same end time ) ?!
2)Why must import system objects via the most recent incremental export file I3(because it is possible that there was no change for the system objects in I3, but only existed change in the previous some incremental/cumulative export file such as either I1 or C1、and might even only in complete export file
X1) !?
Re: The doubt about full db recovery via exp/imp [message #605131 is a reply to message #605129] Tue, 07 January 2014 08:58 Go to previous messageGo to next message
Michel Cadot
Messages: 68624
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

Forget about all that.
INCTYPE no more exists in the current versions (since the beginning of this century) and it has always have bugs which have never been fixed.
Use RMAN to backup and restore your database, you will have much more features and easiness to use.

Re: The doubt about full db recovery via exp/imp [message #605132 is a reply to message #605131] Tue, 07 January 2014 09:03 Go to previous messageGo to next message
BlackSwan
Messages: 26766
Registered: January 2009
Location: SoCal
Senior Member
>(oracle 8i)

please post full results from SQL below

SELECT * FROM V$VERSION;
Re: The doubt about full db recovery via exp/imp [message #605293 is a reply to message #605129] Wed, 08 January 2014 07:46 Go to previous messageGo to next message
lylklb
Messages: 12
Registered: January 2014
Junior Member
SQL>
SQL>
SQL> select * from v$version;

BANNER
----------------------------------------------------------------
Oracle8i Enterprise Edition Release 8.1.7.4.0 - Production
PL/SQL Release 8.1.7.4.0 - Production
CORE 8.1.7.0.0 Production
TNS for IBM/AIX RISC System/6000: Version 8.1.7.4.0 - Production
NLSRTL Version 3.4.1.0.0 - Production

SQL>
SQL>

In fact I really want to understand the truth of the principle for full db recpovery via exp/imp !


Thanks a lots !!!
Re: The doubt about full db recovery via exp/imp [message #605294 is a reply to message #605293] Wed, 08 January 2014 08:07 Go to previous messageGo to next message
Michel Cadot
Messages: 68624
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

exp/imp is NOT a database backup and cannot be used to recover.
Read again my first answer and forget exp/imp to backup/recover, use RMAN.

Re: The doubt about full db recovery via exp/imp [message #605303 is a reply to message #605293] Wed, 08 January 2014 09:22 Go to previous messageGo to next message
gazzag
Messages: 1118
Registered: November 2010
Location: Bedwas, UK
Senior Member
You can restore a database using an export (although that is not its purpose), however recovery is a very different thing. You should learn the correct terminology.

HTH
-g
Re: The doubt about full db recovery via exp/imp [message #605449 is a reply to message #605129] Thu, 09 January 2014 08:32 Go to previous messageGo to next message
lylklb
Messages: 12
Registered: January 2014
Junior Member
I would apologize for my serious mistake that my demand is to restore a full db via exp/imp, but not to recovery db via RMAN !!
So I hope that someone would be willing to explain the truth of the principle for restoring full db via exp/imp !!
Re: The doubt about full db recovery via exp/imp [message #605454 is a reply to message #605449] Thu, 09 January 2014 09:16 Go to previous messageGo to next message
gazzag
Messages: 1118
Registered: November 2010
Location: Bedwas, UK
Senior Member
Essentially you have to create a blank database then:

1. Create the required tablespaces
2. Create the required schemas
3. Import your dump file

Look into the SHOW=Y option of the import as this will help you determine what you need to pre-create before the import.

Good luck.
-g
Re: The doubt about full db recovery via exp/imp [message #605623 is a reply to message #605454] Sun, 12 January 2014 07:38 Go to previous messageGo to next message
lylklb
Messages: 12
Registered: January 2014
Junior Member
Thanks !

But I still want to know the answers of my above doubt about the two questins !!
Re: The doubt about full db recovery via exp/imp [message #605625 is a reply to message #605623] Sun, 12 January 2014 07:54 Go to previous messageGo to next message
Michel Cadot
Messages: 68624
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

Why?

Re: The doubt about full db recovery via exp/imp [message #605653 is a reply to message #605623] Mon, 13 January 2014 02:47 Go to previous messageGo to next message
gazzag
Messages: 1118
Registered: November 2010
Location: Bedwas, UK
Senior Member
The two questions are irrelevant. Forget about incremental exports - they never really worked anyway. I have given you the steps you need to take. Try and ask again if you encounter problems.

HTH
-g
Re: The doubt about full db recovery via exp/imp [message #605788 is a reply to message #605129] Tue, 14 January 2014 10:31 Go to previous messageGo to next message
tim2boles
Messages: 38
Registered: August 2008
Location: Clarksburg, WV
Member
Quote:
The following questions are my doubt:
1)Why must firstly & individually recovery system objects (but not import both system objects and user objects at the same end time ) ?!


Interesting that you left off the rest of the text in your original posting.

http://docs.oracle.com/cd/A87860_01/doc/server.817/a76955/ch02.htm#26295
Quote:
This step imports the correct system objects (for example, users, object types, and so forth) for the database.


You have to have the users, objects and so forth that might have been added so that your imports of those objects will work. You can not do them both, because the import may not have imported the system objects before attempts to import the objects that depend on those definitions. So system objects first.

Quote:

2)Why must import system objects via the most recent incremental export file I3(because it is possible that there was no change for the system objects in I3, but only existed change in the previous some incremental/cumulative export file such as either I1 or C1、and might even only in complete export file
X1) !?


I believe that the way that information and system tables are handled differently than "user" tables. http://docs.oracle.com/cd/A87860_01/doc/server.817/a76955/ch01.htm#17642
Quote:

In addition to the base tables and data, the following data is exported:

All system objects (including tablespace definitions, rollback segment definitions, and user privileges, but not including temporary segments)

Information about dropped objects

Clusters, tables, views, procedures, functions, dimensions, and synonyms created since the last export

All type definitions

Note: Export does not export grants on data dictionary views for security reasons that affect Import. If such grants were exported, access privileges would be changed and the user would not be aware of this. Also, not forcing grants on import allows the user more flexibility to set up appropriate grants on import.

Re: The doubt about full db recovery via exp/imp [message #605870 is a reply to message #605788] Wed, 15 January 2014 08:17 Go to previous messageGo to next message
lylklb
Messages: 12
Registered: January 2014
Junior Member
Anyway, thanks very much to tim2boles !!!

1. I can accept & realize your explanation for the first question !
2. Would be there any other information or explanation for the system objects within an incremental/cumulative export ?
Notes: at least the documents of Oracle do not make sure the principle of an incremental/cumulative export for the system objects vs user objects(table & data)!

[Updated on: Wed, 15 January 2014 08:20]

Report message to a moderator

Re: The doubt about full db recovery via exp/imp [message #606879 is a reply to message #605870] Thu, 30 January 2014 06:11 Go to previous message
mrkamranumer
Messages: 11
Registered: January 2014
Junior Member
As explained by Michel Cadot thats right in all scenarios


1.export data (required schemas) in dump file by using expdp or exp (expdp is more advance option)
2.Install new database
3.import with (required schemas) and thats it
Previous Topic: When and why RMAN catalogs the files in recovery area during a Restore and Recovery?
Next Topic: restore online backup to different server with different dir
Goto Forum:
  


Current Time: Thu Mar 28 07:18:42 CDT 2024