1. Requirements: 10g oracle database on the windows need to be imported into the 10g Oracle database on Linux
2. Analysis: After use exp exported dmp file into Linux in Oracle
imp test/test@orcl full=y file=/home/oracle/exp20191017.dmp ignore=y
3. Question: After importing the discovery table after the import was incomplete, missing seventeen table
4. Analysis TWO: table structure analysis of the log and find that it contains seventeen table has a field of type CLOB
5. Measures: After the query can not know imp command to import clob type of field, it would change a new command: expdp / impdp
Export steps:
Export Directory to establish a connection Oracle:. Note that this directory needs to be created manually
create directory dir as 'D:\test';
Then export the query directory listing:
select * from dba_directories;
If you find the same name will be deleted reconstruction dir:
drop directory dir;
Permission to this directory then licensed to test user:
grant read,write on directory dir to test;
. B then exit Oracle, derived directly from the command line:
expdp test/test directory=dir dumpfile=20191104exp.dmp logfile=20191104log.log
This can be in D: \ test to view the exported file.
Then we look at import steps:
. A front and export as import command:
impdp wl/wl directory=dir dumpfile=20191104EXP.DMP REMAP_SCHEMA=test:wl EXCLUDE=USER
Note: REMAP_SCHEMA = test: wl parameters, it is export and import user name
Error when importing:
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
This is a linux directory permissions is not enough, because the import is used when Oracle account, and when the new root directory permissions permission, we just need to cut back to give the root directory of authorized users can:
chown -R oracle:oinstall /home/oracle/20191104
This can be directly imported.
As for the different versions of Oracle import and export, next time he says.
Work record:
1.expdp Export: sqlplus /nolog connect /as sysdba create directory dir as 'D:\ziyuan'; select * from dba_directories; drop directory dir; grant read,write on directory dir to ZIYUAN; SELECT SUM(s.BYTES)/1024/1024 "sizes(MB)" from dba_segments s where s.owner= 'ZIYUAN'; select count(*) from dba_tables t where t.owner='ZIYUAN'; oracle下 expdp ZIYUAN/ZIYUAN2015 directory=dir dumpfile=20191104exp.dmp logfile=20191104log.log 2.impdp import: create directory dir as '/home/oracle/Desktop'; select * from dba_directories; drop directory dir; grant read,write on directory dir to MBZY; SELECT SUM(s.BYTES)/1024/1024 "sizes(MB)" from dba_segments s where s.owner= 'ZIYUAN'; select count(*) from dba_tables t where t.owner='ZIYUAN'; impdp MBZY/MBZY directory=dir dumpfile=20191104EXP.DMP logfile=20191104log.log impdp MBZY/MBZY directory=dir dumpfile=20191104EXP.DMP REMAP_SCHEMA=ZIYUAN:MBZY EXCLUDE=USER logfile=20191104log.log impdp MBZY/MBZY schemas=certification directory=dir dumpfile=20191104EXP.DMP impdp MBZY/MBZY schemas=ZIYUAN directory=dir dumpfile=20191104EXP.DMP logfile=imp.log IMPDP USERID='SYS/ggoabak10@ggbak10 as sysdba' schemas=ZIYUAN directory=dir dumpfile=20191104EXP.DMP logfile=aa.log version=10.2.0.1.0