In this article, we will see the conversion of the non-RAC database to RAC database using DBCA.
Single Instance DB Name | RAC DB name | RAC Instance Node | RAC Instance Name | RAC Node Name |
dbtest | testrac | Node 1 | testrac1 | RAC1 |
Node 2 | testrac2 | RAC2 |
Part 1: Create a template from existing database.
Step 1: Run DBCA from Single Instance database home.
Step 2 : Choose Single Instance database and click on next then Click on Manage Templates from given list.
Step 3 : Click on Create a database template , and choose from an existing database [Structure as well as data].
Step 4 : Choose and database instance name from which you want to create a template and click next.
Step 5 : Give the name of template , description and destination of template file :
Step 6 : Choose to maintain the file location.
Step 7: It will ask for confirmation click on ok and click Finish.
Step 8 : Check clone template generation progress.
Once it is finished it will ask for “do you want to perform another operation?” click No and then ok.
Check created template in $ORACLE_HOME/assistants/dbca/templates.
[oracle@rac1 ~]$ cd $ORACLE_HOME/assistants/dbca/templates [oracle@rac1 templates]$ ll total 594776 -rw-r----- 1 oracle oinstall 9748480 Mar 25 00:26 Conversion_non_RAC-DB_to_RAC_DB.ctl -rw-r----- 1 oracle oinstall 4802 Mar 25 00:27 Conversion_non_RAC-DB_to_RAC_DB.dbc -rw-r----- 1 oracle oinstall 290512896 Mar 25 00:26 Conversion_non_RAC-DB_to_RAC_DB.dfb -rw-r--r-- 1 oracle oinstall 5104 Aug 24 2013 Data_Warehouse.dbc -rwxr-xr-x 1 oracle oinstall 21741568 Aug 27 2013 example01.dfb -rwxr-xr-x 1 oracle oinstall 1507328 Aug 27 2013 example.dmp -rw-r--r-- 1 oracle oinstall 4984 Aug 24 2013 General_Purpose.dbc -rw-r--r-- 1 oracle oinstall 11489 May 1 2013 New_Database.dbt -rwxr-xr-x 1 oracle oinstall 9748480 Aug 27 2013 Seed_Database.ctl -rwxr-xr-x 1 oracle oinstall 275750912 Aug 27 2013 Seed_Database.dfb
Step 9 : Transfer all files like Conversion_non_RAC-DB_to_RAC_DB.ctl,.dbc,.dfb file to RAC2.
[oracle@rac1 templates]$ scp Conversion_non_RAC-DB_to_RAC_DB.* rac2:$ORACLE_HOME/assistants/dbca/templates/ Conversion_non_RAC-DB_to_RAC_DB.ctl 100% 9520KB 9.3MB/s 00:01 Conversion_non_RAC-DB_to_RAC_DB.dbc 100% 4802 4.7KB/s 00:00 Conversion_non_RAC-DB_to_RAC_DB.dfb 100% 277MB 4.5MB/s 01:01 [oracle@rac1 templates]$
Part 2 : Create new RAC database from existing template.
Step 1 : Run dbca from RAC database home. Choose RAC Database.
Step 2 : Choose to create a database and click next.
Step 3 : Choose template we have created recently, Conversion non RAC -DB to RAC-DB.
Step 4 : Choose configuration type as admin managed and choose nodes for RAC database.
Step 5 : Click on configure Enterprise manager , if you want to enable EM.
Step 6 : In next step give Same Administrator password for all accounts , give confirm password and click on next.
Step 7 : Give Storage type as ASM and define Database area as +DATA [your ASM disk].
Step 8 : Specify Fast Recovery Area and Enable archiving (optional).
Step 9 : Custom Scripts :- As I have no scripts for Post database creation so choose no scripts to run and click next.
Step 10 : Set the memory parameters
Step 10: Check the Create Database and Click on finish .
Step 11 : Check Progress of Database creation , once it is created click on close.
Step 12 : Connect database from node RAC1 instance and check active instances.
[oracle@rac1 ~]$ export ORACLE_SID=testrac1 [oracle@rac1 ~]$ sqlplus / as sysdba SQL*Plus: Release 11.2.0.4.0 Production on Sun Mar 25 12:56:13 2018 Copyright (c) 1982, 2013, Oracle. All rights reserved. Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP, Data Mining and Real Application Testing options SQL> select name,open_mode from v$database; NAME OPEN_MODE --------- -------------------- TESTRAC READ WRITE SQL> select * from v$active_instances; INST_NUMBER INST_NAME ----------- ------------------------------------------------------------ 1 rac1.localdomain:testrac1 2 rac2.localdomain:testrac2 SQL>
Stay tuned for More articles on Oracle RAC
Thank you for giving your valuable time to read the above information.
If you want to be updated with all our articles send us the Invitation or Follow us:
Skant Gupta’s LinkedIn: www.linkedin.com/in/skantali/
Joel Perez’s LinkedIn: Joel Perez’s Profile
Anuradha’s LinkedIn: Anuradha’s Profile
LinkedIn Group: Oracle Cloud DBAAS
Facebook Page: OracleHelp