码迷,mamicode.com
首页 > 其他好文 > 详细

Data Pump Export 数据泵导出因ORA-31693 ORA-02354 和 ORA-01555 错误且没有LOB损坏而失败 (Doc ID 1507116.1)

时间:2019-12-01 12:03:59      阅读:115      评论:0      收藏:0      [点我收藏+]

标签:under   number   ram   dba   column   export   步骤   long   not   

Data Pump Export Fails With ORA-31693 ORA-02354 and ORA-01555 Errors And No LOB Corruption (Doc ID 1507116.1)

APPLIES TO:

Oracle Database Cloud Schema Service - Version N/A and later
Oracle Database Exadata Cloud Machine - Version N/A and later
Oracle Cloud Infrastructure - Database Service - Version N/A and later
Oracle Database Backup Service - Version N/A and later
Oracle Database Exadata Express Cloud Service - Version N/A and later
Information in this document applies to any platform.

SYMPTOMS

You are exporting your applications database using Data Pump (expdp), and all is exporting fine, except one table fails to export with the following errors:

您正在使用数据泵(expdp)导出应用程序数据库,并且一切正常,但一个表无法导出却出现以下错误:

ORA-31693: Table data object "<SCHEMA_NAME>"."<TABLE_NAME>" failed to load/unload and is being skipped due to error:
ORA-02354: error in exporting/importing data
ORA-01555: snapshot too old: rollback segment number 154 with name "<ROLLBACK_SEGMENT_NAME>" too small

You suspected that you may have had LOB corruption and followed the steps from Note:452341.1 or Note:787004.1, but no corruption is found in the LOB.

您怀疑您可能已发生LOB损坏,并遵循了Note:452341.1Note:787004.1中的步骤,但是在LOB中未发现损坏

CHANGES

CAUSE

The LOB Retention is not defined properly.  LOB保留的定义不正确

This is confirmed by the queries:  通过查询确认

SQL> show parameter undo;

NAME                                 TYPE        VALUE
------------------------------------ ----------- ------------------------------
undo_management                      string      AUTO
undo_retention                       integer     900
undo_tablespace                      string      UNDOTBS1


SQL> select max(maxquerylen) from v$undostat;

MAX(MAXQUERYLEN)
----------------
16331

SQL> select retention from dba_lobs where owner=‘<SCHEMA_NAME>‘ and table_name=‘<TABLE_NAME>‘;

RETENTION
----------
900

 

We see the retention comes back showing 900 seconds (15 minutes) which is the same as the current UNDO_RETENTION, but the maxquery length is 16331 seconds.

我们看到保留时间返回,显示为900秒(15分钟),与当前的UNDO_RETENTION相同,但是maxquery的长度为16331秒

When the LOB was created, the actual setting for RETENTION was defined by the current setting for UNDO_RETENTION.

创建LOB时,RETENTION的实际设置由UNDO_RETENTION的当前设置定义

This time is not long enough.  这个时间还不够长。

SOLUTION

1. Modify the current UNDO_RETENTION for the database:

1. 修改数据库的当前UNDO_RETENTION

SQL>ALTER SYSTEM SET UNDO_RETENTION = 16500 scope=both sid=‘*‘;

    Note: For versions =< 10.2.0.5, an instance restart is required because LOB retention does not change when undo_retention is changed. See further details from Document 563470.1 which shows that retention is not changed until after a restart.

    注意:对于版本= <10.2.0.5,需要重新启动实例,因为更改undo_retention时LOB保留不会更改。请参阅文档563470.1中的更多详细信息,该文档显示保留直到重新启动后才更改。

2. Modify the LOB retention to become greater than the undersized retention parameter following the steps from Note:563470.1

2. 按照注:563470.1中的步骤,修改LOB保留,使其大于大小不足的保留参数。

SQL> alter table <SCHEMA_NAME>.<TABLE_NAME> modify lob(<LOB_COLUMN_NAME>) (pctversion 5);
Table altered.

SQL> alter table <SCHEMA_NAME>.<TABLE_NAME> modify lob(<LOB_COLUMN_NAME>) (retention);
Table altered.

3.  Query the lob retention again to verify that the change has taken hold:

3.再次查询lob保留,以确认更改已生效:

SQL> select retention from dba_lobs where owner=‘<SCHEMA_NAME>‘ and table_name=‘<TABLE_NAME>‘;

RETENTION
----------
16500

4. Perform the export again.  再次执行导出。

REFERENCES

NOTE:787004.1 - Export Receives The Errors ORA-1555 ORA-22924 ORA-1578 ORA-22922
NOTE:563470.1 - Lob retention not changing when undo_retention is changed
NOTE:452341.1 - ORA-01555 And Other Errors while Exporting Table With LOBs, How To Detect Lob Corruption.

Data Pump Export 数据泵导出因ORA-31693 ORA-02354 和 ORA-01555 错误且没有LOB损坏而失败 (Doc ID 1507116.1)

标签:under   number   ram   dba   column   export   步骤   long   not   

原文地址:https://www.cnblogs.com/zylong-sys/p/11965239.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!