cancel
Showing results for 
Search instead for 
Did you mean: 

RMAN 'SEND' Command Question

Michele_2
Level 4
Our DBA is having an issue with RMAN backups through Netbackup.
We discovered the need to send the NB_ORA_POLICY parameter to Netbackup to avoid the policy being incorrect on the Default-Application-Backup. So, the DBA the following in the backup script (after setting the variable name for the policy) -
 
run
{
send 'NB_ORA_POLICY=${NB_POLICY_NAME}' ;
BACKUP RECOVERY AREA;
}
 
This resulted in the folloing error -
 
RMAN> 2> 3> 4> 5>
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of send command at 07/29/2010 15:14:52
RMAN-06422: no channels found for SEND command
 
The Channels and other configuration parameters are set within RMAN as follows -
 
RMAN configuration settings (configured within RMAN)
CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 35 DAYS;
CONFIGURE BACKUP OPTIMIZATION ON;
CONFIGURE DEFAULT DEVICE TYPE TO DISK; # default
CONFIGURE CONTROLFILE AUTOBACKUP ON;
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE 'SBT_TAPE' TO '%F';
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '%F'; # default
CONFIGURE DEVICE TYPE DISK PARALLELISM 2 BACKUP TYPE TO BACKUPSET;
CONFIGURE DEVICE TYPE 'SBT_TAPE' PARALLELISM 2 BACKUP TYPE TO BACKUPSET;
CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE SBT_TAPE TO 1; # default
CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE SBT_TAPE TO 1; # default
CONFIGURE CHANNEL DEVICE TYPE 'SBT_TAPE' MAXPIECESIZE 32 G;
CONFIGURE MAXSETSIZE TO UNLIMITED; # default
CONFIGURE ENCRYPTION FOR DATABASE OFF; # default
CONFIGURE ENCRYPTION ALGORITHM 'AES128'; # default
CONFIGURE COMPRESSION ALGORITHM 'BZIP2'; # default
CONFIGURE ARCHIVELOG DELETION POLICY TO NONE; # default
CONFIGURE SNAPSHOT CONTROLFILE NAME TO '+ASM_FRA/cat11g1/snap_cf_cat11g1.f';
 
As you can see the "CONFIGURE CHANNEL DEVICE TYPE 'SBT_TAPE' MAXPIECESIZE 32 G;" is set in this configuration.
 
When the DBA added the ALLOCATE to the run block the script does work and sends the correct policy name to Netbackup, but it seems to lose/override all the above configuration, specifically the MAXPIECESIZE parameter. Adding this to the ALLOCATE in the run block does not seem to correct this issue -
 
run
{
ALLOCATE CHANNEL T1 TYPE 'SBT_TAPE' MAXPIECESIZE 32 G;
send 'NB_ORA_POLICY=${NB_POLICY_NAME}' ;
BACKUP RECOVERY AREA;
RELEASE CHANNEL T1;
}
 
So, the question is, Can we use the SEND command in the RMAN script run block and have it use the pre-set CONFIGURE values, instead of having the ALLOCATE command in the script?
1 ACCEPTED SOLUTION

Accepted Solutions

Michele_2
Level 4
Our DBA found that the following syntax works -


run
{
ALLOCATE CHANNEL T1 TYPE 'SBT_TAPE' MAXPIECESIZE 32 G;
send 'NB_ORA_POLICY=${NB_POLICY_NAME}' ;
BACKUP RECOVERY AREA;
RELEASE CHANNEL T1;
}

She verified the MAXPIECESIZE is working and that the configurations in RMAN, aside from the ones overridden by the ALLOCATE CHANNEL still apply.

Thanks everyone for your replies.

View solution in original post

8 REPLIES 8

Will_Restore
Level 6
CONFIGURE CHANNEL on the RMAN server is not the same thing as
ALLOCATE CHANNEL on the oracle client.

>>So, the question is, Can we use the SEND command in the RMAN script run block and have it use the pre-set CONFIGURE values, instead of having the ALLOCATE command in the script?

You still have to allocate and release channel(s) on the client.

Michele_2
Level 4
Bill,

Thank you for the quick response!

I am the Linux Sys Admin, so forgive me for playing middle-man.

Without sending the NB_ORA_POLICY value, the RMAN script does not use an ALLOCATE -

run
{
BACKUP RECOVERY AREA;
}

Once our DBA added the 'SEND' the ALLOCATE was needed. Which makes sense, I guess.

She is also wondering why adding the 'ALLOCATE CHANNEL T1 TYPE 'SBT_TAPE' MAXPIECESIZE 32 G;' did not set the MAXPIECESIZE as expected?

Thank you again!

Marianne
Level 6
Partner    VIP    Accredited Certified

MAXPIECESIZE seems to be relevant to  CHANNEL DEVICE TYPE DISK only - thus explaining why it is ignored when used with SBT_TAPE.
See:
http://download.oracle.com/docs/cd/B14117_01/server.101/b10734/rcmconc1.htm#1007483

RMAN ALLOCATE: http://download.oracle.com/docs/cd/B14117_01/server.101/b10770/rcmsynta4.htm#RCMRF102

SEND is used to send a vendor-specific quoted string to one or more specific channels. A list of RMAN SEND command variables can be found in the NBU for Oracle Admin Guide: ftp://exftpp.symantec.com/pub/support/products/NetBackup_Enterprise_Server/340131.pdf





Will_Restore
Level 6

did you try 32G (without the space) ?

Will_Restore
Level 6

Example 3–2 Setting the Maximum Size of a Backup Piece

This example manually allocates an SBT channel, which specifies an Oracle Secure

Backup tape drive, and makes a whole database backup. The MAXPIECESIZE

parameter specifies that no backup piece written to tape should exceed 800 MB.

RUN

{

ALLOCATE CHANNEL c1 DEVICE TYPE sbt

PARMS 'SBT_LIBRARY=/usr/local/oracle/backup/lib/libobk.so, ENV=(OB_DEVICE_1=stape1)'

MAXPIECESIZE 800M;

BACKUP DATABASE;

}
 

http://download.oracle.com/docs/cd/B28359_01/backup.111/b28273.pdf

Michele_2
Level 4
Thank you for the responses!

I will relay your advice to our DBA and test again next week.

Marianne
Level 6
Partner    VIP    Accredited Certified

Good find, Bill. The only reference to MAXPIECESIZE that I could find was related to DISK. I have honestly never seen it in any RMAN script at any of our customers (obviously channel of type sbt_tape). I wonder what the relevance is when used with tape? Maybe Michele can ask their DBA?

Michele_2
Level 4
Our DBA found that the following syntax works -


run
{
ALLOCATE CHANNEL T1 TYPE 'SBT_TAPE' MAXPIECESIZE 32 G;
send 'NB_ORA_POLICY=${NB_POLICY_NAME}' ;
BACKUP RECOVERY AREA;
RELEASE CHANNEL T1;
}

She verified the MAXPIECESIZE is working and that the configurations in RMAN, aside from the ones overridden by the ALLOCATE CHANNEL still apply.

Thanks everyone for your replies.