Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> problem DUPLICATE DATABASE IN OTHER NODE WITH RMAN CATALOG
problem:
duplicate database in other node .
Machine A - (PRODUCTION DATABASE) - Database EDISA - SID EDISA - Oracle 817 std edition in Windows2000 server.
Machine B - (TEST DATABASE) > Database PRUEBAS - SID PRUEBAS - Oracle 817 std edition in Windows2000 server.
I have a complete backup of the database with rman in catalog mode ,
the rman catalog
is instaled in the machine B rman/rman_at_rman
The destination of the backup is type disk in the machine A
G:\ORABACKUP\ In the machine B i have a link to \\MachineA\g mapped to G:
G:\ORABACKUP\ In the machine B i have a database named PRUEBAS , sid PRUEBAS the destination of the database are
f:\oracle\oradata\pruebas
I copied the init.ora of the database EDISA in machine A f:\oracle\admin\edisa\pfile\init.ora
to
machine B f:\oracle\admin\pruebas\pfile\init.ora
edit the init.ora in the machine B and change the parameters
###db_name = "EDISA"
db_name = "PRUEBAS"
###instance_name = EDISA
instance_name = PRUEBAS
###control_files = ("F:\oracle\oradata\EDISA\control01.ctl", "F:\oracle\oradata\EDISA\control02.ctl", "F:\oracle\oradata\EDISA\control03.ctl") control_files = ("F:\oracle\oradata\PRUEBAS\control01.ctl", "F:\oracle\oradata\PRUEBAS\control02.ctl", "F:\oracle\oradata\PRUEBAS\control03.ctl")
###log_archive_dest = "G:\oradata\EDISA\archive" log_archive_dest = "F:\oracle\oradata\PRUEBAS\archive"
###background_dump_dest = F:\oracle\admin\EDISA\bdump background_dump_dest = F:\oracle\admin\PRUEBAS\bdump
###user_dump_dest = F:\oracle\admin\EDISA\udump user_dump_dest = F:\oracle\admin\PRUEBAS\udump
db_file_name_convert = ('F:\ORACLE\ORADATA\EDISA',
'F:\ORACLE\ORADATA\PRUEBAS')
log_file_name_convert = ('F:\ORACLE\ORADATA\EDISA',
'F:\ORACLE\ORADATA\PRUEBAS')
remote_login_passwordfile = exclusive
In the machine B
SQL> connect internal/kernel_at_pruebas conectado a una instancia inactiva SQL> startup nomount Instancia de ORACLE arrancada. Total System Global Area 150243356 bytes Fixed Size 75804 bytes Variable Size 67215360 bytes Database Buffers 81920000 bytes Redo Buffers 1032192 bytes
In the machine B i start the rman
RMAN RCVCAT RMAN/RMAN_at_RMAN TARGET=SYSTEM/MANAGER_at_EDISA AUXILIARY=INTERNAL/KERNEL_at_PRUEBAS RUN
{ ALLOCATE AUXILIARY CHANNEL CH1 TYPE DISK; duplicate target database to PRUEBAS; RELEASE CHANNEL CH1; }
the output of this is:
Recovery Manager: Versión 8.1.7.0.0 - Production
RMAN-06005: conectado a la base de datos destino: EDISA
(DBID=2598999380)
RMAN-06008: conectado a la base de datos del catálogo de recuperación
RMAN-06020: conectado a una base de datos auxiliar
RMAN>
RMAN> RUN
2> { 3> ALLOCATE AUXILIARY CHANNEL CH1 TYPE DISK; 4> duplicate target database to PRUEBAS; 5> RELEASE CHANNEL CH1; 6> } RMAN-03022: compilando el comando: allocate RMAN-03023: ejecutando el comando: allocateRMAN-08030: canal asignado: CH1
RMAN-03022: compilando el comando: Duplicate Db
RMAN-03027: imprimiendo el fichero de comandos almacenado: Memory
Script
{
set until scn 48459944;
set newname for datafile 1 to
"F:\ORACLE\ORADATA\PRUEBAS\SYSTEM01.DBF";
set newname for datafile 2 to
"F:\ORACLE\ORADATA\PRUEBAS\LIBRA_DATOS2.ORA";
set newname for datafile 3 to
"F:\ORACLE\ORADATA\PRUEBAS\USERS01.DBF";
set newname for datafile 4 to
"F:\ORACLE\ORADATA\PRUEBAS\LIBRA_LOGFILE.ORA";
set newname for datafile 5 to
"F:\ORACLE\ORADATA\PRUEBAS\TOOLS01.DBF";
set newname for datafile 6 to
"F:\ORACLE\ORADATA\PRUEBAS\LIBRA_DATOS.ORA";
set newname for datafile 7 to
"F:\ORACLE\ORADATA\PRUEBAS\OEM_REPOSITORY.ORA";
set newname for datafile 8 to
"F:\ORACLE\ORADATA\PRUEBAS\ROLLBACK.ORA";
set newname for datafile 9 to
"F:\ORACLE\ORADATA\PRUEBAS\IDX.ORA";
restore
check readonly
clone database
;
sql clone " CREATE CONTROLFILE REUSE SET DATABASE ^"PRUEBAS^"
RESETLOGS ARCHIVELOG
MAXLOGFILES 32 MAXLOGMEMBERS 2 MAXDATAFILES 254 MAXINSTANCES 1
RMAN-03022: compilando el comando: set
RMAN-03022: compilando el comando: set
RMAN-03022: compilando el comando: set
RMAN-03022: compilando el comando: set
RMAN-03022: compilando el comando: set
RMAN-03022: compilando el comando: set
RMAN-03022: compilando el comando: set
RMAN-03022: compilando el comando: set
RMAN-03022: compilando el comando: set
RMAN-03022: compilando el comando: set
RMAN-03022: compilando el comando: restore
RMAN-03022: compilando el comando: IRESTORE RMAN-03023: ejecutando el comando: IRESTORE RMAN-08016: canal CH1: iniciando restauración del juego de copias deseguridad de ficheros de datos
RMAN-03026: error de recuperación al liberar los recursos de canales RMAN-08031: canal liberado: CH1 RMAN-00571: =========================================================== RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS
RMAN-00571: =========================================================== RMAN-03002: failure during compilation of command RMAN-03013: command type: Duplicate Db RMAN-03015: error occurred in stored script Memory Script RMAN-03002: failure during compilation of commandRMAN-03013: command type: restore
ORA-27041: no se ha podido abrir el fichero OSD-04002: no se ha podido abrir el fichero O/S-Error: (OS 5) Acceso denegado. ORA-06512: en "SYS.X$DBMS_BACKUP_RESTORE", línea 1157RMAN-10031: ORA-19624 occurred during call to DBMS_BACKUP_RESTORE.RESTOREBACKUPPIECE Received on Fri Nov 07 2003 - 05:48:07 CST