impdp工具(8)

加密导出文件

# 只指定加密范围(ENCRYPTION),必须开启wallet,否则报错 $ expdp hr/hr DIRECTORY=datapump SCHEMAS=hr DUMPFILE=hr.dmp ENCRYPTION=all LOGFILE=hr.log JOB_NAME=hr Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options ORA-39002: invalid operation ORA-39188: unable to encrypt dump file set ORA-28365: wallet is not open # 开启wallet ' 1.查询存储wallet文件目录是否创建 SQL@dbabd> select * from v$encryption_wallet; WRL_TYPE WRL_PARAMETER STATUS -------------------- ---------------------------------------- ------------------ file /data/app/oracle/admin/dbabd/wallet CLOSED $ ll /data/app/oracle/admin/dbabd/wallet ls: cannot access /data/app/oracle/admin/dbabd/wallet: No such file or directory 2.创建目录 $ mkdir -pv /data/app/oracle/admin/dbabd/wallet mkdir: created directory ‘/data/app/oracle/admin/dbabd/wallet’ 3.开启wallet SYS@dbabd> alter system set encryption key identified by oracle; System altered. SQL@dbabd> select * from v$encryption_wallet; WRL_TYPE WRL_PARAMETER STATUS -------------------- ---------------------------------------- ------------------ file /data/app/oracle/admin/dbabd/wallet OPEN $ ls /data/app/oracle/admin/dbabd/wallet ewallet.p12 ' # 只指定加密密码(ENCRYPTION_PASSWORD),加密范围(ENCRYPTION)默认为ALL $ expdp hr/hr DIRECTORY=datapump SCHEMAS=hr DUMPFILE=hr.dmp ENCRYPTION_PASSWORD=oracle LOGFILE=hr.log JOB_NAME=hr # 指定加密范围(ENCRYPTION),同时指定加密密码(ENCRYPTION_PASSWORD),wallet不需要开启 $ expdp hr/hr DIRECTORY=datapump SCHEMAS=hr DUMPFILE=hr.dmp ENCRYPTION=all ENCRYPTION_PASSWORD=oracle LOGFILE=hr.log JOB_NAME=hr

预估导出所需空间大小

$ expdp hr/hr SCHEMAS=hr DIRECTORY=datapump ESTIMATE=statistics ESTIMATE_ONLY=yes JOB_NAME=hr impdp工具

内容版权声明:除非注明,否则皆为本站原创文章。

转载注明出处:https://www.heiqu.com/c5f5211542d385175e71281df8fffac0.html