Restoring files

To restore IBM® Storage Protect Snapshot backups by restoring specific files, complete the following steps.

Procedure

  1. If the database is running, enter the following command to stop the database:
    shutdown;
  2. Enter the following command to mount the database:
    startup mount;
  3. Enter the following command to start RMAN and connect to the target database and the recovery catalog. Enter the command on one line.
    rman target username/password rcvcat username
    		/password@connect_string
    The RMAN command in the preceding example is divided to accommodate page formatting. The actual RMAN command string is on one line.
  4. Issue a RMAN run command by specifying the allocation of channels and the restoration of the data file n, where n is the number of the data file. The following example is from an AIX® installation:
    run
    {
    allocate channel t1 type 'sbt_tape' parms 
    'ENV=(TDPO_OPTFILE=/usr/tivoli/tsm/client/oracle/bin/tdpo.opt)';
    allocate channel t2 type 'sbt_tape' parms 
    'ENV=(TDPO_OPTFILE=/usr/tivoli/tsm/client/oracle/bin/tdpo.opt)';
    allocate channel t3 type 'sbt_tape' parms 
    'ENV=(TDPO_OPTFILE=/usr/tivoli/tsm/client/oracle/bin/tdpo.opt)';
    allocate channel t4 type 'sbt_tape' parms 
    'ENV=(TDPO_OPTFILE=/usr/tivoli/tsm/client/oracle/bin/tdpo.opt)';
    restore datafile n;
    }

    This example can also apply to Linux™, Solaris and HP-UX platforms, except that the path to the tdpo.opt file differs. On Linux, Solaris and HP-UX platforms, the path is likely to start with /opt/tivoli.

  5. Enter the following SQL command to bring the data file online. The n variable is the number of the data file.
    alter database datafile n online;
  6. Recover the data file by connecting to the target database and entering the following command:
    recover datafile n;

What to do next

If your restore is not successful and you receive an error message, see the error log file for assistance.