How To Transfer Enviroments Variables To Rman

I like show how to pass substitution variables from shell to Rman script.

The code for shell scrit is thw followig, please note I use the KSH shell;

 
#!/bin/ksh
set name      = $argv[1]
set format    = $argv[2]
rman @execute_backup.rcv using $tag $format

Below I show the code for rman script named execute_backup.rcv;

 
connect target /
run 
{
backup database
tag &1
format '&2 ';
}
exit;

HTH – Antonio NAVARRO

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s