Dear Erman,
Need your expertise. Any specific reasons to have the "INCLUDE CURRENT CONTROLFILE" in L0 backup scripts like below BACKUP AS COMPRESSED BACKUPSET INCREMENTAL LEVEL=0 DATABASE INCLUDE CURRENT CONTROLFILE PLUS ARCHIVELOG; Thank you, satish |
Administrator
|
If the autobackup feature is not set, then you must manually back up the control file.
But be aware that -> A manual backup of the control file is not the same as a control file autobackup. In manual backups, only RMAN repository data for backups within the current RMAN session is in the control file backup, and a manually backed-up control file cannot be automatically restored. |
Dear erman,
Thanks for the update. Can't we use this for rman duplicate? In case of dropped table space, can't we use this? Thank you |
Administrator
|
Yes you can.
Here is a duplicate demo for you.. (duplicate from backup --including controlfile) [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ rman target / Recovery Manager: Release 11.2.0.4.0 - Production on Tue Jan 29 15:08:05 2019 Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved. connected to target database: ORCL (DBID=1388576454) RMAN> show all; using target database control file instead of recovery catalog RMAN configuration parameters for database with db_unique_name ORCL are: CONFIGURE RETENTION POLICY TO REDUNDANCY 1; # default CONFIGURE BACKUP OPTIMIZATION OFF; # default CONFIGURE DEFAULT DEVICE TYPE TO DISK; # default CONFIGURE CONTROLFILE AUTOBACKUP OFF; CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '/backups/cf_auto_%F'; CONFIGURE DEVICE TYPE DISK PARALLELISM 1 BACKUP TYPE TO BACKUPSET; # default CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default CONFIGURE MAXSETSIZE TO UNLIMITED; # default CONFIGURE ENCRYPTION FOR DATABASE OFF; # default CONFIGURE ENCRYPTION ALGORITHM 'AES128'; # default CONFIGURE COMPRESSION ALGORITHM 'BASIC' AS OF RELEASE 'DEFAULT' OPTIMIZE FOR LOAD TRUE ; # default CONFIGURE ARCHIVELOG DELETION POLICY TO NONE; # default CONFIGURE SNAPSHOT CONTROLFILE NAME TO '/u01/app/oracle/product/11.2.0/dbhome_1/dbs/snapcf_orcl.f'; # default RMAN> RMAN> RMAN> Recovery Manager complete. [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ rman target / Recovery Manager: Release 11.2.0.4.0 - Production on Tue Jan 29 15:08:54 2019 Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved. connected to target database: ORCL (DBID=1388576454) RMAN> backup database include current controlfile format '/backups/db_backup_%U.bkp'; Starting backup at 29-JAN-19 using target database control file instead of recovery catalog allocated channel: ORA_DISK_1 channel ORA_DISK_1: SID=143 device type=DISK channel ORA_DISK_1: starting full datafile backup set channel ORA_DISK_1: specifying datafile(s) in backup set input datafile file number=00001 name=/u01/app/oracle/oradata/orcl/system01.dbf input datafile file number=00002 name=/u01/app/oracle/oradata/orcl/sysaux01.dbf input datafile file number=00005 name=/u01/app/oracle/oradata/orcl/example01.dbf input datafile file number=00003 name=/u01/app/oracle/oradata/orcl/undotbs01.dbf input datafile file number=00004 name=/u01/app/oracle/oradata/orcl/users01.dbf channel ORA_DISK_1: starting piece 1 at 29-JAN-19 channel ORA_DISK_1: finished piece 1 at 29-JAN-19 piece handle=/backups/db_backup_0ctoi489_1_1.bkp tag=TAG20190129T150857 comment=NONE channel ORA_DISK_1: backup set complete, elapsed time: 00:00:35 channel ORA_DISK_1: starting full datafile backup set channel ORA_DISK_1: specifying datafile(s) in backup set including current control file in backup set including current SPFILE in backup set channel ORA_DISK_1: starting piece 1 at 29-JAN-19 channel ORA_DISK_1: finished piece 1 at 29-JAN-19 piece handle=/backups/db_backup_0dtoi49c_1_1.bkp tag=TAG20190129T150857 comment=NONE channel ORA_DISK_1: backup set complete, elapsed time: 00:00:01 Finished backup at 29-JAN-19 RMAN> RMAN> RMAN> backup archivelog all format '/backups/arch_backup_%U.bkp'; Starting backup at 29-JAN-19 current log archived using channel ORA_DISK_1 channel ORA_DISK_1: starting archived log backup set channel ORA_DISK_1: specifying archived log(s) in backup set input archived log thread=1 sequence=20 RECID=1 STAMP=998835956 input archived log thread=1 sequence=21 RECID=2 STAMP=998835957 input archived log thread=1 sequence=22 RECID=3 STAMP=998835960 input archived log thread=1 sequence=23 RECID=4 STAMP=998835960 input archived log thread=1 sequence=24 RECID=5 STAMP=998835961 input archived log thread=1 sequence=25 RECID=6 STAMP=998835962 input archived log thread=1 sequence=26 RECID=7 STAMP=998835963 input archived log thread=1 sequence=27 RECID=8 STAMP=998838193 channel ORA_DISK_1: starting piece 1 at 29-JAN-19 channel ORA_DISK_1: finished piece 1 at 29-JAN-19 piece handle=/backups/arch_backup_0etoi4ae_1_1.bkp tag=TAG20190129T151006 comment=NONE channel ORA_DISK_1: backup set complete, elapsed time: 00:00:01 channel ORA_DISK_1: starting archived log backup set channel ORA_DISK_1: specifying archived log(s) in backup set input archived log thread=1 sequence=1 RECID=9 STAMP=998838380 input archived log thread=1 sequence=2 RECID=10 STAMP=998838380 input archived log thread=1 sequence=3 RECID=11 STAMP=998838382 input archived log thread=1 sequence=4 RECID=12 STAMP=998838384 input archived log thread=1 sequence=5 RECID=13 STAMP=998838385 input archived log thread=1 sequence=6 RECID=14 STAMP=998838385 input archived log thread=1 sequence=7 RECID=15 STAMP=998838386 input archived log thread=1 sequence=8 RECID=16 STAMP=998838606 channel ORA_DISK_1: starting piece 1 at 29-JAN-19 channel ORA_DISK_1: finished piece 1 at 29-JAN-19 piece handle=/backups/arch_backup_0ftoi4af_1_1.bkp tag=TAG20190129T151006 comment=NONE channel ORA_DISK_1: backup set complete, elapsed time: 00:00:01 Finished backup at 29-JAN-19 RMAN> RMAN> list backup; List of Backup Sets =================== BS Key Type LV Size Device Type Elapsed Time Completion Time ------- ---- -- ---------- ----------- ------------ --------------- 7 Full 1.37G DISK 00:00:26 29-JAN-19 BP Key: 7 Status: AVAILABLE Compressed: NO Tag: TAG20190129T150857 Piece Name: /backups/db_backup_0ctoi489_1_1.bkp List of Datafiles in backup set 7 File LV Type Ckp SCN Ckp Time Name ---- -- ---- ---------- --------- ---- 1 Full 1127587 29-JAN-19 /u01/app/oracle/oradata/orcl/system01.dbf 2 Full 1127587 29-JAN-19 /u01/app/oracle/oradata/orcl/sysaux01.dbf 3 Full 1127587 29-JAN-19 /u01/app/oracle/oradata/orcl/undotbs01.dbf 4 Full 1127587 29-JAN-19 /u01/app/oracle/oradata/orcl/users01.dbf 5 Full 1127587 29-JAN-19 /u01/app/oracle/oradata/orcl/example01.dbf BS Key Type LV Size Device Type Elapsed Time Completion Time ------- ---- -- ---------- ----------- ------------ --------------- 8 Full 9.36M DISK 00:00:01 29-JAN-19 BP Key: 8 Status: AVAILABLE Compressed: NO Tag: TAG20190129T150857 Piece Name: /backups/db_backup_0dtoi49c_1_1.bkp SPFILE Included: Modification time: 29-JAN-19 SPFILE db_unique_name: ORCL Control File Included: Ckp SCN: 1127599 Ckp time: 29-JAN-19 BS Key Size Device Type Elapsed Time Completion Time ------- ---------- ----------- ------------ --------------- 9 9.42M DISK 00:00:00 29-JAN-19 BP Key: 9 Status: AVAILABLE Compressed: NO Tag: TAG20190129T151006 Piece Name: /backups/arch_backup_0etoi4ae_1_1.bkp List of Archived Logs in backup set 9 Thrd Seq Low SCN Low Time Next SCN Next Time ---- ------- ---------- --------- ---------- --------- 1 20 1119444 18-JAN-15 1125740 29-JAN-19 1 21 1125740 29-JAN-19 1125746 29-JAN-19 1 22 1125746 29-JAN-19 1125750 29-JAN-19 1 23 1125750 29-JAN-19 1125753 29-JAN-19 1 24 1125753 29-JAN-19 1125756 29-JAN-19 1 25 1125756 29-JAN-19 1125759 29-JAN-19 1 26 1125759 29-JAN-19 1125762 29-JAN-19 1 27 1125762 29-JAN-19 1126280 29-JAN-19 BS Key Size Device Type Elapsed Time Completion Time ------- ---------- ----------- ------------ --------------- 10 553.00K DISK 00:00:00 29-JAN-19 BP Key: 10 Status: AVAILABLE Compressed: NO Tag: TAG20190129T151006 Piece Name: /backups/arch_backup_0ftoi4af_1_1.bkp List of Archived Logs in backup set 10 Thrd Seq Low SCN Low Time Next SCN Next Time ---- ------- ---------- --------- ---------- --------- 1 1 1126281 29-JAN-19 1127363 29-JAN-19 1 2 1127363 29-JAN-19 1127367 29-JAN-19 1 3 1127367 29-JAN-19 1127371 29-JAN-19 1 4 1127371 29-JAN-19 1127375 29-JAN-19 1 5 1127375 29-JAN-19 1127379 29-JAN-19 1 6 1127379 29-JAN-19 1127383 29-JAN-19 1 7 1127383 29-JAN-19 1127387 29-JAN-19 1 8 1127387 29-JAN-19 1127633 29-JAN-19 RMAN> RMAN> RMAN> Recovery Manager complete. [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ ls -l /backups/ total 1456168 -rw-r-----. 1 oracle oinstall 9879552 Jan 29 15:10 arch_backup_0etoi4ae_1_1.bkp -rw-r-----. 1 oracle oinstall 566784 Jan 29 15:10 arch_backup_0ftoi4af_1_1.bkp -rw-r-----. 1 oracle oinstall 1470832640 Jan 29 15:09 db_backup_0ctoi489_1_1.bkp -rw-r-----. 1 oracle oinstall 9830400 Jan 29 15:09 db_backup_0dtoi49c_1_1.bkp [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ sql SQL*Plus: Release 11.2.0.4.0 Production on Tue Jan 29 15:10:52 2019 Copyright (c) 1982, 2013, Oracle. All rights reserved. Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options SQL> create pfile='/backups/initorcl.ora' from spfile; File created. SQL> Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ sql SQL*Plus: Release 11.2.0.4.0 Production on Tue Jan 29 15:11:12 2019 Copyright (c) 1982, 2013, Oracle. All rights reserved. Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options SQL> shu immediatE; Database closed. Database dismounted. ORACLE instance shut down. SQL> SQL> SQL> SQL> Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ sql SQL*Plus: Release 11.2.0.4.0 Production on Tue Jan 29 15:11:31 2019 Copyright (c) 1982, 2013, Oracle. All rights reserved. Connected to an idle instance. SQL> SQL> STARTUP NOMOUNT RESTRICT; ORACLE instance started. Total System Global Area 835104768 bytes Fixed Size 2257840 bytes Variable Size 507513936 bytes Database Buffers 318767104 bytes Redo Buffers 6565888 bytes SQL> alter database mount; Database altered. SQL> drop database; Database dropped. Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options SQL> SQL> SQL> SQL> [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ ps -ef | grep pmon oracle 19087 16363 0 15:18 pts/0 00:00:00 grep pmon [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ ls -l /u01/app/oracle/product/11.2.0/dbhome_1/dbs/ total 12 -rw-rw----. 1 oracle oinstall 1544 Jan 29 15:17 hc_orcl.dat -rw-r--r--. 1 oracle oinstall 2851 May 15 2009 init.ora -rw-r-----. 1 oracle oinstall 24 Jan 29 14:41 lkORCL [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ sql SQL*Plus: Release 11.2.0.4.0 Production on Tue Jan 29 15:18:53 2019 Copyright (c) 1982, 2013, Oracle. All rights reserved. Connected to an idle instance. SQL> SQL> startup nomount pfile='/backups/initorcl.ora'; ORACLE instance started. Total System Global Area 835104768 bytes Fixed Size 2257840 bytes Variable Size 507513936 bytes Database Buffers 318767104 bytes Redo Buffers 6565888 bytes SQL> SQL> SQL> Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ cat /backups/initorcl.ora orcl.__db_cache_size=381681664 orcl.__java_pool_size=4194304 orcl.__large_pool_size=8388608 orcl.__oracle_base='/u01/app/oracle'#ORACLE_BASE set from environment orcl.__pga_aggregate_target=293601280 orcl.__sga_target=545259520 orcl.__shared_io_pool_size=0 orcl.__shared_pool_size=138412032 orcl.__streams_pool_size=0 *.audit_file_dest='/u01/app/oracle/admin/orcl/adump' *.audit_trail='db' *.compatible='11.2.0.4.0' *.control_files='/u01/app/oracle/oradata/orcl/control01.ctl','/u01/flash_recovery_area/orcl/control02.ctl' *.db_block_size=8192 *.db_domain='' *.db_name='orcl' *.db_recovery_file_dest='/u01/flash_recovery_area' *.db_recovery_file_dest_size=4389339136 *.diagnostic_dest='/u01/app/oracle' *.dispatchers='(PROTOCOL=TCP) (SERVICE=orclXDB)' *.job_queue_processes=1000 *.memory_target=838860800 *.open_cursors=300 *.processes=150 *.remote_login_passwordfile='EXCLUSIVE' *.undo_tablespace='UNDOTBS1' [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ sql SQL*Plus: Release 11.2.0.4.0 Production on Tue Jan 29 15:21:45 2019 Copyright (c) 1982, 2013, Oracle. All rights reserved. Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options SQL> shu immediate; ORA-01109: database not open Database dismounted. ORACLE instance shut down. SQL> SQL> SQL> Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ sql SQL*Plus: Release 11.2.0.4.0 Production on Tue Jan 29 15:22:20 2019 Copyright (c) 1982, 2013, Oracle. All rights reserved. Connected to an idle instance. SQL> startup nomount pfile='/backups/initorcl.ora' ; ORACLE instance started. Total System Global Area 835104768 bytes Fixed Size 2257840 bytes Variable Size 507513936 bytes Database Buffers 318767104 bytes Redo Buffers 6565888 bytes SQL> Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ rman auxiliary / Recovery Manager: Release 11.2.0.4.0 - Production on Tue Jan 29 15:22:34 2019 Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved. connected to auxiliary database: ORCL (not mounted) RMAN> duplicate target database to orclt backup location '/backups/' nofilenamecheck; Starting Duplicate Db at 29-JAN-19 contents of Memory Script: { sql clone "create spfile from memory"; } executing Memory Script sql statement: create spfile from memory contents of Memory Script: { shutdown clone immediate; startup clone nomount; } executing Memory Script Oracle instance shut down connected to auxiliary database (not started) Oracle instance started Total System Global Area 835104768 bytes Fixed Size 2257840 bytes Variable Size 511708240 bytes Database Buffers 314572800 bytes Redo Buffers 6565888 bytes contents of Memory Script: { sql clone "alter system set db_name = ''ORCL'' comment= ''Modified by RMAN duplicate'' scope=spfile"; shutdown clone immediate; startup clone force nomount restore clone primary controlfile from '/backups/db_backup_0dtoi49c_1_1.bkp'; alter clone database mount; } executing Memory Script sql statement: alter system set db_name = ''ORCL'' comment= ''Modified by RMAN duplicate'' scope=spfile Oracle instance shut down Oracle instance started Total System Global Area 835104768 bytes Fixed Size 2257840 bytes Variable Size 511708240 bytes Database Buffers 314572800 bytes Redo Buffers 6565888 bytes Starting restore at 29-JAN-19 allocated channel: ORA_AUX_DISK_1 channel ORA_AUX_DISK_1: SID=133 device type=DISK channel ORA_AUX_DISK_1: restoring control file channel ORA_AUX_DISK_1: restore complete, elapsed time: 00:00:01 output file name=/u01/app/oracle/oradata/orcl/control01.ctl output file name=/u01/flash_recovery_area/orcl/control02.ctl Finished restore at 29-JAN-19 database mounted released channel: ORA_AUX_DISK_1 allocated channel: ORA_AUX_DISK_1 channel ORA_AUX_DISK_1: SID=133 device type=DISK contents of Memory Script: { set until scn 1127633; set newname for datafile 1 to "/u01/app/oracle/oradata/orcl/system01.dbf"; set newname for datafile 2 to "/u01/app/oracle/oradata/orcl/sysaux01.dbf"; set newname for datafile 3 to "/u01/app/oracle/oradata/orcl/undotbs01.dbf"; set newname for datafile 4 to "/u01/app/oracle/oradata/orcl/users01.dbf"; set newname for datafile 5 to "/u01/app/oracle/oradata/orcl/example01.dbf"; restore clone database ; } executing Memory Script executing command: SET until clause executing command: SET NEWNAME executing command: SET NEWNAME executing command: SET NEWNAME executing command: SET NEWNAME executing command: SET NEWNAME Starting restore at 29-JAN-19 using channel ORA_AUX_DISK_1 channel ORA_AUX_DISK_1: starting datafile backup set restore channel ORA_AUX_DISK_1: specifying datafile(s) to restore from backup set channel ORA_AUX_DISK_1: restoring datafile 00001 to /u01/app/oracle/oradata/orcl/system01.dbf channel ORA_AUX_DISK_1: restoring datafile 00002 to /u01/app/oracle/oradata/orcl/sysaux01.dbf channel ORA_AUX_DISK_1: restoring datafile 00003 to /u01/app/oracle/oradata/orcl/undotbs01.dbf channel ORA_AUX_DISK_1: restoring datafile 00004 to /u01/app/oracle/oradata/orcl/users01.dbf channel ORA_AUX_DISK_1: restoring datafile 00005 to /u01/app/oracle/oradata/orcl/example01.dbf channel ORA_AUX_DISK_1: reading from backup piece /backups/db_backup_0ctoi489_1_1.bkp channel ORA_AUX_DISK_1: piece handle=/backups/db_backup_0ctoi489_1_1.bkp tag=TAG20190129T150857 channel ORA_AUX_DISK_1: restored backup piece 1 channel ORA_AUX_DISK_1: restore complete, elapsed time: 00:00:35 Finished restore at 29-JAN-19 contents of Memory Script: { switch clone datafile all; } executing Memory Script datafile 1 switched to datafile copy input datafile copy RECID=1 STAMP=998839484 file name=/u01/app/oracle/oradata/orcl/system01.dbf datafile 2 switched to datafile copy input datafile copy RECID=2 STAMP=998839484 file name=/u01/app/oracle/oradata/orcl/sysaux01.dbf datafile 3 switched to datafile copy input datafile copy RECID=3 STAMP=998839484 file name=/u01/app/oracle/oradata/orcl/undotbs01.dbf datafile 4 switched to datafile copy input datafile copy RECID=4 STAMP=998839484 file name=/u01/app/oracle/oradata/orcl/users01.dbf datafile 5 switched to datafile copy input datafile copy RECID=5 STAMP=998839484 file name=/u01/app/oracle/oradata/orcl/example01.dbf contents of Memory Script: { set until scn 1127633; recover clone database delete archivelog ; } executing Memory Script executing command: SET until clause Starting recover at 29-JAN-19 using channel ORA_AUX_DISK_1 starting media recovery channel ORA_AUX_DISK_1: starting archived log restore to default destination channel ORA_AUX_DISK_1: restoring archived log archived log thread=1 sequence=8 channel ORA_AUX_DISK_1: reading from backup piece /backups/arch_backup_0ftoi4af_1_1.bkp channel ORA_AUX_DISK_1: piece handle=/backups/arch_backup_0ftoi4af_1_1.bkp tag=TAG20190129T151006 channel ORA_AUX_DISK_1: restored backup piece 1 channel ORA_AUX_DISK_1: restore complete, elapsed time: 00:00:01 archived log file name=/u01/flash_recovery_area/ORCL/archivelog/2019_01_29/o1_mf_1_8_g50o0xjv_.arc thread=1 sequence=8 channel clone_default: deleting archived log(s) archived log file name=/u01/flash_recovery_area/ORCL/archivelog/2019_01_29/o1_mf_1_8_g50o0xjv_.arc RECID=1 STAMP=998839485 media recovery complete, elapsed time: 00:00:00 Finished recover at 29-JAN-19 Oracle instance started Total System Global Area 835104768 bytes Fixed Size 2257840 bytes Variable Size 511708240 bytes Database Buffers 314572800 bytes Redo Buffers 6565888 bytes contents of Memory Script: { sql clone "alter system set db_name = ''ORCLT'' comment= ''Reset to original value by RMAN'' scope=spfile"; shutdown clone immediate; startup clone nomount; } executing Memory Script sql statement: alter system set db_name = ''ORCLT'' comment= ''Reset to original value by RMAN'' scope=spfile Oracle instance shut down connected to auxiliary database (not started) Oracle instance started Total System Global Area 835104768 bytes Fixed Size 2257840 bytes Variable Size 511708240 bytes Database Buffers 314572800 bytes Redo Buffers 6565888 bytes sql statement: CREATE CONTROLFILE REUSE SET DATABASE "ORCLT" RESETLOGS ARCHIVELOG MAXLOGFILES 16 MAXLOGMEMBERS 3 MAXDATAFILES 100 MAXINSTANCES 8 MAXLOGHISTORY 292 LOGFILE GROUP 1 SIZE 50 M , GROUP 2 SIZE 50 M , GROUP 3 SIZE 50 M DATAFILE '/u01/app/oracle/oradata/orcl/system01.dbf' CHARACTER SET WE8MSWIN1252 contents of Memory Script: { set newname for tempfile 1 to "/u01/app/oracle/oradata/orcl/temp01.dbf"; switch clone tempfile all; catalog clone datafilecopy "/u01/app/oracle/oradata/orcl/sysaux01.dbf", "/u01/app/oracle/oradata/orcl/undotbs01.dbf", "/u01/app/oracle/oradata/orcl/users01.dbf", "/u01/app/oracle/oradata/orcl/example01.dbf"; switch clone datafile all; } executing Memory Script executing command: SET NEWNAME renamed tempfile 1 to /u01/app/oracle/oradata/orcl/temp01.dbf in control file cataloged datafile copy datafile copy file name=/u01/app/oracle/oradata/orcl/sysaux01.dbf RECID=1 STAMP=998839538 cataloged datafile copy datafile copy file name=/u01/app/oracle/oradata/orcl/undotbs01.dbf RECID=2 STAMP=998839538 cataloged datafile copy datafile copy file name=/u01/app/oracle/oradata/orcl/users01.dbf RECID=3 STAMP=998839538 cataloged datafile copy datafile copy file name=/u01/app/oracle/oradata/orcl/example01.dbf RECID=4 STAMP=998839538 datafile 2 switched to datafile copy input datafile copy RECID=1 STAMP=998839538 file name=/u01/app/oracle/oradata/orcl/sysaux01.dbf datafile 3 switched to datafile copy input datafile copy RECID=2 STAMP=998839538 file name=/u01/app/oracle/oradata/orcl/undotbs01.dbf datafile 4 switched to datafile copy input datafile copy RECID=3 STAMP=998839538 file name=/u01/app/oracle/oradata/orcl/users01.dbf datafile 5 switched to datafile copy input datafile copy RECID=4 STAMP=998839538 file name=/u01/app/oracle/oradata/orcl/example01.dbf contents of Memory Script: { Alter clone database open resetlogs; } executing Memory Script database opened Finished Duplicate Db at 29-JAN-19 RMAN> RMAN> Recovery Manager complete. [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ sql SQL*Plus: Release 11.2.0.4.0 Production on Tue Jan 29 15:25:48 2019 Copyright (c) 1982, 2013, Oracle. All rights reserved. Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options SQL> set linesize 200 SQL> select name,instance_name, db_unique_name,instance_number, status, database_role, open_mode from v$database, gv$instance; NAME INSTANCE_NAME DB_UNIQUE_NAME INSTANCE_NUMBER STATUS DATABASE_ROLE OPEN_MODE --------- ---------------- ------------------------------ --------------- ------------ ---------------- -------------------- ORCLT orcl 1 OPEN PRIMARY READ WRITE SQL> SQL> Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options [oracle@ovmmanager ~]$ [oracle@ovmmanager ~]$ |
Free forum by Nabble | Edit this page |