Bo's Oracle Station

查看: 1356|回复: 0

传送表空间“自包含集”检查和目的地转换大小endian码

[复制链接]

1005

主题

1469

帖子

1万

积分

管理员

Rank: 9Rank: 9Rank: 9

积分
12012
发表于 2020-9-3 20:36:38 | 显示全部楼层 |阅读模式
  1. create tablespace tbs3 datafile '/u01/app/oracle/oradata/orcl2/tbs3.dbf' size 10M autoextend on maxsize 3G;

  2. select *
  3.   from dba_objects o
  4.   where o.owner='HR'  
  5.   order by 2;
  6.   
  7.   
  8.   create table hr.t062iu11_g  ( a number )  tablespace tbs3;
  9.   
  10.   insert into HR.t062iu11_g  values ( 999);
  11.   
  12.   commit;
  13.   
  14.   create index  hr.i062iu11_g   on HR.t062iu11_g (a)  tablespace users;
  15.   
  16.   create table hr.t062iu11_part ( a number )  tablespace tbs3
  17.   partition by range (a)
  18.   ( partition p1 values less than (100)  tablespace tbs3,
  19.     partition p2 values less than (maxvalue)  tablespace users );
  20.    
  21. insert into hr.t062iu11_part  values ( 99) ;

  22. insert into hr.t062iu11_part  values ( 100) ;

  23. commit;

  24. select  * from hr.t062iu11_part;

  25. select  * from hr.t062iu11_part   partition ( p1);

  26.   select  * from hr.t062iu11_part   partition ( p2);
  27.   
  28.   select  * from dba_segments
  29.     where segment_name ='T062IU11_PART';
  30.   
  31.   select * from  dba_objects  where object_name like 'DBMS%TTS';
  32.   desc dbms_tts;
  33.   
  34.   begin
  35.     dbms_tts.TRANSPORT_SET_CHECK('TBS3');
  36.   end;

  37. select  * from transport_set_violations;
  38.   
复制代码

-------


  1. [oracle@classroom orcl2]$ impdp system/oracle_4U directory=dir1 dumpfile=xtts2.dmp transport_datafiles='/u01/app/oracle/oradata/orcl/tbs3.dbf'

  2. Import: Release 12.1.0.2.0 - Production on Thu Sep 3 21:04:05 2020

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

  4. Connected to: Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production
  5. With the Partitioning, Automatic Storage Management, OLAP, Advanced Analytics
  6. and Real Application Testing options
  7. Master table "SYSTEM"."SYS_IMPORT_TRANSPORTABLE_01" successfully loaded/unloaded
  8. Source time zone is +00:00 and target time zone is +08:00.
  9. Starting "SYSTEM"."SYS_IMPORT_TRANSPORTABLE_01":  system/******** directory=dir1 dumpfile=xtts2.dmp transport_datafiles=/u01/app/oracle/oradata/orcl/tbs3.dbf
  10. Processing object type TRANSPORTABLE_EXPORT/PLUGTS_BLK
  11. ORA-39123: Data Pump transportable tablespace job aborted
  12. ORA-01565: error in identifying file '/u01/app/oracle/oradata/orcl/tbs3.dbf'
  13. ORA-27048: skgfifi: file header information is invalid
  14. Additional information: 13

  15. Job "SYSTEM"."SYS_IMPORT_TRANSPORTABLE_01" stopped due to fatal error at Thu Sep 3 21:04:15 2020 elapsed 0 00:00:05

  16. [oracle@classroom orcl2]$ rman target /

  17. Recovery Manager: Release 12.1.0.2.0 - Production on Thu Sep 3 21:04:41 2020

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

  19. connected to target database: ORCL (DBID=1574592120)

  20. RMAN> convert datafile '/u01/app/oracle/oradata/orcl/tbs3.dbf'  from platform 'Solaris[tm] OE (32-bit)'  format '/u01/app/oracle/oradata/orcl/tbs3-trans.dbf'
  21. 2> ;

  22. Starting conversion at target at 2020-09-03:21:07:21
  23. using target database control file instead of recovery catalog
  24. allocated channel: ORA_DISK_1
  25. channel ORA_DISK_1: SID=7 device type=DISK
  26. channel ORA_DISK_1: starting datafile conversion
  27. input file name=/u01/app/oracle/oradata/orcl/tbs3.dbf
  28. converted datafile=/u01/app/oracle/oradata/orcl/tbs3-trans.dbf
  29. channel ORA_DISK_1: datafile conversion complete, elapsed time: 00:00:01
  30. Finished conversion at target at 2020-09-03:21:07:24

  31. RMAN> exit


  32. Recovery Manager complete.
  33. [oracle@classroom orcl2]$ cd /u01/app/oracle/
  34. [oracle@classroom oracle]$ ls
  35. admin        cfgtoollogs  Clusterware  fast_recovery_area   man_recovery_area      oradiag_oracle  wallet
  36. audit        checkpoints  crsdata      flash_recovery_area  man_recovery_area.11g  product
  37. botangdir01  classroom    diag         log                  oradata                station90
  38. [oracle@classroom oracle]$ cd oradata/
  39. [oracle@classroom oradata]$ ls
  40. em12rep  orcl  orcl2  rcat  RCAT  rcat.11g  RCAT.11g  rcat.12c  RCAT.12c  rcat.12c.test  RCAT.12c.test
  41. [oracle@classroom oradata]$ cd orcl
  42. [oracle@classroom orcl]$ ls
  43. sysaux01.dbf  system01.dbf  tbs1.dbf  tbs2.dbf  tbs3.dbf  tbs3-trans.dbf  temp01.dbf  undotbs01.dbf  users01.dbf
  44. [oracle@classroom orcl]$ mv tbs3-trans.dbf tbs3.dbf
  45. [oracle@classroom orcl]$ impdp system/oracle_4U directory=dir1 dumpfile=xtts2.dmp transport_datafiles='/u01/app/oracle/oradata/orcl/tbs3.dbf'

  46. Import: Release 12.1.0.2.0 - Production on Thu Sep 3 21:08:25 2020

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

  48. Connected to: Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production
  49. With the Partitioning, Automatic Storage Management, OLAP, Advanced Analytics
  50. and Real Application Testing options
  51. Master table "SYSTEM"."SYS_IMPORT_TRANSPORTABLE_01" successfully loaded/unloaded
  52. Source time zone is +00:00 and target time zone is +08:00.
  53. Starting "SYSTEM"."SYS_IMPORT_TRANSPORTABLE_01":  system/******** directory=dir1 dumpfile=xtts2.dmp transport_datafiles=/u01/app/oracle/oradata/orcl/tbs3.dbf
  54. Processing object type TRANSPORTABLE_EXPORT/PLUGTS_BLK
  55. Processing object type TRANSPORTABLE_EXPORT/TABLE
  56. Processing object type TRANSPORTABLE_EXPORT/TABLE_STATISTICS
  57. Processing object type TRANSPORTABLE_EXPORT/STATISTICS/MARKER
  58. Processing object type TRANSPORTABLE_EXPORT/POST_INSTANCE/PLUGTS_BLK
  59. Job "SYSTEM"."SYS_IMPORT_TRANSPORTABLE_01" successfully completed at Thu Sep 3 21:08:55 2020 elapsed 0 00:00:29

  60. [oracle@classroom orcl]$
复制代码



回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

QQ|手机版|Bo's Oracle Station   

GMT+8, 2024-11-21 22:29 , Processed in 0.038149 second(s), 25 queries .

快速回复 返回顶部 返回列表