To create the standby database, you must first take a back-up copy of the data files of the primary database, create a back-up control file for the standby database, and archive the on-line redo logs of the primary database. The backed-up data files, control file and archived log files can then be transferred to a remote site where the standby database will be maintained.

To create a standby database, perform the following procedures:

  1. Back-up the data files from your primary database. The back-ups can be done either on-line or off-line.

 
  • Create the control file for your standby database by issuing the following command:
     
    ALTER DATABASE CREATE STANDBY CONTROLFILE AS 'filename' 

    This command creates a modified back-up copy of the primary database's control file.

  • Archive the current on-line redo logs of the primary database by issuing the following command:
     
    ALTER SYSTEM ARCHIVE LOG CURRENT  

    This command forces a log switch on all threads and archives of the redo at an scn after the data files have been backed-up.

  • Transfer the standby database control file, archived log files and backed-up data files to the remote (standby) site.

INIT.ORA Notes

The DB_NAME value must be the same in both the standby and production init.ora files.

If the standby database resides on the same file system as your primary database, set the LOCK_NAME_SPACE parameter in the standby init.ora file to a distinct value. For example, enter:

LOCK_NAME_SPACE = standby