Anthony Key
asked on
Use RMAN restore database validate before restoring database in the same script
Hi All, I have a rman restore script that I would like to execute and I would like to validate the backup before I restore and I'd like to do it in one script is this possible. Below is a simple rman restore that I plan on using.
connect target;
connect catalog HR89QAT/rcvhcm@RCVHCM;
shutdown immediate;
startup mount;
run
{
## restore database validate;
## if validate invalid or not good then exit otherwise restore database
allocate channel c5 type 'sbt_tape';
allocate channel c6 type 'sbt_tape';
restore database;
recover database;
alter database open;
release channel c5;
release channel c6;
}
Thanks,
7Souls
connect target;
connect catalog HR89QAT/rcvhcm@RCVHCM;
shutdown immediate;
startup mount;
run
{
## restore database validate;
## if validate invalid or not good then exit otherwise restore database
allocate channel c5 type 'sbt_tape';
allocate channel c6 type 'sbt_tape';
restore database;
recover database;
alter database open;
release channel c5;
release channel c6;
}
Thanks,
7Souls
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.