Take the 2-minute tour ×
Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

I have one db dump below is the log file for that dump

Connected to: Oracle Database 10g Express Edition Release 10.2.0.1.0 - Production
Starting "SYSTEM"."SYS_EXPORT_SCHEMA_01":  system/******** PARALLEL=1 SCHEMAS=tmsmv DUMPFILE=tmsmv-20120706.dmp LOGFILE=tmsmv-20120706.log 
Estimate in progress using BLOCKS method...
Processing object type SCHEMA_EXPORT/TABLE/TABLE_DATA
Total estimation using BLOCKS method: 146.1 MB
...........

I want to restore this dump using another user tmsmv using below command:

sql>conn / as sysdba
CREATE OR REPLACE DIRECTORY DUMP_DIR AS '/home/..../';
GRANT READ, WRITE ON DIRECTORY DUMP_DIR TO tmsmv;
GRANT READ, WRITE ON DIRECTORY SYS.DUMP_DIR TO EXP_FULL_DATABASE;
GRANT READ, WRITE ON DIRECTORY SYS.DUMP_DIR TO IMP_FULL_DATABASE;

And then importing with:

impdp tmsmv/***** schemas=TMSMV directory=DUMP_DIR dumpfile=tmsmv-20120706.dmp

While restoring I am facing below error message:

ORA-39002: invalid operation
ORA-39070: Unable to open the log file.
ORA-29283: invalid file operation
ORA-06512: at "SYS.UTL_FILE", line 475
ORA-29283: invalid file operation 

Please help me to solve this issue.

share|improve this question
    
Does the DUMP_DIR exist? Is it writable by the user you're running the impdp as? Does the log file already exist, and can you specify a different one on the command line? –  Alex Poole Jul 20 '12 at 7:25
    
yes the dump is exist and it has write permissions,and i also tested like impdp tmsmv/* NOLOGFILE=Y schemas=TMSMV directory=DUMP_DIR dumpfile=tmsmv-20120706.dmp in this case i got below error message ORA-39001: invalid argument value ORA-39000: bad dump file specification ORA-31640: unable to open dump file "/home/....../tmsmv-20120706.dmp" for read ORA-27037: unable to obtain file status Linux Error: 13: Permission denied Additional information: 3 –  babu Jul 20 '12 at 7:31
    
not readable by user means db user or Linux user? As a linux user i gave all permissions to that folder. –  babu Jul 20 '12 at 7:50
    
how to make my file readable by oracle owner. –  babu Jul 20 '12 at 12:06
add comment

1 Answer

up vote 1 down vote accepted

It looks like Oracle can't read the .dmp file, because it's under another user's home directory. Oracle has to be able to read it, not the Linux user you're running the impdp command as. (Contrary to my earlier misleading comments!)

Assuming the two users are in different groups, you may need to make the .dmp file world-readable:

chmod o+r /home/..../tmsmv-20120706.dmp

And usually all directories in the path need to be world-readable and world-executable:

chmod o+rx /home/..../

If you wanted the log file to be created, it would be need to be writable too (chmod o+rwx). If it's in a subdirectory of your home directory, you might need to do this to all intermediate levels.

But relaxing permissions on your home directory can be a problem, so you might be better off using a directory somewhere else. Or leave the file where expdp put it, and grant permissions on that DIRECTORY object to tmsmv instead.

share|improve this answer
    
thanks alex,i changed my dmp file user to oracle it's working now. –  babu Jul 24 '12 at 4:08
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.