赞
踩
1、 在sqlplus下创建相关的表空间
create tablespace INDX datafile '/app/oracle/orcl/indx_01.dbf' size 2048M extent management local segment space management auto;
2、 创建directory
dba用sqlplus用户登入,执行:
create or replace DIRECTORY DATA_DUMP_DIR AS '/app/oracle/dump';
赋予权限:
grant read,write on directory DATA_DUMP_DIR to system;
3、导入
将数据泵文件上传到DATA_DUMP_DIR目录中,然后执行命令:
impdp system/【密码】SCHEMAS=mctpsys,mctp,mctpsa DIRECTORY=DATA_DUMP_DIR DUMPFILE=ipap_v1.6.0.expdp logfile=impdp_ipap_v1.6.0_.log;
4、验证检查
通过pl/sql工具检查MCTP、MCTPSA、MCTPSYS三个用户的失效对象,并编译失效对象
5、备份
执行命令:
expdp system/【密码】SCHEMAS=mctpsys,mctp,mctpsa DIRECTORY=DATA_DUMP_DIR DUMPFILE=ipap_v1.6.0.expdp logfile=impdp_ipap_v1.6.0_.log;
导出的文件在 DATA_DUMP_DIR目录中。
6、检查数据库是否存在指定路径
select directory_name,directory_path from dba_directories;
7、单独的导入几个表
删除当前数据库中已经存在的表,然后导入,在导入的时候会有报错,是因为这些对象已经存在,当导入到删除的表的时候,会正确的导入,数据不会发生变化
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。