ORA-29341: The transportable set is not self-contained ORACLE 报错 故障修复 远程处理

文档解释

ORA-29341: The transportable set is not self-contained

Cause: The set of objects in the set of tablespaces selected are not self-contained.

Action: Consider using different export options, or removing some of the pointers that caused the violation, or selecting a different set of tablespaces.

ORA-29341错误表示Oracle数据库在运行过程中检测到当前传输集不是自包含,官方解释是当传输集中存在外部引用而不是保存在该传输集中时,ORA-29341会被触发。在某些特定场景使用expdp导出数据时,比如使用当前用户点号执行,或在导出和导入操作过程中没有使用fromuser和touser参数等,可能会出现ORA-29341错误。

常见案例

1. 如果用expdp以当前表空间(cusotmer)为参数导出数据库, 但是在cusotmer表空间中的表的schema引用的是其它表空间的对象,此时可能会出现ORA-29341;

2. 在用expdp导出table时,表的schema引用的是其它数据库的对象,此时也可能出现ORA-29341;

3. 如果数据表的schema引用的序列,存储过程等不在同一用户表空间,此时也会出现ORA-29341;

一般处理方法及步骤

1. 识别表空间中存在哪些类型的引用,如果发现是外部引用,则confirm以下三种情况:

a) expdp导出与导入设置相同的fromuser/touser;

b) 将对象复制到expdp中导出时所使用的表空间中;

c) 将对象使用相同的schema绑定,使他们能正确引用;

2. 设置进行expdp操作时的参数:

a) include=schema:引用的schema也同时导出,尽可能设置include的各个参数;

b) remap_schema:在expdp和impdp期间重新定义schema,确保在不同环境中能正常引用;

3. 将调整好的参数与新的对象一起写入一个脚本文件,随时准备启动expdp操作;


数据运维技术 » ORA-29341: The transportable set is not self-contained ORACLE 报错 故障修复 远程处理