oracle数据泵导入导出命令
1.在PL/SQL的界面,找到Directories文件夹,找到目录文件的路径


2.通过SSH进入服务器
找到相应的路径 cd /u01/oracle/dpdir
输入指令
df -h 查看资源使用量
su – oracle 进入系统的oracle用户
3.导出数据库文件
expdp userid=hbcxjm/oracle directory=dpdir dumpfile=hbcxjm.dmp job_name=hbcxjm logfile=hbcxjmlog parallel=2 schemas=hbcxjm
PS:
其中userid是要导出的目标库的用户名密码,directory是建立的路径名称,dumpfile是目标文件名称
4.新建数据库用户
PS:注意表空间问题,确保表空间充足,否则导入会报错
5.导入数据
impdp hbcxjm/oracle directory=dpdir dumpfile=hbcxjm.dmp REMAP_SCHEMA=hbcxjm:hbcxjm REMAP_TABLESPACE=TP_HBCXJM:TP_HBCXJM
table_exists_action = truncate logfile=hbcxjmimp.log SCHEMAS=hbcxjm
PS:
REMAP_SCHEMA:导出数据用户的名称和导入数据用户的名称
REMAP_TABLESPACE:导出数据用户的表空间和导入数据用户的表空间
table_exists_action:如果表中有数据的处理方式,此处采用truncate处理
logfile:日志文件名称
例子:
文件导出:
expdp userid=hbcxjm/oracle directory=dpdir dumpfile=hbcxjm.dmp job_name=hbcxjm logfile=hbcxjmlog parallel=2 schemas=hbcxjm
expdp userid=drm_hbcxjm/oracle directory=dpdir dumpfile=drm_hbcxjm.dmp job_name=drm_hbcxjm logfile=drm_hbcxjmlog parallel=2 schemas=drm_hbcxjm
expdp userid=hbcxjm_report/oracle directory=dpdir dumpfile=hbcxjm_report.dmp job_name=hbcxjm_report logfile=hbcxjm_reportlog parallel=2 schemas=hbcxjm_report
expdp userid=hbcxjm_siif/oracle directory=dpdir dumpfile=hbcxjm_siif.dmp job_name=hbcxjm_siif logfile=hbcxjm_siiflog parallel=2 schemas=hbcxjm_siif
expdp userid=hxpt3dd/oracle directory=dpdir dumpfile=hxpt3dd.dmp job_name=hxpt3dd logfile=hxpt3ddlog parallel=2 schemas=hxpt3dd
expdp userid=drm_hxpt3dd/oracle directory=dpdir dumpfile=drm_hxpt3dd.dmp job_name=drm_hxpt3dd logfile=drm_hxpt3ddlog parallel=2 schemas=drm_hxpt3dd
文件导入:
impdp hbcxjm/oracle directory=dpdir dumpfile=hbcxjm.dmp REMAP_SCHEMA=hbcxjm:hbcxjm REMAP_TABLESPACE=TP_HBCXJM:TP_HBCXJM table_exists_action = truncate logfile=hbcxjmimp.log SCHEMAS=hbcxjm
impdp drm_hbcxjm/oracle directory=dpdir dumpfile=drm_hbcxjm.dmp REMAP_SCHEMA=drm_hbcxjm:drm_hbcxjm REMAP_TABLESPACE=TP_HBCXJM_DRM:TP_HBCXJM_DRM table_exists_action = truncate logfile=drm_hbcxjmimp.log SCHEMAS=drm_hbcxjm
impdp hbcxjm_report/oracle directory=dpdir dumpfile=hbcxjm_report.dmp REMAP_SCHEMA=hbcxjm_report:hbcxjm_report REMAP_TABLESPACE=TP_HBCXJM_DRM:TP_HBCXJM_DRM table_exists_action = truncate logfile=hbcxjm_reportimp.log SCHEMAS=hbcxjm_report
impdp hbcxjm_siif/oracle directory=dpdir dumpfile=hbcxjm_siif.dmp REMAP_SCHEMA=hbcxjm_siif:hbcxjm_siif REMAP_TABLESPACE=TP_HBCXJM:TP_HBCXJM table_exists_action = truncate logfile=hbcxjm_siifimp.log SCHEMAS=hbcxjm_siif
impdp hxpt3dd/oracle directory=dpdir dumpfile=hxpt3dd.dmp REMAP_SCHEMA=hxpt3dd:hxpt3dd REMAP_TABLESPACE=TP_HBCXJM_YBDD:TP_HBCXJM_YBDD table_exists_action = truncate logfile=hxpt3ddimp.log SCHEMAS=hxpt3dd
impdp drm_hxpt3dd/oracle directory=dpdir dumpfile=drm_hxpt3dd.dmp REMAP_SCHEMA=drm_hxpt3dd:drm_hxpt3dd REMAP_TABLESPACE=TP_HBCXJM_YBDD:TP_HBCXJM_YBDD table_exists_action = truncate logfile=drm_hxpt3ddimp.log SCHEMAS=drm_hxpt3dd
oracle数据泵导入导出命令的更多相关文章
- Oracle 数据泵导入导出总结
Oracle 数据泵(IMPDP/EXPDP)导入导出总结 Oracle数据泵导入导出是日常工作中常用的基本技术之一,它相对传统的逻辑导入导出要高效,这种特性更适合数据库对象数量巨大的情形,因为我日常 ...
- 【EXPDP/IMPDP】ORACLE数据泵导入导出案例(expdp & impdp)
概要: 因项目需要,通常需要将生产库下的部分数据抽取并恢复到测试库上 本文主要介绍数据泵导入导出的几种情况以及错误处理 案例环境: rhel-server-6.5-x86_64 oracle 11.2 ...
- Oracle数据泵导入导出数据,建立表空
Oracle11g 数据导入到oracle10g 中:1.在oracle11g 服务器命令行中用expdp 导出数据expdp ts/ts@orcl directory=expdp_dir dumpf ...
- 基于多用户的Oracle数据泵导入导出数据
登陆SqlPlus: SqlPlus sys/syspwd@MyOrcl AS sysdba 其中:syspwd:sys的登陆密码:MyOrcl:所创建的数据库服务名. 创建数据泵: create o ...
- oracle数据泵导入导出部分用户
问题描述:需要将140服务器中的tbomnew实例下的部分用户导入到118服务器下的tbompx实例中,本次导入导出的两个数据库均为19C 部分用户名:CORE,MSTDATA,BOMMGMT,CFG ...
- oracle数据泵导入导出
1.首先建立DUMP_DIR sqlplus / as sysdba select * from dba_directories 如果没有DUMP_DIR就执行下面的语句 CREATE OR REPL ...
- Oracle基础 exp/imp 数据泵导入/导出 命令
一.导出方式: 使用exp/imp方式导出数据分为四种方式: 1.表方式导出:一个或多个指定的表,包括表的定义.表数据.表的所有者授权.表索引.表约束,以及创建在该表上的触发器.也可以只导出结构,不导 ...
- oracle数据泵导入导出数据
expdp 导出 1.管理员用户登入sqlplus sqlplus system/manger@pdb1 2.创建逻辑导出目录 create directory dpdata as '/home/or ...
- Oracle 数据泵导入导出
imp zminfo/zminfo fromuser=zminfo touser=zminfo file=E:\zBONDDT.dmp log=e:\bonddt.log buffer=1000000 ...
随机推荐
- VM磁盘映射共享方法,要求文件系统必须一致
如果主机是window系统,那么虚拟机也应该是Windows系统,不然不起作用
- 局域网共享hfs 软件使用
前言 由于想从局域网同学电脑上偷点小片,又不想用u盘拷贝.所有在同学电脑上打开hfs软件,通过自己电脑ie浏览器(chrome不行报错)下载即可. 流程 1.两台电脑在同一局域网下,在同学电脑上打开h ...
- 【BZOJ4042】【CERC2014】parades 状压DP
题目大意 给你一棵\(n\)个点的树和\(m\)条路径要求你找出最多的路径,使得这些路径不共边.特别的,每个点的度数\(\leq 10\). \(n\leq 1000,m\leq \frac{n(n- ...
- MT【248】$f(x)=\dfrac{1}{x-1}+\dfrac{1}{x-b}$的性质
探讨函数$f(x)=\dfrac{1}{x-a}+\dfrac{1}{x-b}$其中$a<b$的几个性质 分析:对称性:关于$(\dfrac{a+b}{2},0)$证明提示:$f(x)+f(a+ ...
- 【hihocoder1167】高等理论计算机科学 (重链剖分 +树状数组)
Descroption 原题链接给你一棵\(~n~\)个点的树和\(~m~\)条链,求两两相交的链有多少对,两条链相交当且仅当有至少一个公共点.\(~1 \leq n, m \leq 10 ^ 5~\ ...
- Educational Codeforces Round 51 (Rated for Div. 2) G. Distinctification(线段树合并 + 并查集)
题意 给出一个长度为 \(n\) 序列 , 每个位置有 \(a_i , b_i\) 两个参数 , \(b_i\) 互不相同 ,你可以进行任意次如下的两种操作 : 若存在 \(j \not = i\) ...
- django从零开始-视图
1.处理的登录请求 views文章中添加登录函数login_action def login_action(request): if request.method == 'POST': usernam ...
- python列表转字符串
temp = "".join(sorted(arr[i])) arr[i] = temp
- 如何优雅的解决mac安装zsh不执行.bash_profile
最近刚刚重装了系统,并安装了优雅的shell命令工具zsh,突然发现我放在我的工作目录下的.bash_profile居然在启动的时候执行,导致我的java的一些配置没有注册到bash中.然后查资料得知 ...
- VS code golang 开发环境搭建
安装go (1)下载go安装程序 下载地址:https://golang.org/dl/(墙内下载地址http://www.golangtc.com/download),如果是您的系统是windows ...