Restoring the SAP Oracle Database from the SAP Command Line


On this page

You can recover the Oracle database using SAP command line interface.


  1. Restore the Oracle application available under the <oracle install> directory using the File System iDataAgent.

  2. Restore the Oracle database files using the SAP command line. To this purpose, use the following general steps in the order presented:

    1. Ensure that the appropriate profiles exist, the profile names are defined appropriately, and the parameters are correctly set. Then use BRRESTORE to restore each required file (including the current summary log and current detail log) individually.

    2. Use BRRESTORE to completely restore the backup (i.e., reset the database to the last online or offline backup).

    3. Use BRRESTORE to restore the required offline redo log files from the BRARCHIVE media.

  3. Restore init<SID>.ora file:

        brrestore -d util_file -b2 becmmcsy.anf -m /oracle_setup/dbs/init<SID>.ora
  4. Restore init<SID>.utl file:

        brrestore -d util_file -b2 becmmcsy.anf -m /oracle_setup/dbs/init<SID>.utl
  5. Restore init<SID>.sap file:

        brrestore -d util_file -b2 becmmcsy.anf -m /oracle_setup/dbs/init<SID>.sap
  6. Restore Control File:

        brrestore -d util_file -m 0
  7. Restore DataFiles:

        brrestore -d util_file -b last -m all -u /
  8. Restore Archive logs:

        brrestore -a <From ARCHIVE LOG# - To ARCHIVE LOG#>
  9. After restoring the above files, run recover database manually using backup control file:

        sql>recover database using backup controlfile until cancel;
  10. Reset open DB with RESET LOGS option:

        sql>alter database open resetlogs;

    Note: init<SID>.ora, init<SID>.sap and init<SID>.utl can only be restored by SAP Command Line Interface. The remaining files such as control file, data files, archive log files can also be restored from CommCell Console.

For more information on Disaster Recovery using BRRESTORE, refer SAP documentation.


The database is restored to the directory where it resides.