IMP-00009: abnormal end of export file

在测试环境需要迁移点数据,从12.1.0.2 到12.2.0.1,使用expdp/impdp工具没有任何问题,但使用exp/imp工具时报错。错误日志如下:

. importing TEST's objects into TEST
. . importing table "DEPT" 2 rows imported
. . importing table "EMP" 3 rows imported
. . importing table "M1" 1000 rows imported
. . importing table "M2" 1000 rows imported
. . importing table "M3" 1000 rows imported
. . importing table "M4" 2000 rows imported
. . importing table "M5" 1000 rows imported
. . importing table "M6"
IMP-00009: abnormal end of export file
Import terminated successfully with warnings.

可以看出,在处理test.m6这张表的时候提示dmp文件有问题。test.m6这张表是一张空表,没有插入过任何数据。expdp/impdp工具迁移相同的数据没有问题,这说明是exp/imp工具的问题。

 

搜索了下MOS。找到篇文章:ALERT: Direct Path Export (EXP) Corrupts The Dump If An Empty Table Partition Exists (Doc ID 1604983.1)

大概意思是:当源端数据库存在空表或者空分区,并且使用exp工具导出数据时,使用direct=y参数,则在imp的过程中会出现这个错误。

 

解决办法有3种:

(1).导出时不要指定direct=n

(2). 如果非要指定direct=y,则导出之前物化那些空表或空分区,命令如下所示:

connect / as sysdba
exec dbms_space_admin.materialize_deferred_segments (schema_name => 'TEST', table_name => 'PART001', partition_name => 'P002');

(3). 使用expdp/impdp工具。

 

posted @   石云华  阅读(1341)  评论(0编辑  收藏  举报
编辑推荐:
· Linux系列:如何用heaptrack跟踪.NET程序的非托管内存泄露
· 开发者必知的日志记录最佳实践
· SQL Server 2025 AI相关能力初探
· Linux系列:如何用 C#调用 C方法造成内存泄露
· AI与.NET技术实操系列(二):开始使用ML.NET
阅读排行:
· 【自荐】一款简洁、开源的在线白板工具 Drawnix
· 没有Manus邀请码?试试免邀请码的MGX或者开源的OpenManus吧
· 无需6万激活码!GitHub神秘组织3小时极速复刻Manus,手把手教你使用OpenManus搭建本
· C#/.NET/.NET Core优秀项目和框架2025年2月简报
· DeepSeek在M芯片Mac上本地化部署
点击右上角即可分享
微信分享提示