Monday, October 17, 2016

ORA-19554: error allocating device, device type: SBT_TAPE, device name:

Problem:

Getting an error ORA-19554: error allocating device, device type: SBT_TAPE, device name: when trying to duplicate the database to standby database

RMAN> duplicate target database for standby from active database
2> spfile
3> set audit_file_dest='/u01/app/oracle/admin/db1tesd/adump'
4> set db_unique_name='db1tesd'
5> set fal_server='db1tesp1','db1tesp2'
6> set instance_number='1'
7> NOFILENAMECHECK;
Starting Duplicate Db at 17-OCT-16
using target database control file instead of recovery catalog
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of Duplicate Db command at 10/17/2016 02:30:46
RMAN-05501: aborting duplication of target database
RMAN-03009: failure of allocate command on ORA_AUX_SBT_TAPE_1 channel at 10/17/2016 02:30:46
ORA-19554: error allocating device, device type: SBT_TAPE, device name:
ORA-27211: Failed to load Media Management Library
Additional information: 2
RMAN>

Issue1:

The issue here is that SBT_TAPE variable is set and causing the problem.

CONFIGURE DEVICE TYPE 'SBT_TAPE' PARALLELISM 1 BACKUP TYPE TO BACKUPSET;

Fix 1:

Check the current value of SBT_TAPE

$ rman target /
RMAN> show DEVICE TYPE;
RMAN configuration parameters for database with db_unique_name DB1TESP are:
CONFIGURE DEVICE TYPE 'SBT_TAPE' PARALLELISM 1 BACKUP TYPE TO BACKUPSET;
CONFIGURE DEVICE TYPE DISK PARALLELISM 1 BACKUP TYPE TO BACKUPSET; # default
RMAN>
RMAN> CONFIGURE DEVICE TYPE 'SBT_TAPE' clear;
old RMAN configuration parameters:
CONFIGURE DEVICE TYPE 'SBT_TAPE' PARALLELISM 1 BACKUP TYPE TO BACKUPSET;
RMAN configuration parameters are successfully reset to default value
RMAN>
RMAN> show DEVICE TYPE;
RMAN configuration parameters for database with db_unique_name DB1TESP are:
CONFIGURE DEVICE TYPE DISK PARALLELISM 1 BACKUP TYPE TO BACKUPSET; # default
RMAN> 

Issue 2:

RMAN had below setting
CONFIGURE DEFAULT DEVICE TYPE TO 'SBT_TAPE';

Fix 2: 
Just clear this setting and try again
RMAN> CONFIGURE DEFAULT DEVICE TYPE clear;

old RMAN configuration parameters:
CONFIGURE DEFAULT DEVICE TYPE TO 'SBT_TAPE';
RMAN configuration parameters are successfully reset to default value

RMAN> show DEVICE TYPE;

RMAN configuration parameters for database with db_unique_name QA1CSMP are:
CONFIGURE DEVICE TYPE DISK PARALLELISM 1 BACKUP TYPE TO BACKUPSET; # default

RMAN>

RMAN>

RMAN> show default DEVICE TYPE;

RMAN configuration parameters for database with db_unique_name QA1CSMP are:
CONFIGURE DEFAULT DEVICE TYPE TO DISK; # default

RMAN>

Now you will not get the error !!! Happy Days :)


No comments: