现场FLASHBACK_SCN=与expdp的导出,总担心报错,在家做实验
[oracle@oratest expdpdir]$ expdp \"/ as sysdba\" directory=dpdata dumpfile=mydb_%U.dmp schemas=scott exclude=TABLE:\"IN\(\'EMP\',\'DEPT\'\)\" FLASHBACK_SCN=1346341
Export: Release 11.2.0.4.0 - Production on Sat Nov 1 15:55:18 2014
Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved.
Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
Starting "SYS"."SYS_EXPORT_SCHEMA_01": "/******** AS SYSDBA" directory=dpdata dumpfile=mydb_%U.dmp schemas=scott exclude=TABLE:"IN('EMP','DEPT')" FLASHBACK_SCN=1346341
Estimate in progress using BLOCKS method...
Processing object type SCHEMA_EXPORT/TABLE/TABLE_DATA
Total estimation using BLOCKS method: 34.18 MB
Processing object type SCHEMA_EXPORT/USER
Processing object type SCHEMA_EXPORT/SYSTEM_GRANT
Processing object type SCHEMA_EXPORT/ROLE_GRANT
Processing object type SCHEMA_EXPORT/DEFAULT_ROLE
Processing object type SCHEMA_EXPORT/PRE_SCHEMA/PROCACT_SCHEMA
Processing object type SCHEMA_EXPORT/TABLE/TABLE
Processing object type SCHEMA_EXPORT/TABLE/CONSTRAINT/CONSTRAINT
Processing object type SCHEMA_EXPORT/TABLE/INDEX/STATISTICS/INDEX_STATISTICS
Processing object type SCHEMA_EXPORT/TABLE/STATISTICS/TABLE_STATISTICS
ORA-31693: Table data object "SCOTT"."TEST4" 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
. . exported "SCOTT"."DINYA_TEST":"PART_01" 6.015 KB 0 rows
. . exported "SCOTT"."DINYA_TEST":"PART_02" 6.070 KB 2 rows
. . exported "SCOTT"."DINYA_TEST":"PART_03" 6.117 KB 4 rows
. . exported "SCOTT"."BONUS" 5.929 KB 0 rows
. . exported "SCOTT"."SALGRADE" 5.679 KB 5 rows
. . exported "SCOTT"."TEST3" 4.976 KB 3 rows
Master table "SYS"."SYS_EXPORT_SCHEMA_01" successfully loaded/unloaded
******************************************************************************
Dump file set for SYS.SYS_EXPORT_SCHEMA_01 is:
/home/oracle/expdpdir/mydb_01.dmp
Job "SYS"."SYS_EXPORT_SCHEMA_01" completed with 1 error(s) at Sat Nov 1 15:55:26 2014 elapsed 0 00:00:07
[oracle@oratest expdpdir]$ ll
total 260
-rw-r--r-- 1 oracle oinstall 2170 Nov 1 15:55 export.log
-rw-r----- 1 oracle oinstall 258048 Nov 1 15:55 mydb_01.dmp
[oracle@oratest expdpdir]$ rm -f *
[oracle@oratest expdpdir]$ rm -rf *
[oracle@oratest expdpdir]$ expdp \"/ as sysdba\" directory=dpdata dumpfile=mydb_%U.dmp schemas=scott exclude=TABLE:\"IN\(\'EMP\',\'DEPT\'\)\" FLASHBACK_SCN=1346341
Export: Release 11.2.0.4.0 - Production on Sat Nov 1 15:55:52 2014
Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved.
Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
Starting "SYS"."SYS_EXPORT_SCHEMA_01": "/******** AS SYSDBA" directory=dpdata dumpfile=mydb_%U.dmp schemas=scott exclude=TABLE:"IN('EMP','DEPT')" FLASHBACK_SCN=1346341
Estimate in progress using BLOCKS method...
Processing object type SCHEMA_EXPORT/TABLE/TABLE_DATA
Total estimation using BLOCKS method: 24.18 MB
Processing object type SCHEMA_EXPORT/USER
Processing object type SCHEMA_EXPORT/SYSTEM_GRANT
Processing object type SCHEMA_EXPORT/ROLE_GRANT
Processing object type SCHEMA_EXPORT/DEFAULT_ROLE
Processing object type SCHEMA_EXPORT/PRE_SCHEMA/PROCACT_SCHEMA
Processing object type SCHEMA_EXPORT/TABLE/TABLE
Processing object type SCHEMA_EXPORT/TABLE/CONSTRAINT/CONSTRAINT
Processing object type SCHEMA_EXPORT/TABLE/INDEX/STATISTICS/INDEX_STATISTICS
Processing object type SCHEMA_EXPORT/TABLE/STATISTICS/TABLE_STATISTICS
. . exported "SCOTT"."DINYA_TEST":"PART_01" 6.015 KB 0 rows
. . exported "SCOTT"."DINYA_TEST":"PART_02" 6.070 KB 2 rows
. . exported "SCOTT"."DINYA_TEST":"PART_03" 6.117 KB 4 rows
. . exported "SCOTT"."BONUS" 5.929 KB 0 rows
. . exported "SCOTT"."SALGRADE" 5.679 KB 5 rows
. . exported "SCOTT"."TEST3" 4.976 KB 3 rows
Master table "SYS"."SYS_EXPORT_SCHEMA_01" successfully loaded/unloaded
******************************************************************************
Dump file set for SYS.SYS_EXPORT_SCHEMA_01 is:
/home/oracle/expdpdir/mydb_01.dmp
Job "SYS"."SYS_EXPORT_SCHEMA_01" successfully completed at Sat Nov 1 15:56:01 2014 elapsed 0 00:00:07
&&&&&& 数据库表的创建
SQL> create table scott.test4 as select * from dba_objects;
Table created.
SQL> drop table scott.test4;
Table dropped.
SQL>
&&&&&&&&&&& truncat 后
[oracle@oratest expdpdir]$ expdp \"/ as sysdba\" directory=dpdata dumpfile=mydb_%U.dmp schemas=scott exclude=TABLE:\"IN\(\'EMP\',\'DEPT\'\)\" FLASHBACK_SCN=1346341
Export: Release 11.2.0.4.0 - Production on Sat Nov 1 16:00:30 2014
Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved.
Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
Starting "SYS"."SYS_EXPORT_SCHEMA_01": "/******** AS SYSDBA" directory=dpdata dumpfile=mydb_%U.dmp schemas=scott exclude=TABLE:"IN('EMP','DEPT')" FLASHBACK_SCN=1346341
Estimate in progress using BLOCKS method...
Processing object type SCHEMA_EXPORT/TABLE/TABLE_DATA
Total estimation using BLOCKS method: 24.18 MB
Processing object type SCHEMA_EXPORT/USER
Processing object type SCHEMA_EXPORT/SYSTEM_GRANT
Processing object type SCHEMA_EXPORT/ROLE_GRANT
Processing object type SCHEMA_EXPORT/DEFAULT_ROLE
Processing object type SCHEMA_EXPORT/PRE_SCHEMA/PROCACT_SCHEMA
Processing object type SCHEMA_EXPORT/TABLE/TABLE
Processing object type SCHEMA_EXPORT/TABLE/CONSTRAINT/CONSTRAINT
Processing object type SCHEMA_EXPORT/TABLE/INDEX/STATISTICS/INDEX_STATISTICS
Processing object type SCHEMA_EXPORT/TABLE/STATISTICS/TABLE_STATISTICS
. . exported "SCOTT"."DINYA_TEST":"PART_01" 6.015 KB 0 rows
. . exported "SCOTT"."DINYA_TEST":"PART_02" 6.070 KB 2 rows
. . exported "SCOTT"."DINYA_TEST":"PART_03" 6.117 KB 4 rows
. . exported "SCOTT"."BONUS" 5.929 KB 0 rows
. . exported "SCOTT"."SALGRADE" 5.679 KB 5 rows
ORA-31693: Table data object "SCOTT"."TEST3" 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 "SYS"."SYS_EXPORT_SCHEMA_01" successfully loaded/unloaded
******************************************************************************
Dump file set for SYS.SYS_EXPORT_SCHEMA_01 is:
/home/oracle/expdpdir/mydb_01.dmp
Job "SYS"."SYS_EXPORT_SCHEMA_01" completed with 1 error(s) at Sat Nov 1 16:00:40 2014 elapsed 0 00:00:09
***************用完回滚段
[oracle@oratest expdpdir]$ expdp \"/ as sysdba\" directory=dpdata dumpfile=mydb_%U.dmp schemas=scott exclude=TABLE:\"IN\(\'EMP\',\'DEPT\'\)\" FLASHBACK_SCN=1370446
Export: Release 11.2.0.4.0 - Production on Sat Nov 1 16:12:19 2014
Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved.
Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
ORA-31626: job does not exist
ORA-31637: cannot create job SYS_EXPORT_SCHEMA_01 for user SYS
ORA-06512: at "SYS.DBMS_SYS_ERROR", line 95
ORA-06512: at "SYS.KUPV$FT_INT", line 798
ORA-39080: failed to create queues "KUPC$C_1_20141101161219" and "KUPC$S_1_20141101161219" for Data Pump job
ORA-06512: at "SYS.DBMS_SYS_ERROR", line 95
ORA-06512: at "SYS.KUPC$QUE_INT", line 1534
ORA-00604: error occurred at recursive SQL level 2
ORA-30036: unable to extend segment by 8 in undo tablespace 'UNDO1'
--再次释放回滚段
[oracle@oratest expdpdir]$ expdp \"/ as sysdba\" directory=dpdata dumpfile=mydb_%U.dmp schemas=scott exclude=TABLE:\"IN\(\'EMP\',\'DEPT\'\)\" FLASHBACK_SCN=1370446
Export: Release 11.2.0.4.0 - Production on Sat Nov 1 16:13:21 2014
Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved.
Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
Starting "SYS"."SYS_EXPORT_SCHEMA_01": "/******** AS SYSDBA" directory=dpdata dumpfile=mydb_%U.dmp schemas=scott exclude=TABLE:"IN('EMP','DEPT')" FLASHBACK_SCN=1370446
Estimate in progress using BLOCKS method...
Processing object type SCHEMA_EXPORT/TABLE/TABLE_DATA
Total estimation using BLOCKS method: 553.1 MB
Processing object type SCHEMA_EXPORT/USER
Processing object type SCHEMA_EXPORT/SYSTEM_GRANT
Processing object type SCHEMA_EXPORT/ROLE_GRANT
Processing object type SCHEMA_EXPORT/DEFAULT_ROLE
Processing object type SCHEMA_EXPORT/PRE_SCHEMA/PROCACT_SCHEMA
Processing object type SCHEMA_EXPORT/TABLE/TABLE
Processing object type SCHEMA_EXPORT/TABLE/CONSTRAINT/CONSTRAINT
Processing object type SCHEMA_EXPORT/TABLE/INDEX/STATISTICS/INDEX_STATISTICS
Processing object type SCHEMA_EXPORT/TABLE/STATISTICS/TABLE_STATISTICS
ORA-31693: Table data object "SCOTT"."TEST5" 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 16 with name "_SYSSMU16_62169813$" too small
. . exported "SCOTT"."DINYA_TEST":"PART_01" 6.015 KB 0 rows
. . exported "SCOTT"."DINYA_TEST":"PART_02" 6.070 KB 2 rows
. . exported "SCOTT"."DINYA_TEST":"PART_03" 6.117 KB 4 rows
. . exported "SCOTT"."BONUS" 5.929 KB 0 rows
. . exported "SCOTT"."SALGRADE" 5.679 KB 5 rows
. . exported "SCOTT"."TEST3" 4.929 KB 0 rows
Master table "SYS"."SYS_EXPORT_SCHEMA_01" successfully loaded/unloaded
******************************************************************************
Dump file set for SYS.SYS_EXPORT_SCHEMA_01 is:
/home/oracle/expdpdir/mydb_01.dmp
Job "SYS"."SYS_EXPORT_SCHEMA_01" completed with 1 error(s) at Sat Nov 1 16:13:41 2014 elapsed 0 00:00:18
[oracle@oratest expdpdir]$ ll
total 8464
-rw-r--r-- 1 oracle oinstall 2206 Nov 1 16:13 export.log
-rw-r----- 1 oracle oinstall 8646656 Nov 1 16:13 mydb_01.dmp