mkdir
mkdir -p /dbdbname/admin/
mkdir -p /dbdbname/admin/
mkdir -p /dbdbname/admin/
mkdir -p /dbdbname/admin/
mkdir
mkdir -p /dbdbname/admin/
mkdir -p /dbdbname/admin/
mkdir -p /dbdbname/admin/
mkdir -p /dbdbname/admin/
-On First Node:
--Install Oracle Clusterware (If you don't have it already installed)
--Create the listener on both nodes
--Backup the database and restore it on a shared location like ASM
--Add the following parameters to your pfile
*.cluster_database = TRUE
*.cluster_database_instances = 2
*.undo_management=AUTO
--Copy the $ORACLE_HOME/dbs/init
--After create the listener on both nodes, add them at tnsnames.ora file
LISTENER_BPLS_hostname01 =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = hostname01-vip.b2winc.com)(PORT = 1539))
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.201.31)(PORT = 1539))
)
LISTENER_BPLS_hostname02 =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = hostname01-vip.b2winc.com)(PORT = 1539))
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.201.31)(PORT = 1539))
)
--Use an pfile to startup nomount and them create the spfile
SQL>startup nomount pfile='temp_pfile
SQL>create SPFILE='+DG_dbname_FRA/
SQL>shutdown immediate
SQL>startup mount
--Create UNDO tablespaces for both nodes
SQL>create undo tablespace UNDOTBS1 datafile '+DG_dbname_FRA' size 500M;
SQL>create undo tablespace UNDOTBS2 datafile '+DG_dbname_FRA' size 500M;
--Create redo groups for thread 2
SQL>alter database add logfile thread 2 group 4 size 50M;
SQL>alter database add logfile thread 2 group 5 size 50M;
SQL>alter database add logfile thread 2 group 6 size 50M;
--Open the database and enable thread 2
SQL>alter database open;
SQL>alter database enable public thread 2;
--On second node, copy the init file, change the name to dbnameSID2.ora and start the database
export ORACLE_SID=dbname
sqlplus / as sysdba
SQL>startup
--Finally create services
srvctl add database -d
srvctl add instance -d
srvctl add instance -d
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = hostname01-vip.b2winc.com)(PORT = 1539))
(ADDRESS = (PROTOCOL = TCP)(HOST = hostname02-vip.b2winc.com)(PORT = 1539))
(LOAD_BALANCE = yes)
)
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME =
(FAILOVER_MODE =
(TYPE = SELECT)
(METHOD = BASIC)
(RETRIES = 180)
(DELAY = 5)
)
)
)
Best Regards,
Paulo Portugal
No comments:
Post a Comment