Oracle impdp command ORA-39145, ORA-31655, ORA-39154
While using the Oracle 11g impdp command there are few precursors that need to be taken care:
1. impdp is a OS command and hence need to be executed from command prompt and not SQL Plus. For using it within SQL Plus,you got to use the following command: host impdp
2. Prerequisite steps:
a. First create the directory within SQL Plus :
create or replace directory importTestDB as 'c:\importTestDB';
If there is an issue with this directory, you may receive the following error:
ORA-39145: directory object parameter must be specified and non-null
b. Grant the permissions to user for this directory:
grant read,write on DIRECTORY importTestDB to user1;
c. Grant the permission to import full database to the user:
grant imp_full_database to user1;
Failing which you may receive the following error:
ORA-31655: no data or metadata objects selected for job
ORA-39154: Objects from foreign schemas have been removed from import
3. Execute the following command from command prompt:
impdp user1/pass@orcl directory=importTestDB full=y dumpfile=TestDBDump11092012.dmp logfile=log.txt;
if you see the following text after the above command starts execution, then you have successfully met all the prerequisities to import a Oracle database :
Connected to: Oracle Database 11g Release 11.2.0.1.0 - Production
Master table "user1"."SYS_IMPORT_FULL_01" successfully loaded/unloaded
Starting "user1"."SYS_IMPORT_FULL_01": user1/********@orcl directory=importTestDB full=y dumpfile=TestDBDump11092012.dmp logfile=log
txt;
Processing object type SCHEMA_EXPORT/USER
Processing object type SCHEMA_EXPORT/SYSTEM_GRANT
Processing object type SCHEMA_EXPORT/ROLE_GRANT
Processing object type SCHEMA_EXPORT/DEFAULT_ROLE
Processing object type SCHEMA_EXPORT/TABLESPACE_QUOTA
Processing object type SCHEMA_EXPORT/PRE_SCHEMA/PROCACT_SCHEMA
Processing object type SCHEMA_EXPORT/SEQUENCE/SEQUENCE
Processing object type SCHEMA_EXPORT/TABLE/TABLE
Processing object type SCHEMA_EXPORT/TABLE/TABLE_DATA
Please check the log file especially the last few lines to see if import was successfully completed or not.
1. impdp is a OS command and hence need to be executed from command prompt and not SQL Plus. For using it within SQL Plus,you got to use the following command: host impdp
2. Prerequisite steps:
a. First create the directory within SQL Plus :
create or replace directory importTestDB as 'c:\importTestDB';
If there is an issue with this directory, you may receive the following error:
ORA-39145: directory object parameter must be specified and non-null
b. Grant the permissions to user for this directory:
grant read,write on DIRECTORY importTestDB to user1;
c. Grant the permission to import full database to the user:
grant imp_full_database to user1;
Failing which you may receive the following error:
ORA-31655: no data or metadata objects selected for job
ORA-39154: Objects from foreign schemas have been removed from import
3. Execute the following command from command prompt:
impdp user1/pass@orcl directory=importTestDB full=y dumpfile=TestDBDump11092012.dmp logfile=log.txt;
if you see the following text after the above command starts execution, then you have successfully met all the prerequisities to import a Oracle database :
Connected to: Oracle Database 11g Release 11.2.0.1.0 - Production
Master table "user1"."SYS_IMPORT_FULL_01" successfully loaded/unloaded
Starting "user1"."SYS_IMPORT_FULL_01": user1/********@orcl directory=importTestDB full=y dumpfile=TestDBDump11092012.dmp logfile=log
txt;
Processing object type SCHEMA_EXPORT/USER
Processing object type SCHEMA_EXPORT/SYSTEM_GRANT
Processing object type SCHEMA_EXPORT/ROLE_GRANT
Processing object type SCHEMA_EXPORT/DEFAULT_ROLE
Processing object type SCHEMA_EXPORT/TABLESPACE_QUOTA
Processing object type SCHEMA_EXPORT/PRE_SCHEMA/PROCACT_SCHEMA
Processing object type SCHEMA_EXPORT/SEQUENCE/SEQUENCE
Processing object type SCHEMA_EXPORT/TABLE/TABLE
Processing object type SCHEMA_EXPORT/TABLE/TABLE_DATA
Please check the log file especially the last few lines to see if import was successfully completed or not.
Comments