Experience: is what you get soon after you need it.

Experience: is what you get soon after you need it.

Rasul Allah (sal Allahu alaihi wa sallam) said: "Restore the trusts of those who trust you, and deal not falsely with him who deals falsely with you." [Abu Dawud, Tirmidhi]

Search This Blog

Friday, September 16, 2011

ORA-19870: error reading backup piece ORA-19507: failed to retrieve sequential file handle= parms="" ORA-27029:

You are trying to duplicate the database from host-A to host-B via Netbackup Tape library. During the duplicate process you see the below errors:

ORA-19870: error reading backup piece lemmjmn2_1_1

ORA-19507: failed to retrieve sequential file, handle="lemmjmn2_1_1", parms=""

ORA-27029: skgfrtrv: sbtrestore returned error

ORA-19511: Error received from media manager layer, error text:

Backup file not found in NetBackup catalog

ORA-19870: error reading backup piece ldmmjlv8_1_1

ORA-19507: failed to retrieve sequential file, handle="ldmmjlv8_1_1", parms=""

ORA-27029: skgfrtrv: sbtrestore returned error

ORA-19511: Error received from media manager layer, error text:

Backup file not found in NetBackup catalog


and your backup script may look like this..

connect target rmanbackup/pwd@myproddb;
connect auxiliary /;
run
{
allocate auxiliary channel ch01 device type 'SBT_TAPE' ;
allocate auxiliary channel ch02 device type 'SBT_TAPE' ;
allocate auxiliary channel ch03 device type 'SBT_TAPE' ;
SET UNTIL TIME "TO_DATE('09/15/2011 12:45:00', 'MM/DD/YYYY HH24:MI:SS')" ;
send 'NB_ORA_POLICY=MY_POLICY_PROD,NB_ORA_CLIENT=myclientname';
duplicate target database to 'DUPDB';
release channel ch01;
release channel ch02;
release channel ch03;
}

Here if you see you left the parms parameter in the channel and defined it as send block.. due to this Netbackup was unable to read the backup pieces from the catalog.

Remove the send block and add the parms command in the channel defenition as below.
connect target rmanbackup/pwd@myproddb;
connect auxiliary /;
run
{
allocate auxiliary channel ch01 device type 'SBT_TAPE' params="ENV=(NB_ORA_POLICY=myprodpolicy,NB_ORA_CLIENT=myprodclient)";
allocate auxiliary channel ch02 device type 'SBT_TAPE' params="ENV=(NB_ORA_POLICY=myprodpolicy,NB_ORA_CLIENT=myprodclient)";
allocate auxiliary channel ch03 device type 'SBT_TAPE' params="ENV=(NB_ORA_POLICY=myprodpolicy,NB_ORA_CLIENT=myprodclient)";
SET UNTIL TIME "TO_DATE('09/15/2011 12:45:00', 'MM/DD/YYYY HH24:MI:SS')" ;
duplicate target database to 'mydupdb';
release channel ch01;
release channel ch02;
release channel ch03;
}

reference:
http://www.symantec.com/docs/TECH43525

No comments: