Date: Aug 2010
Affected Product & Version: NVBU 8.x
Affected Module & Version: APM for Oracle (Using RMAN based backups)
OS Version: any
Symptoms:
It is necessary to restore a copy of the production database files without impacting the running production database. The files are needed for a task outside of recovery of the production database. Any recovery will be handled by the DBA outside of NetVault.
Cause:
The files may be required as a DR test or for external tasks that are beyond the remit of NetVault. Note: The database files will not be a consistant database copy, database recovery will be required.
By using RMAN it is possible to restore database files to an alternate location which is outside the scope of the production instance.
E.G.
RMAN> connect target system/manager
RMAN> run {
2> allocate channel nvch1 type 'SBT_TAPE';
3> send 'NV_BACKUP_SERVER=NETVAULT_SRV';
4>
5> set newname for datafile 4 to 'c:\temp\users01.dbf';
6> restore datafile 4;
7> release channel nvch1;
8> }
allocated channel: nvch1
channel nvch1: SID=16 device type=SBT_TAPE
channel nvch1: NetVault Oracle APM v.6.0.18
sent command to channel: nvch1
executing command: SET NEWNAME
Starting restore at 02-AUG-10
channel nvch1: starting datafile backup set restore
channel nvch1: specifying datafile(s) to restore from backup set
channel nvch1: restoring datafile 00004 to c:\temp\users01.dbf
channel nvch1: reading from backup piece NETVAULT_SRV:#568:NETVAULT_SRV:33_725986009:RMAN FULL DB ORCL_1280756788
channel nvch1: piece handle=NETVAULT_SRV:#568:NETVAULT_SRV:33_725986009:RMAN FULL DB ORCL_1280756788 tag=TAG20100802T144649
channel nvch1: restored backup piece 1
channel nvch1: restore complete, elapsed time: 00:09:35
Finished restore at 02-AUG-10
released channel: nvch1
RMAN>
Explanation:
Using the "set newname" syntax RMAN can write the file to a new location seperate from the production database. See the "set newname" syntax for other types of files that can be renamed.
***IMPORTANT NOTE***
Quite often scripts would finally use the "switch datafile" command. This must NOT be done in this case as the result would be that this newly restored file would be adopted instead of the live production file. That will alter the production database.
© ALL RIGHTS RESERVED. Terms of Use Privacy Cookie Preference Center