I am trying to do a point in time duplicate of one of my development databases and I am getting the following error:
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of Duplicate Db command at 02/06/2020 09:16:25
RMAN-05501: aborting duplication of target database
RMAN-03015: error occurred in stored script Memory Script
RMAN-06026: some targets not found - aborting restore
RMAN-06024: no backup or copy of the control file found to restore
this is what I am using to do the duplicate. I have done this before and it has worked, but apparently it is not working this time. Below is what I an using to get it to run
RMAN> run {
DUPLICATE TARGET DATABASE TO STGE
BACKUP LOCATION '/u99/backup/rman/PROD'
NOFILENAMECHECK
UNTIL TIME "TO_DATE('2020-02-04 17:00:00', 'YYYY-MM-DD HH24:MI:SS')";
}
the full picture
[svc_oracle@stg-bannerdb PROD]$ rman target sys/password@PROD auxiliary sys/password@STGE
Recovery Manager: Release 12.1.0.2.0 - Production on Thu Feb 6 08:52:14 2020
Copyright (c) 1982, 2014, Oracle and/or its affiliates. All rights reserved.
connected to target database: PROD (DBID=303212289)
connected to auxiliary database: STGE (not mounted)
RMAN> run {
2> DUPLICATE TARGET DATABASE TO STGE
3> BACKUP LOCATION '/u99/backup/rman/PROD'
4> NOFILENAMECHECK
5> UNTIL TIME "TO_DATE('2020-02-04 17:00:00', 'YYYY-MM-DD HH24:MI:SS')";
6> }
Starting Duplicate Db at 06-FEB-20
using target database control file instead of recovery catalog
allocated channel: ORA_AUX_DISK_1
channel ORA_AUX_DISK_1: SID=5638 device type=DISK
allocated channel: ORA_AUX_DISK_2
channel ORA_AUX_DISK_2: SID=7516 device type=DISK
allocated channel: ORA_AUX_DISK_3
channel ORA_AUX_DISK_3: SID=9395 device type=DISK
allocated channel: ORA_AUX_DISK_4
channel ORA_AUX_DISK_4: SID=11272 device type=DISK
contents of Memory Script:
{
set until scn 11722484126;
sql clone "alter system set db_name =
''PROD'' comment=
''Modified by RMAN duplicate'' scope=spfile";
sql clone "alter system set db_unique_name =
''STGE'' comment=
''Modified by RMAN duplicate'' scope=spfile";
shutdown clone immediate;
startup clone force nomount
restore clone primary controlfile;
alter clone database mount;
}
executing Memory Script
executing command: SET until clause
sql statement: alter system set db_name = ''PROD'' comment= ''Modified by RMAN duplicate'' scope=spfile
sql statement: alter system set db_unique_name = ''STGE'' comment= ''Modified by RMAN duplicate'' scope=spfile
Oracle instance shut down
Oracle instance started
Total System Global Area 12884901888 bytes
Fixed Size 3725224 bytes
Variable Size 12213815384 bytes
Database Buffers 637534208 bytes
Redo Buffers 29827072 bytes
Starting restore at 06-FEB-20
allocated channel: ORA_AUX_DISK_1
channel ORA_AUX_DISK_1: SID=5638 device type=DISK
allocated channel: ORA_AUX_DISK_2
channel ORA_AUX_DISK_2: SID=7516 device type=DISK
allocated channel: ORA_AUX_DISK_3
channel ORA_AUX_DISK_3: SID=9395 device type=DISK
allocated channel: ORA_AUX_DISK_4
channel ORA_AUX_DISK_4: SID=11272 device type=DISK
Oracle instance started
Total System Global Area 12884901888 bytes
Fixed Size 3725224 bytes
Variable Size 12213815384 bytes
Database Buffers 637534208 bytes
Redo Buffers 29827072 bytes
contents of Memory Script:
{
sql clone "alter system set db_name =
''STGE'' comment=
''Reset to original value by RMAN'' scope=spfile";
sql clone "alter system reset db_unique_name scope=spfile";
shutdown clone immediate;
}
executing Memory Script
sql statement: alter system set db_name = ''STGE'' comment= ''Reset to original value by RMAN'' scope=spfile
sql statement: alter system reset db_unique_name scope=spfile
Oracle instance shut down
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of Duplicate Db command at 02/06/2020 09:07:12
RMAN-05501: aborting duplication of target database
RMAN-03015: error occurred in stored script Memory Script
RMAN-06026: some targets not found - aborting restore
RMAN-06024: no backup or copy of the control file found to restore
Not sure what else is there to do to see what is wrong.. I have looked at a lot of FAQs and documentation, bur alas none with my issues.
If I do a duplicate without the set time, it works...