当前位置:数据库 > Oracle >>

Oracle - Import datapump errors

Oracle - Import datapump errors
 
I got below errors when I was doing datapump import for oracle database today.
[html] 
impdp 'xeuser/password@xe' directory=datadump schemas=xeuser dumpfile=BACKUP.DMP logfile=impdp.log  
  
...  
  
ORA-39002: invalid operation  
ORA-39070: Unable to open the log file.  
ORA-39087: directory name DATADUMP is invalid  
 
How to resolve?
1. create directory
[html] 
SQL>create or replace directory datadump as '/dumpdir';  
I named this direcotry as datadump. You can name it as what you want. 
 
2. grant read, write permission to user
[html] 
SQL>grant read,write on directory datadump to xeuser,sys;  
 
3. please notice: if you use linux os you need to do one more thing:
    Make sure oracle has the write permission of datadump folder and has the read permission of your datadump file.
Ortherwise you more likely get error below:
[html] 
ORA-39002: invalid operation  
ORA-39070: Unable to open the log file.  
ORA-29283: invalid file operation  
ORA-06512: at "SYS.UTL_FILE", line 536  
ORA-29283: invalid file operation  
 
Don't repeat my mistake!
I just simply gave rwx for all users.
[html] 
sudo chmod u+rwx,g+rwx,o+rwx /dumpdir  
 
CopyRight © 2022 站长资源库 编程知识问答 zzzyk.com All Rights Reserved
部分文章来自网络,