Oracle internals, debugging and undocumented features
I was trying to duplicate production database to development using 11g feature DUPLICATE DATABASE … FROM ACTIVE DATABASE .
I did it in the past and worked every time but not today..
ALLOCATE CHANNEL ch1 DEVICE TYPE disk;
ALLOCATE AUXILIARY CHANNEL ach1 DEVICE TYPE disk;
duplicate target database to test from active database;
Scripts will run fine until end and then RMAN will give error
RMAN-06004: ORACLE error from recovery catalog database: RMAN-20242: specification does not match any archived log in the recovery catalog
I tried few times but without success.. Then I have realized that must be issue with archive log destination parameters etc..
The reason my duplicate command worked in the past is that I did not have data guard configured.RMAN does not like to have standby archivelog destinations configured.
This is Oracle Bug 6603587.
For DUPLICATE DATABASE FOR STANDBY FROM ACTIVE, simply avoid using the
DORECOVER clause. Logs will ship naturally as part of the standby log
For DUPLICATE TARGET DATABASE foo FROM ACTIVE, defer all standby destinations
prior to executing the command.
I think RMAN should be called BUGMAN.