|
图形界面做Dataguard请务必验证一下:
在转换最大可用模式之前,必须验证通过:
主库和备库的属性都要改:
TSPITR:
做自包含集检查,并处理:
查询物化视图:
- select * from dba_mviews mv
- where mv.MVIEW_NAME in (
- select s.segment_name from dba_segments s
- where s.tablespace_name='USERS'
- );
复制代码- drop materialized view log on hr.TAB1;
复制代码
自动克隆了一个实例:
- [root@station90 ~]# ps aux | grep ora_smon
- oracle 15057 0.0 0.2 523720 40584 ? Ss 20:43 0:00 ora_smon_Agrx
- root 15352 0.0 0.0 103308 2032 pts/11 S+ 20:45 0:00 grep ora_smon
- oracle 27168 0.0 1.2 6795216 200232 ? Ss 20:11 0:00 ora_smon_orcl
复制代码
TSPITR:
- [oracle@station90 ~]$ export NLS_DATE_FORMAT='YYYY-MM-DD:HH24:MI:SS'
- [oracle@station90 ~]$ rman target /
- Recovery Manager: Release 11.2.0.3.0 - Production on Mon Jul 23 21:44:23 2018
- Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved.
- connected to target database: ORCL (DBID=1343950367)
- RMAN> recover tablespace users
- 2> until time '2018-07-23:21:43:18'
- 3> auxiliary destination '/u01/app/oracle/oradata';
- Starting recover at 2018-07-23:21:45:03
- using target database control file instead of recovery catalog
- allocated channel: ORA_DISK_1
- channel ORA_DISK_1: SID=78 device type=DISK
- allocated channel: ORA_DISK_2
- channel ORA_DISK_2: SID=9 device type=DISK
- allocated channel: ORA_DISK_3
- channel ORA_DISK_3: SID=76 device type=DISK
- allocated channel: ORA_DISK_4
- channel ORA_DISK_4: SID=143 device type=DISK
- allocated channel: ORA_DISK_5
- channel ORA_DISK_5: SID=202 device type=DISK
- allocated channel: ORA_DISK_6
- channel ORA_DISK_6: SID=11 device type=DISK
- allocated channel: ORA_DISK_7
- channel ORA_DISK_7: SID=73 device type=DISK
- allocated channel: ORA_DISK_8
- channel ORA_DISK_8: SID=14 device type=DISK
- allocated channel: ORA_SBT_TAPE_1
- channel ORA_SBT_TAPE_1: SID=71 device type=SBT_TAPE
- channel ORA_SBT_TAPE_1: Oracle Secure Backup
- allocated channel: ORA_SBT_TAPE_2
- channel ORA_SBT_TAPE_2: SID=75 device type=SBT_TAPE
- channel ORA_SBT_TAPE_2: Oracle Secure Backup
- RMAN-05026: WARNING: presuming following set of tablespaces applies to specified point-in-time
- List of tablespaces expected to have UNDO segments
- Tablespace SYSTEM
- Tablespace UNDOTBS1
- Creating automatic instance, with SID='BcBD'
- initialization parameters used for automatic instance:
- db_name=ORCL
- db_unique_name=BcBD_tspitr_ORCL
- compatible=11.2.0.0.0
- db_block_size=8192
- db_files=200
- sga_target=280M
- processes=50
- db_create_file_dest=/u01/app/oracle/oradata
- log_archive_dest_1='location=/u01/app/oracle/oradata'
- #No auxiliary parameter file used
- starting up automatic instance ORCL
- Oracle instance started
- Total System Global Area 292278272 bytes
- Fixed Size 2227744 bytes
- Variable Size 100663776 bytes
- Database Buffers 184549376 bytes
- Redo Buffers 4837376 bytes
- Automatic instance created
- Running TRANSPORT_SET_CHECK on recovery set tablespaces
- TRANSPORT_SET_CHECK completed successfully
- contents of Memory Script:
- {
- # set requested point in time
- set until time "2018-07-23:21:43:18";
- # restore the controlfile
- restore clone controlfile;
- # mount the controlfile
- sql clone 'alter database mount clone database';
- # archive current online log
- sql 'alter system archive log current';
- # avoid unnecessary autobackups for structural changes during TSPITR
- sql 'begin dbms_backup_restore.AutoBackupFlag(FALSE); end;';
- }
- executing Memory Script
- executing command: SET until clause
- Starting restore at 2018-07-23:21:45:50
- allocated channel: ORA_AUX_DISK_1
- channel ORA_AUX_DISK_1: SID=80 device type=DISK
- allocated channel: ORA_AUX_DISK_2
- channel ORA_AUX_DISK_2: SID=5 device type=DISK
- allocated channel: ORA_AUX_DISK_3
- channel ORA_AUX_DISK_3: SID=30 device type=DISK
- allocated channel: ORA_AUX_DISK_4
- channel ORA_AUX_DISK_4: SID=56 device type=DISK
- allocated channel: ORA_AUX_DISK_5
- channel ORA_AUX_DISK_5: SID=81 device type=DISK
- allocated channel: ORA_AUX_DISK_6
- channel ORA_AUX_DISK_6: SID=6 device type=DISK
- allocated channel: ORA_AUX_DISK_7
- channel ORA_AUX_DISK_7: SID=31 device type=DISK
- allocated channel: ORA_AUX_DISK_8
- channel ORA_AUX_DISK_8: SID=57 device type=DISK
- allocated channel: ORA_AUX_SBT_TAPE_1
- channel ORA_AUX_SBT_TAPE_1: SID=82 device type=SBT_TAPE
- channel ORA_AUX_SBT_TAPE_1: Oracle Secure Backup
- allocated channel: ORA_AUX_SBT_TAPE_2
- channel ORA_AUX_SBT_TAPE_2: SID=7 device type=SBT_TAPE
- channel ORA_AUX_SBT_TAPE_2: Oracle Secure Backup
- channel ORA_AUX_DISK_1: starting datafile backup set restore
- channel ORA_AUX_DISK_1: restoring control file
- channel ORA_AUX_DISK_1: reading from backup piece +FRA/orcl/autobackup/2018_07_23/s_982272726.326.982272727
- channel ORA_AUX_DISK_1: piece handle=+FRA/orcl/autobackup/2018_07_23/s_982272726.326.982272727 tag=TAG20180723T213205
- channel ORA_AUX_DISK_1: restored backup piece 1
- channel ORA_AUX_DISK_1: restore complete, elapsed time: 00:00:01
- output file name=/u01/app/oracle/oradata/ORCL/controlfile/o1_mf_focq0r3q_.ctl
- Finished restore at 2018-07-23:21:46:00
- sql statement: alter database mount clone database
- sql statement: alter system archive log current
- sql statement: begin dbms_backup_restore.AutoBackupFlag(FALSE); end;
- contents of Memory Script:
- {
- # set requested point in time
- set until time "2018-07-23:21:43:18";
- plsql <<<-- tspitr_2
- declare
- sqlstatement varchar2(512);
- offline_not_needed exception;
- pragma exception_init(offline_not_needed, -01539);
- begin
- sqlstatement := 'alter tablespace '|| 'USERS' ||' offline immediate';
- krmicd.writeMsg(6162, sqlstatement);
- krmicd.execSql(sqlstatement);
- exception
- when offline_not_needed then
- null;
- end; >>>;
- # set destinations for recovery set and auxiliary set datafiles
- set newname for clone datafile 1 to new;
- set newname for clone datafile 3 to new;
- set newname for clone datafile 2 to new;
- set newname for clone tempfile 1 to new;
- set newname for datafile 4 to
- "+DATA/orcl/datafile/users.259.816169553";
- # switch all tempfiles
- switch clone tempfile all;
- # restore the tablespaces in the recovery set and the auxiliary set
- restore clone datafile 1, 3, 2, 4;
- switch clone datafile all;
- }
- executing Memory Script
- executing command: SET until clause
- sql statement: alter tablespace USERS offline immediate
- executing command: SET NEWNAME
- executing command: SET NEWNAME
- executing command: SET NEWNAME
- executing command: SET NEWNAME
- executing command: SET NEWNAME
- renamed tempfile 1 to /u01/app/oracle/oradata/ORCL/datafile/o1_mf_temp_%u_.tmp in control file
- Starting restore at 2018-07-23:21:46:06
- using channel ORA_AUX_DISK_1
- using channel ORA_AUX_DISK_2
- using channel ORA_AUX_DISK_3
- using channel ORA_AUX_DISK_4
- using channel ORA_AUX_DISK_5
- using channel ORA_AUX_DISK_6
- using channel ORA_AUX_DISK_7
- using channel ORA_AUX_DISK_8
- using channel ORA_AUX_SBT_TAPE_1
- using channel ORA_AUX_SBT_TAPE_2
- channel ORA_AUX_SBT_TAPE_1: starting datafile backup set restore
- channel ORA_AUX_SBT_TAPE_1: specifying datafile(s) to restore from backup set
- channel ORA_AUX_SBT_TAPE_1: restoring datafile 00001 to /u01/app/oracle/oradata/ORCL/datafile/o1_mf_system_%u_.dbf
- channel ORA_AUX_SBT_TAPE_1: reading from backup piece 1rt88jb3_1_1
- channel ORA_AUX_SBT_TAPE_2: starting datafile backup set restore
- channel ORA_AUX_SBT_TAPE_2: specifying datafile(s) to restore from backup set
- channel ORA_AUX_SBT_TAPE_2: restoring datafile 00003 to /u01/app/oracle/oradata/ORCL/datafile/o1_mf_undotbs1_%u_.dbf
- channel ORA_AUX_SBT_TAPE_2: restoring datafile 00002 to /u01/app/oracle/oradata/ORCL/datafile/o1_mf_sysaux_%u_.dbf
- channel ORA_AUX_SBT_TAPE_2: restoring datafile 00004 to +DATA/orcl/datafile/users.259.816169553
- channel ORA_AUX_SBT_TAPE_2: reading from backup piece 1qt88jb3_1_1
- channel ORA_AUX_SBT_TAPE_1: piece handle=1rt88jb3_1_1 tag=100T_WHOLE_FULL
- channel ORA_AUX_SBT_TAPE_1: restored backup piece 1
- channel ORA_AUX_SBT_TAPE_1: restore complete, elapsed time: 00:00:35
- channel ORA_AUX_SBT_TAPE_2: piece handle=1qt88jb3_1_1 tag=100T_WHOLE_FULL
- channel ORA_AUX_SBT_TAPE_2: restored backup piece 1
- channel ORA_AUX_SBT_TAPE_2: restore complete, elapsed time: 00:00:35
- Finished restore at 2018-07-23:21:46:42
- datafile 1 switched to datafile copy
- input datafile copy RECID=8 STAMP=982273603 file name=/u01/app/oracle/oradata/ORCL/datafile/o1_mf_system_focq1l57_.dbf
- datafile 3 switched to datafile copy
- input datafile copy RECID=9 STAMP=982273603 file name=/u01/app/oracle/oradata/ORCL/datafile/o1_mf_undotbs1_focq1q5x_.dbf
- datafile 2 switched to datafile copy
- input datafile copy RECID=10 STAMP=982273603 file name=/u01/app/oracle/oradata/ORCL/datafile/o1_mf_sysaux_focq1q59_.dbf
- contents of Memory Script:
- {
- # set requested point in time
- set until time "2018-07-23:21:43:18";
- # online the datafiles restored or switched
- sql clone "alter database datafile 1 online";
- sql clone "alter database datafile 3 online";
- sql clone "alter database datafile 2 online";
- sql clone "alter database datafile 4 online";
- # recover and open resetlogs
- recover clone database tablespace "USERS", "SYSTEM", "UNDOTBS1", "SYSAUX" delete archivelog;
- alter clone database open resetlogs;
- }
- executing Memory Script
- executing command: SET until clause
- sql statement: alter database datafile 1 online
- sql statement: alter database datafile 3 online
- sql statement: alter database datafile 2 online
- sql statement: alter database datafile 4 online
- Starting recover at 2018-07-23:21:46:43
- using channel ORA_AUX_DISK_1
- using channel ORA_AUX_DISK_2
- using channel ORA_AUX_DISK_3
- using channel ORA_AUX_DISK_4
- using channel ORA_AUX_DISK_5
- using channel ORA_AUX_DISK_6
- using channel ORA_AUX_DISK_7
- using channel ORA_AUX_DISK_8
- using channel ORA_AUX_SBT_TAPE_1
- using channel ORA_AUX_SBT_TAPE_2
- starting media recovery
- archived log for thread 1 with sequence 160 is already on disk as file +FRA/orcl/archivelog/2018_07_17/thread_1_seq_160.283.981749477
- archived log for thread 1 with sequence 161 is already on disk as file +FRA/orcl/archivelog/2018_07_17/thread_1_seq_161.284.981749479
- archived log for thread 1 with sequence 162 is already on disk as file +FRA/orcl/archivelog/2018_07_17/thread_1_seq_162.285.981749481
- archived log for thread 1 with sequence 163 is already on disk as file +FRA/orcl/archivelog/2018_07_17/thread_1_seq_163.286.981749481
- archived log for thread 1 with sequence 164 is already on disk as file +FRA/orcl/archivelog/2018_07_17/thread_1_seq_164.287.981749483
- archived log for thread 1 with sequence 165 is already on disk as file +FRA/orcl/archivelog/2018_07_17/thread_1_seq_165.288.981749485
- archived log for thread 1 with sequence 1 is already on disk as file +FRA/orcl/archivelog/2018_07_19/thread_1_seq_1.292.981927643
- archived log for thread 1 with sequence 2 is already on disk as file +FRA/orcl/archivelog/2018_07_22/thread_1_seq_2.293.982145289
- archived log for thread 1 with sequence 3 is already on disk as file +FRA/orcl/archivelog/2018_07_22/thread_1_seq_3.294.982145393
- archived log for thread 1 with sequence 4 is already on disk as file +FRA/orcl/archivelog/2018_07_22/thread_1_seq_4.295.982159249
- archived log for thread 1 with sequence 5 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_5.296.982267971
- archived log for thread 1 with sequence 6 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_6.297.982268257
- archived log for thread 1 with sequence 7 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_7.298.982268257
- archived log for thread 1 with sequence 8 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_8.299.982268269
- archived log for thread 1 with sequence 9 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_9.300.982268269
- archived log for thread 1 with sequence 10 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_10.301.982268271
- archived log for thread 1 with sequence 11 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_11.302.982268275
- archived log for thread 1 with sequence 12 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_12.303.982269845
- archived log for thread 1 with sequence 13 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_13.304.982270181
- archived log for thread 1 with sequence 14 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_14.305.982270719
- archived log for thread 1 with sequence 15 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_15.306.982270721
- archived log for thread 1 with sequence 16 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_16.307.982270729
- archived log for thread 1 with sequence 17 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_17.308.982270729
- archived log for thread 1 with sequence 18 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_18.309.982270729
- archived log for thread 1 with sequence 19 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_19.310.982270731
- archived log for thread 1 with sequence 20 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_20.311.982270909
- archived log for thread 1 with sequence 21 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_21.313.982272133
- archived log for thread 1 with sequence 22 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_22.314.982272133
- archived log for thread 1 with sequence 23 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_23.315.982272145
- archived log for thread 1 with sequence 24 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_24.316.982272151
- archived log for thread 1 with sequence 25 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_25.317.982272151
- archived log for thread 1 with sequence 26 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_26.318.982272153
- archived log for thread 1 with sequence 27 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_27.319.982272459
- archived log for thread 1 with sequence 28 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_28.320.982272459
- archived log for thread 1 with sequence 29 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_29.321.982272469
- archived log for thread 1 with sequence 30 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_30.322.982272473
- archived log for thread 1 with sequence 31 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_31.323.982272473
- archived log for thread 1 with sequence 32 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_32.324.982272475
- archived log for thread 1 with sequence 33 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_33.325.982272615
- archived log for thread 1 with sequence 34 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_34.327.982273393
- archived log for thread 1 with sequence 35 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_35.328.982273393
- archived log for thread 1 with sequence 36 is already on disk as file +FRA/orcl/archivelog/2018_07_23/thread_1_seq_36.333.982273403
- channel ORA_AUX_SBT_TAPE_1: starting archived log restore to default destination
- channel ORA_AUX_SBT_TAPE_1: restoring archived log
- archived log thread=1 sequence=159
- channel ORA_AUX_SBT_TAPE_1: reading from backup piece 1st88jbu_1_1
- channel ORA_AUX_SBT_TAPE_1: piece handle=1st88jbu_1_1 tag=100T_WHOLE_FULL
- channel ORA_AUX_SBT_TAPE_1: restored backup piece 1
- channel ORA_AUX_SBT_TAPE_1: restore complete, elapsed time: 00:00:22
- archived log file name=/u01/app/oracle/oradata/1_159_816169635.dbf thread=1 sequence=159
- channel clone_default: deleting archived log(s)
- archived log file name=/u01/app/oracle/oradata/1_159_816169635.dbf RECID=194 STAMP=982273621
- archived log file name=+FRA/orcl/archivelog/2018_07_17/thread_1_seq_160.283.981749477 thread=1 sequence=160
- archived log file name=+FRA/orcl/archivelog/2018_07_17/thread_1_seq_161.284.981749479 thread=1 sequence=161
- archived log file name=+FRA/orcl/archivelog/2018_07_17/thread_1_seq_162.285.981749481 thread=1 sequence=162
- archived log file name=+FRA/orcl/archivelog/2018_07_17/thread_1_seq_163.286.981749481 thread=1 sequence=163
- archived log file name=+FRA/orcl/archivelog/2018_07_17/thread_1_seq_164.287.981749483 thread=1 sequence=164
- archived log file name=+FRA/orcl/archivelog/2018_07_17/thread_1_seq_165.288.981749485 thread=1 sequence=165
- archived log file name=+FRA/orcl/archivelog/2018_07_19/thread_1_seq_1.292.981927643 thread=1 sequence=1
- archived log file name=+FRA/orcl/archivelog/2018_07_22/thread_1_seq_2.293.982145289 thread=1 sequence=2
- archived log file name=+FRA/orcl/archivelog/2018_07_22/thread_1_seq_3.294.982145393 thread=1 sequence=3
- archived log file name=+FRA/orcl/archivelog/2018_07_22/thread_1_seq_4.295.982159249 thread=1 sequence=4
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_5.296.982267971 thread=1 sequence=5
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_6.297.982268257 thread=1 sequence=6
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_7.298.982268257 thread=1 sequence=7
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_8.299.982268269 thread=1 sequence=8
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_9.300.982268269 thread=1 sequence=9
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_10.301.982268271 thread=1 sequence=10
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_11.302.982268275 thread=1 sequence=11
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_12.303.982269845 thread=1 sequence=12
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_13.304.982270181 thread=1 sequence=13
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_14.305.982270719 thread=1 sequence=14
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_15.306.982270721 thread=1 sequence=15
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_16.307.982270729 thread=1 sequence=16
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_17.308.982270729 thread=1 sequence=17
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_18.309.982270729 thread=1 sequence=18
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_19.310.982270731 thread=1 sequence=19
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_20.311.982270909 thread=1 sequence=20
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_21.313.982272133 thread=1 sequence=21
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_22.314.982272133 thread=1 sequence=22
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_23.315.982272145 thread=1 sequence=23
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_24.316.982272151 thread=1 sequence=24
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_25.317.982272151 thread=1 sequence=25
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_26.318.982272153 thread=1 sequence=26
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_27.319.982272459 thread=1 sequence=27
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_28.320.982272459 thread=1 sequence=28
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_29.321.982272469 thread=1 sequence=29
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_30.322.982272473 thread=1 sequence=30
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_31.323.982272473 thread=1 sequence=31
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_32.324.982272475 thread=1 sequence=32
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_33.325.982272615 thread=1 sequence=33
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_34.327.982273393 thread=1 sequence=34
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_35.328.982273393 thread=1 sequence=35
- archived log file name=+FRA/orcl/archivelog/2018_07_23/thread_1_seq_36.333.982273403 thread=1 sequence=36
- media recovery complete, elapsed time: 00:01:09
- Finished recover at 2018-07-23:21:48:17
- database opened
- contents of Memory Script:
- {
- # make read only the tablespace that will be exported
- sql clone 'alter tablespace USERS read only';
- # create directory for datapump import
- sql "create or replace directory TSPITR_DIROBJ_DPDIR as ''
- /u01/app/oracle/oradata''";
- # create directory for datapump export
- sql clone "create or replace directory TSPITR_DIROBJ_DPDIR as ''
- /u01/app/oracle/oradata''";
- }
- executing Memory Script
- sql statement: alter tablespace USERS read only
- sql statement: create or replace directory TSPITR_DIROBJ_DPDIR as ''/u01/app/oracle/oradata''
- sql statement: create or replace directory TSPITR_DIROBJ_DPDIR as ''/u01/app/oracle/oradata''
- Performing export of metadata...
- EXPDP> Starting "SYS"."TSPITR_EXP_BcBD":
- EXPDP> Processing object type TRANSPORTABLE_EXPORT/PLUGTS_BLK
- EXPDP> Processing object type TRANSPORTABLE_EXPORT/TYPE/TYPE_SPEC
- EXPDP> Processing object type TRANSPORTABLE_EXPORT/TYPE/TYPE_BODY
- EXPDP> Processing object type TRANSPORTABLE_EXPORT/XMLSCHEMA/XMLSCHEMA
- EXPDP> Processing object type TRANSPORTABLE_EXPORT/TABLE
- EXPDP> Processing object type TRANSPORTABLE_EXPORT/INDEX/INDEX
- EXPDP> Processing object type TRANSPORTABLE_EXPORT/CONSTRAINT/CONSTRAINT
- EXPDP> Processing object type TRANSPORTABLE_EXPORT/INDEX_STATISTICS
- EXPDP> Processing object type TRANSPORTABLE_EXPORT/COMMENT
- EXPDP> Processing object type TRANSPORTABLE_EXPORT/CONSTRAINT/REF_CONSTRAINT
- EXPDP> Processing object type TRANSPORTABLE_EXPORT/TABLE_STATISTICS
- EXPDP> Processing object type TRANSPORTABLE_EXPORT/POST_INSTANCE/PLUGTS_BLK
- EXPDP> Master table "SYS"."TSPITR_EXP_BcBD" successfully loaded/unloaded
- EXPDP> ******************************************************************************
- EXPDP> Dump file set for SYS.TSPITR_EXP_BcBD is:
- EXPDP> /u01/app/oracle/oradata/tspitr_BcBD_77380.dmp
- EXPDP> ******************************************************************************
- EXPDP> Datafiles required for transportable tablespace USERS:
- EXPDP> +DATA/orcl/datafile/users.259.816169553
- EXPDP> Job "SYS"."TSPITR_EXP_BcBD" successfully completed at 21:49:21
- Export completed
- contents of Memory Script:
- {
- # shutdown clone before import
- shutdown clone immediate
- # drop target tablespaces before importing them back
- sql 'drop tablespace USERS including contents keep datafiles';
- }
- executing Memory Script
- database closed
- database dismounted
- Oracle instance shut down
- sql statement: drop tablespace USERS including contents keep datafiles
- Performing import of metadata...
- IMPDP> Master table "SYS"."TSPITR_IMP_BcBD" successfully loaded/unloaded
- IMPDP> Starting "SYS"."TSPITR_IMP_BcBD":
- IMPDP> Processing object type TRANSPORTABLE_EXPORT/PLUGTS_BLK
- IMPDP> Processing object type TRANSPORTABLE_EXPORT/TYPE/TYPE_SPEC
- IMPDP> ORA-31684: Object type TYPE:"OE"."SHIPPING_INSTRUCTIONS_T" already existsORA-31684: Object type TYPE:"OE"."REJECTION_T" already existsORA-31684: Object type TYPE:"OE"."ACTION_T" already existsORA-31684: Object type TYPE:"OE"."PART_T" already existsORA-31684: Object type TYPE:"OE"."PRODUCT_REF_LIST_TYP" already existsORA-31684: Object type TYPE:"OE"."CATEGORY_TYP" already existsORA-31684: Object type TYPE:"OE"."SUBCATEGORY_REF_LIST_TYP" already existsORA-31684: Object type TYPE:"OE"."ACTION_V" already existsORA-31684: Object type TYPE:"OE"."LINEITEM_T" already existsORA-31684: Object type TYPE:"OE"."LEAF_CATEGORY_TYP" already existsORA-31684: Object type TYPE:"OE"."COMPOSITE_CATEGORY_TYP" already existsORA-31684: Object type TYPE:"OE"."ACTIONS_T" already existsORA-31684: Object type TYPE:"OE"."LINEITEM_V" already existsORA-31684: Object type TYPE:"OE"."CATALOG_TYP" already existsORA-31684: Object type TYPE:"OE"."LINEITEMS_T" already existsORA-31684: Object type TYPE:"OE"."PURCHASEORDER_T" already exists
- IMPDP> Processing object type TRANSPORTABLE_EXPORT/TYPE/TYPE_BODY
- IMPDP> ORA-31684: Object type TYPE_BODY:"OE"."LEAF_CATEGORY_TYP" already existsORA-31684: Object type TYPE_BODY:"OE"."COMPOSITE_CATEGORY_TYP" already existsORA-31684: Object type TYPE_BODY:"OE"."CATALOG_TYP" already exists
- IMPDP> Processing object type TRANSPORTABLE_EXPORT/XMLSCHEMA/XMLSCHEMA
- IMPDP> ORA-39083: Object type XMLSCHEMA failed to create with error:
- ORA-31085: schema "http://localhost:8080/source/schemas/poSource/xsd/purchaseOrder.xsd" already registered
- Failing sql is:
- BEGIN dbms_xmlschema.registerSchema(:1, :2, (:3 = 1), FALSE,FALSE,FALSE,FALSE, :4, options=> :5, schemaoid => :6, import_options => :7); END;
- IMPDP> Processing object type TRANSPORTABLE_EXPORT/TABLE
- IMPDP> ORA-39083: Object type TABLE:"OE"."PURCHASEORDER" failed to create with error:
- ORA-31061: XDB error: DBMS_XDBZ.ENABLE_HIERARCHY
- ORA-06512: at "XDB.DBMS_XDBZ0", line 131
- ORA-06512: at "XDB.DBMS_XDBZ0", line 588
- ORA-01031: insufficient privileges
- Failing sql is:
- BEGIN DBMS_XDBZ.ENABLE_HIERARCHY('"OE"','"PURCHASEORDER"'); END;
- IMPDP> Processing object type TRANSPORTABLE_EXPORT/INDEX/INDEX
- IMPDP> Processing object type TRANSPORTABLE_EXPORT/CONSTRAINT/CONSTRAINT
- IMPDP> Processing object type TRANSPORTABLE_EXPORT/INDEX_STATISTICS
- IMPDP> ORA-39083: Object type INDEX_STATISTICS failed to create with error:
- ORA-20000: INDEX "OE"."LINEITEM_TABLE_MEMBERS" does not exist or insufficient privileges
- Failing sql is:
- DECLARE I_N VARCHAR2(60); I_O VARCHAR2(60); NV VARCHAR2(1); c DBMS_METADATA.T_VAR_COLL; df varchar2(21) := 'YYYY-MM-DD:HH24:MI:SS'; stmt varchar2(300) := ' INSERT INTO "SYS"."IMPDP_STATS" (type,version,flags,c1,c2,c3,c5,n1,n2,n3,n4,n5,n6,n7,n8,n9,n10,n11,n12,d1,cl1) VALUES (''I'',6,:1,:2,:3,:4,:5,:6,:7,:8,:9,:10,:11,:12,:13,NULORA-39112: Dependent object type INDEX_STATISTICS skipped, base object type TABLE:"OE"."PURCHASEORDER" creation failedORA-39083: Object type INDEX_STATISTICS failed to create with error:
- ORA-20000: INDEX "OE"."ACTION_TABLE_MEMBERS" does not exist or insufficient privileges
- Failing sql is:
- DECLARE I_N VARCHAR2(60); I_O VARCHAR2(60); NV VARCHAR2(1); c DBMS_METADATA.T_VAR_COLL; df varchar2(21) := 'YYYY-MM-DD:HH24:MI:SS'; stmt varchar2(300) := ' INSERT INTO "SYS"."IMPDP_STATS" (type,version,flags,c1,c2,c3,c5,n1,n2,n3,n4,n5,n6,n7,n8,n9,n10,n11,n12,d1,cl1) VALUES (''I'',6,:1,:2,:3,:4,:5,:6,:7,:8,:9,:10,:11,:12,:13,NULL,
- IMPDP> Processing object type TRANSPORTABLE_EXPORT/COMMENT
- IMPDP> Processing object type TRANSPORTABLE_EXPORT/CONSTRAINT/REF_CONSTRAINT
- IMPDP> Processing object type TRANSPORTABLE_EXPORT/TABLE_STATISTICS
- IMPDP> ORA-39112: Dependent object type TABLE_STATISTICS skipped, base object type TABLE:"OE"."PURCHASEORDER" creation failed
- IMPDP> Processing object type TRANSPORTABLE_EXPORT/POST_INSTANCE/PLUGTS_BLK
- IMPDP> Job "SYS"."TSPITR_IMP_BcBD" completed with 25 error(s) at 21:49:53
- Import completed
- contents of Memory Script:
- {
- # make read write and offline the imported tablespaces
- sql 'alter tablespace USERS read write';
- sql 'alter tablespace USERS offline';
- # enable autobackups after TSPITR is finished
- sql 'begin dbms_backup_restore.AutoBackupFlag(TRUE); end;';
- }
- executing Memory Script
- sql statement: alter tablespace USERS read write
- sql statement: alter tablespace USERS offline
- sql statement: begin dbms_backup_restore.AutoBackupFlag(TRUE); end;
- Removing automatic instance
- Automatic instance removed
- auxiliary instance file /u01/app/oracle/oradata/ORCL/datafile/o1_mf_temp_focq53vc_.tmp deleted
- auxiliary instance file /u01/app/oracle/oradata/ORCL/onlinelog/o1_mf_3_focq52oo_.log deleted
- auxiliary instance file /u01/app/oracle/oradata/ORCL/onlinelog/o1_mf_2_focq52bt_.log deleted
- auxiliary instance file /u01/app/oracle/oradata/ORCL/onlinelog/o1_mf_1_focq51yc_.log deleted
- auxiliary instance file /u01/app/oracle/oradata/ORCL/datafile/o1_mf_sysaux_focq1q59_.dbf deleted
- auxiliary instance file /u01/app/oracle/oradata/ORCL/datafile/o1_mf_undotbs1_focq1q5x_.dbf deleted
- auxiliary instance file /u01/app/oracle/oradata/ORCL/datafile/o1_mf_system_focq1l57_.dbf deleted
- auxiliary instance file /u01/app/oracle/oradata/ORCL/controlfile/o1_mf_focq0r3q_.ctl deleted
- Finished recover at 2018-07-23:21:49:56
- RMAN>
复制代码
|
|