zoukankan      html  css  js  c++  java
  • 数据泵导出报错ORA-31693 ORA-02354 ORA-01466

    1.Oracle数据泵导出schema时有报错:

    Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    Starting "SCOTT"."SYS_EXPORT_TABLE_01":  scott/******** flashback_scn=3072010 tables=t dumpfile=t.dmp logfile=t.log directory=expdp
    Estimate in progress using BLOCKS method...
    Processing object type TABLE_EXPORT/TABLE/TABLE_DATA
    Total estimation using BLOCKS method: 9 MB
    Processing object type TABLE_EXPORT/TABLE/TABLE
    Processing object type TABLE_EXPORT/TABLE/INDEX/INDEX
    Processing object type TABLE_EXPORT/TABLE/INDEX/STATISTICS/INDEX_STATISTICS
    Processing object type TABLE_EXPORT/TABLE/STATISTICS/TABLE_STATISTICS
    ORA-31693: Table data object "SCOTT"."T" failed to load/unload and is being skipped due to error:
    ORA-02354: error in exporting/importing data
    ORA-01466: unable to read data - table definition has changed
    Master table "SCOTT"."SYS_EXPORT_TABLE_01" successfully loaded/unloaded
    ******************************************************************************
    Dump file set for SCOTT.SYS_EXPORT_TABLE_01 is:
      /home/oracle/expdp/t.dmp
    Job "SCOTT"."SYS_EXPORT_TABLE_01" completed with 1 error(s) at 00:20:06

    2.经过分析报错:

    ORA-31693: Table data object "SCOTT"."T" failed to load/unload and is being skipped due to error:

    说明是T表导出报错

    ORA-01466: unable to read data - table definition has changed

    可以分析是该表现在的表结构和导出时该表的结构发生了变化

    3.重现该报错(测试环境还原场景)

    SYS@PROD4 >conn scott/tiger;
    Connected.
    SCOTT@PROD4 >select current_scn from v$database;

    CURRENT_SCN
    -----------
        3072010

    SCOTT@PROD4 >desc t;
     Name                               Null?    Type
     ----------------------------------------------------- -------- ------------------------------------
     OWNER                                VARCHAR2(30)
     OBJECT_NAME                            VARCHAR2(128)
     SUBOBJECT_NAME                         VARCHAR2(30)
     OBJECT_ID                            NUMBER
     DATA_OBJECT_ID                         NUMBER
     OBJECT_TYPE                            VARCHAR2(19)
     CREATED                            DATE
     LAST_DDL_TIME                            DATE
     TIMESTAMP                            VARCHAR2(19)
     STATUS                             VARCHAR2(7)
     TEMPORARY                            VARCHAR2(1)
     GENERATED                            VARCHAR2(1)
     SECONDARY                            VARCHAR2(1)
     NAMESPACE                            NUMBER
     EDITION_NAME                            VARCHAR2(30)

    SCOTT@PROD4 >alter table t add country varchar2(20);

    Table altered.

    SCOTT@PROD4 >desc t;
     Name                               Null?    Type
     ----------------------------------------------------- -------- ------------------------------------
     OWNER                                VARCHAR2(30)
     OBJECT_NAME                            VARCHAR2(128)
     SUBOBJECT_NAME                         VARCHAR2(30)
     OBJECT_ID                            NUMBER
     DATA_OBJECT_ID                         NUMBER
     OBJECT_TYPE                            VARCHAR2(19)
     CREATED                            DATE
     LAST_DDL_TIME                            DATE
     TIMESTAMP                            VARCHAR2(19)
     STATUS                             VARCHAR2(7)
     TEMPORARY                            VARCHAR2(1)
     GENERATED                            VARCHAR2(1)
     SECONDARY                            VARCHAR2(1)
     NAMESPACE                            NUMBER
     EDITION_NAME                            VARCHAR2(30)
     COUNTRY                            VARCHAR2(20)

    SCOTT@PROD4 >create directory expdp as '/home/oracle/expdp';

    Directory created.

    SCOTT@PROD4 >grant all on directory expdp to public;

    Grant succeeded.

    [oracle@edbjr2p2 ~]$ mkdir -p /home/oracle/expdp
    [oracle@edbjr2p2 ~]$ chmod 777 -R /home/oracle/expdp/

    [oracle@edbjr2p2 trace]$ expdp scott/tiger flashback_scn=3072010 tables=t dumpfile=t.dmp logfile=t.log directory=expdp

    Export: Release 11.2.0.3.0 - Production on Sun Feb 16 00:19:54 2020

    Copyright (c) 1982, 2011, Oracle and/or its affiliates.  All rights reserved.

    Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    Starting "SCOTT"."SYS_EXPORT_TABLE_01":  scott/******** flashback_scn=3072010 tables=t dumpfile=t.dmp logfile=t.log directory=expdp
    Estimate in progress using BLOCKS method...
    Processing object type TABLE_EXPORT/TABLE/TABLE_DATA
    Total estimation using BLOCKS method: 9 MB
    Processing object type TABLE_EXPORT/TABLE/TABLE
    Processing object type TABLE_EXPORT/TABLE/INDEX/INDEX
    Processing object type TABLE_EXPORT/TABLE/INDEX/STATISTICS/INDEX_STATISTICS
    Processing object type TABLE_EXPORT/TABLE/STATISTICS/TABLE_STATISTICS
    ORA-31693: Table data object "SCOTT"."T" failed to load/unload and is being skipped due to error:
    ORA-02354: error in exporting/importing data
    ORA-01466: unable to read data - table definition has changed
    Master table "SCOTT"."SYS_EXPORT_TABLE_01" successfully loaded/unloaded
    ******************************************************************************
    Dump file set for SCOTT.SYS_EXPORT_TABLE_01 is:
      /home/oracle/expdp/t.dmp
    Job "SCOTT"."SYS_EXPORT_TABLE_01" completed with 1 error(s) at 00:20:06

  • 相关阅读:
    HDU 5495:LCS
    关于使用了cudaMallocHost之后发生 segment fault的原因
    关于grub 损坏的问题
    LightOJ
    LightOJ
    poj3268--Silver Cow Party (最短路+技巧)
    hdoj1443--Joseph (约瑟夫环)
    poj2549--Sumsets (sum)
    UVA11080
    hdoj1548--A strange lift(bfs.)
  • 原文地址:https://www.cnblogs.com/gw666/p/12316188.html
Copyright © 2011-2022 走看看