How to Multiplex Control Files in Oracle 11g

Step 1:-Backup your current control file with a trace option
SQL> ALTER DATABASE BACKUP CONTROLFILE TO TRACE;

Database altered.

Step-2: List all the controlfiles

SQL> select name from v$controlfile;

NAME
---------------------------------------------------------
/u01/app/oracle/oradata/prim/control01.ctl
/u01/app/oracle/flash_recovery_area/prim/control02.ctl


Step-3 Shutdown the database
SQL> shut immediate;
Database closed.
Database dismounted.
ORACLE instance shut down.

Step 4:-Add one more controlfile
[oracle@server1 prim]$cp /u01/app/oracle/oradata/prim/control01.ctl /home/oracle/Multiplexed_control_files/control03.ctl

Step-5: Create PFILE using SPFILE
[oracle@server1 dbs]$ sqlplus / as sysdba
SQL> create pfile from spfile;

File created.

[oracle@server1 prim]$ cd /u01/app/oracle/product/11.2.0/db_1/dbs/
##Add the newly created control file.
[oracle@server1 dbs]$ vi initprim.ora
*.control_files='/u01/app/oracle/oradata/prim/control01.ctl','/u01/app/oracle/flash_recovery_area/prim/control02.ctl','/home/oracle/Multiplexed_control_files/control03.ctl'

:wq

Step 5:-Create SPFILE using PFILE
SQL> create spfile from pfile='/u01/app/oracle/product/11.2.0/db_1/dbs/initprim.ora';
File created.

Step 6:- Start the database
SQL> startup
ORACLE instance started.

Total System Global Area  413372416 bytes
Fixed Size                  2213896 bytes
Variable Size             327157752 bytes
Database Buffers           79691776 bytes
Redo Buffers                4308992 bytes
Database mounted.
Database opened.

SQL> select name from v$controlfile;

NAME
--------------------------------------------------------------------------------
/u01/app/oracle/oradata/prim/control01.ctl
/u01/app/oracle/flash_recovery_area/prim/control02.ctl
/home/oracle/Multiplexed_control_files/control03.ctl

Done...

No comments:

Post a Comment