Previous  |  Next  >  
Product: Storage Foundation Guides   
Manual: Storage Foundation 4.1 FlashSnap Point-In-Time Copy Solutions Administrator's Guide   

Rolling Back a Database

To roll back a database, for example, after a logical error has occurred:

  1. Ensure that the database is offline. You can use the VxDBA utility to display the status of the database and its tablespaces, and to shut down the database:

    • Select 2 Display Database/VxDBA Information to access the menus that display status information.
    • Select 1 Database Administration > Shutdown Database Instance to shut down a database.

  2. Select 4 Storage Rollback Administration > Roll Back the Database to a Storage Checkpoint in the VxDBA utility, and choose the appropriate Storage Checkpoint. This restores all data files used by the database, except redo logs and control files, to their state at the time that the Storage Checkpoint was made.
  3. Start up, but do not open, the database instance by selecting 1 Database Administration > Startup Database Instance in the VxDBA utility.
  4. Use one of the following commands to perform an incomplete media recovery of the database:

    • Recover the database until you stop the recovery:
      • recover database until cancel;

        ...

        alter database [database] recover cancel;

    • Recover the database to the point just before a specified system change number, scn:
      • recover database until change scn;

    • Recover the database to the specified time:
      • recover database until time 'yyyy-mm-dd:hh:mm:ss';

    • Recover the database to the specified time using a backup control file:
      • recover database until time 'yyyy-mm-dd:hh:mm:ss' using \

        backup controlfile;


        Note   Note    To find out when an error occurred, check the ../bdump/alert*.log file.

        See the Oracle documentation for complete and detailed information on database recovery.

  5. To open the database after an incomplete media recovery, use the following command:

      alter database open resetlogs;


      Note   Note    The resetlogs option is required after an incomplete media recovery to reset the log sequence. Remember to perform a full database backup and create another Storage Checkpoint after log reset.
  6. Perform a full database backup, and use the VxDBA utility to remove any existing Storage Checkpoints that were taken before the one to which you just rolled back the database. These Storage Checkpoints can no longer be used for Storage Rollback. If required, use the VxDBA utility to delete the old Storage Checkpoints and to create new ones.

 ^ Return to Top Previous  |  Next  >  
Product: Storage Foundation Guides  
Manual: Storage Foundation 4.1 FlashSnap Point-In-Time Copy Solutions Administrator's Guide  
VERITAS Software Corporation
www.veritas.com