RMAN - correlating Backup Media to RMAN Catalog
Date: Mon, 3 Nov 2008 11:16:49 -0700
Here's the platform info:
RMAN catalog - 10.2.0.3 on Windows 2003 Server
TARGET db: 188.8.131.52 on RH EL 4
BACKUP SW: NetBackup 6.0
The problem in a nutshell is that the MEDIA ID stored in the RMAN catalog does not correspond to the MEDIA ID stored to in the NBU catalog.
This happens when the media is copied to new media. The new Media ID of course does not match what is in RMAN. This new media is sent off site, the original media is reused.
If a query such as this is run:
select d.name, p.MEDIA, p.handle, p.start_time,p.completion_time,p.bytes
from rc_backup_piece p, rc_database d
where d.NAME = 'ORCL'
and d.dbid = 123456789 and p.COMPLETION_TIME >= TO_DATE('05/01/2008', 'mm/dd/yyyy') and p.COMPLETION_TIME <= TO_DATE('05/03/2008', 'mm/dd/yyyy') and p.db_id = d.dbid
order by p.media
The MEDIA column contains the information for the original media.
This is verified by running the query for a recent backup, one that has not yet been vaulted. In this case the query returns the correct MEDIA ID.
So, if the previous query is used to identify the media required to restore a backup from media that has been vaulted (say 5 months old), the MEDIA ID will be incorrect.
Does anyone here know how to update the MEDIA column in RMAN with the current MEDIA ID's?
I tried the following - it doesn't change the MEDIA column:
ALLOCATE CHANNEL FOR MAINTENANCE DEVICE TYPE sbt;
COMPLETED BETWEEN "to_date('05/01/2008','mm/dd/yyyy')" and "to_date('05/03/2008','mm/dd/yyyy')";
RELEASE CHANNEL; Thanks,
Certifiable Oracle DBA and Part Time Perl Evangelist