Diferentes ejemplos:
RMAN> CATALOG DATAFILECOPY '/u01/bkp_datafiles/users01.dbf';
RMAN> CATALOG ARCHIVELOG '/u01/arch_logs/arch_t1_898.arc', '/u01/arch_logs/arch_t1_899.arc';
RMAN> CATALOG BACKUPPIECE '/u01/backups/RMAN/l5sbtg9f_1_1';
RMAN> CATALOG START WITH '/u01/backups/RMAN';
Hay varias situaciones que pueden requerir esta "catalogación" o "re-catalogación" manual:
RMAN> CATALOG ARCHIVELOG '/u01/arch_logs/arch_t1_898.arc', '/u01/arch_logs/arch_t1_899.arc';
RMAN> CATALOG BACKUPPIECE '/u01/backups/RMAN/l5sbtg9f_1_1';
RMAN> CATALOG START WITH '/u01/backups/RMAN';
Hay varias situaciones que pueden requerir esta "catalogación" o "re-catalogación" manual:
- You copy or move a backup piece with an operating system utility and want it to be usable by RMAN.
- The RMAN metadata for the backup piece was removed, but the backup piece still exists. This situation can occur if you ran the
DELETE
command on a backup piece that was only temporarily unavailable. - You make a
NOCATALOG
backup on one database host in a Data Guard environment and move the backup piece to the same location on a different database host. In this case, the recovery catalog has no record of the original backup piece. - You do not use a recovery catalog and must re-create the control file, thereby losing all RMAN repository data. Cataloging your backups makes them available again.
- When control file autobackup is disabled, you back up the control file and then back up the archived redo logs. You can restore and mount the control file, but must catalog the backup pieces containing the archived redo logs backed up after the control file.
Pero no es posible utilizar el comando CATALOG para catalogar piezas almacenadas en cinta (tape).
Ahora, vamos a ver un comando "no documentado" que, bajo ciertas condiciones, SI nos permite realizar esta tarea :
CATALOG DEVICE TYPE 'SBT_TAPE' BACKUPPIECE '<handle>';
Donde handle es el nombre "físico" de la pieza en cinta.
Requerimientos:
1- Usar "automatic channel configuration". Es obligatorio configurar un "sbt_tape device channel" en la configuración de RMAN.
2- Es necesario saber el nombre de archivo de la pieza en la cinta, y ésta debe estar disponible y accesible.
Procedimiento:
Procedimiento:
Una vez configurado el canal correspondiente, utilizamos el siguiente comando:
Veamos un ejemplo (aqui utilizamos Data Protector como Tape):
1- Configuramos el canal a cinta:
RMAN> CONFIGURE CHANNEL DEVICE TYPE 'SBT_TAPE' PARMS 'SBT_LIBRARY=/opt/omni/lib/libob2oracle8_64bit.so,ENV=(OB2BARTYPE=Oracle8,OB2APPNAME=SORCL,OB2BARLIST=Oracle_RMAN_SERVER01-ORCL_tape)';
2- Catalogamos una pieza:
RMAN> CATALOG DEVICE TYPE 'SBT_TAPE' BACKUPPIECE
'Oracle_RMAN_server01_ORCL_arch_68873:952312842';
Como ya mencionamos, Oracle_RMAN_server01_ORCL_arch_68873:952312842 en e4ste caso es el handle o nombre de la pieza en cinta.
Salida completa:
RMAN> released channel: ORA_SBT_TAPE_1
allocated channel: ORA_SBT_TAPE_1
channel ORA_SBT_TAPE_1: SID=266 device type=SBT_TAPE
channel ORA_SBT_TAPE_1: Data Protector A.06.20/407
RMAN> CATALOG DEVICE TYPE 'SBT_TAPE' BACKUPPIECE 'Oracle_RMAN_server01_ORCL_arch_68873:952312842';
RMAN> cataloged backup piece
backup piece handle=Oracle_RMAN_server01_ORCL_arch_68873:952312842 RECID=57223 STAMP=952361127
No hay comentarios:
Publicar un comentario