|
Configuring HA-Oracle on Cluster 2.1.First Configure NFS as described in Cluster Installation Procedure for Cluster 2.1 HANFS
1.) Add semephores to /etc/system for oracle SGA to run.
2.) Take both nodes out of the cluster.
3.) Reboot.
4.) Start the cluster on both nodes.
5.) If still running HA-NFS, stop nfs monitoring.
# hareg -n nfs
6.) Unregister nfs.
# hareg -u nfs
7.) Remove any exsisting logical hosts.
# scconf clustername -L logicalhost -r
8.) Edit /etc/hosts on all nodes including the AWS with an entry for logicalhost
hadbms
9.) Create a disk group called hadbms with a 1GB mirrored volume called hadbms.1
and then deport the diskgroup
10.) Create the new logical host hadbms from one node only
e.g # scconf (clustername) -L hadbms -n(nodelist) -g hadbms -i le0,le0,hadbms
e.g # scconf (clustername) -F hadbms (on both nodes)
11.) mkdir on both nodes /hadbms1
12.) Setup vfstab.hadbms for /hadbms1 on both nodes.
13.) Reconfigure the cluster so it mounts /dev/vx/dsk/hadbms/hadbms.1 /hadbms1
14.) On both nodes create the dba group as 65535.
15.) On both nodes create the oracle user as uid 60003, group dba, home directory
/hadbms1/Oracle, using a csh, with password demo.
PLEASE NOTE THAT THE SHELL MUST BE CSH AS THE SHELL ENVIROMENT WHICH IS
PRE SET WITHIN THE ORACLE INSTALL USES CSH!!!!
16.) Set the ownership of the hadbms.1 volume.
# vxedit -g hadbms set user=oracle group=dba mode=660 hadbms.1
17.) On the node hosting the hadbms diskgroup login as root
18.) cd to /hadbms1
19.) Install Oracle. Setup Databases, oratab, tnsnames etc..
20.) Ensure that all files and directories under /hadbms1 have owner as oracle
and group as dba
21.) Login as oracle user
#su - oracle
22.) Test to see if oracle works, start Oracle by
% svrmgrl
SVRMGR> connect internal
SVRMGR> startup
SVRMGR>
Oracle Server Manager Release 3.0.4.0.0 - Production
(c) Copyright 1997, Oracle Corporation. All Rights Reserved.
Oracle8 Enterprise Edition Release 8.0.4.0.0 - Production
With the Partitioning and Objects options
PL/SQL Release 8.0.4.0.0 - Production
SVRMGR> Connected.
SVRMGR> ORACLE instance started.
Total System Global Area 4569280 bytes
Fixed Size 47296 bytes
Variable Size 4235264 bytes
Database Buffers 204800 bytes
Redo Buffers 81920 bytes
Database mounted.
Database opened.
SVRMGR>
Server Manager complete.
**********************************************************************************
NOTE if the database starts up, shut it down as we will want HA to do the work
**********************************************************************************
SVRMGR> shutdown
Database closed.
Database dismounted.
ORACLE instance shut down.
SVRMGR> exit
22.) logout of oracle user
23.) on the node mastering the logicalhost check oratab.
24.) On the node mastering the logicalhost check tnsnames and listener.
25.) Copy across the net the same files to the other node to the same location
e.g tnsnames.ora and listner.ora
26.) license HA-DBMS using /etc/opt/licenses/lit
27.) Register oracle to the logical host
#hareg -s -r oracle -h hadbms
28.) Start the oracle data service
hareg -y oracle
29.) Register the oracle instance to the logical host
# haoracle insert demo hadbms 60 10 120 600 oracle/demo \
/hadbms1/admin/demo/pfile/initdemo.ora
you will get a message
Listener name not specified, using default listener name
NOTE do not specify a listener when using haoracle insert as
it will use the default listener in /var/opt/oracle
30.) Start the Oracle instance
# haoracle start [ instance name ]
start fault monitor for "instance" on localhost...
start fault monitor for "instance" on phys-ukc1 ...
# Jul 31 14:15:22 phys-ukc2 ID[SUNWcluster.ha.oracle.fault_mon.2000]:
hadbms:demo: starting up SQL*Net V2 listener
29022: haoracle_fmon_7.3 demo 60 10 120 600 /etc//opt/SUNWscor/haoracle_config_V1
/hadbms1/admin/demo/log/bdmp/alert_demo.log
Jul 31 14:15:25 phys-ukc2 ID[SUNWcluster.ha.oracle.fault_mon.2000]:
hadbms:demo: starting up SQL*Net V2 listener
LSNRCTL for Solaris: Version 8.0.4.0.0 - Production on 31-JUL-98 14:15:25
(c) Copyright 1997 Oracle Corporation. All rights reserved.
TNS-01106: Listener using listener name LISTENER has already been started
Jul 31 14:15:25 phys-ukc2 ID[SUNWcluster.ha.oracle.fault_mon.2020]: hadbms:demo:
Starting up instance demo PFILE=/hadbms1/admin/demo/pfile/initdemo.ora
Oracle Server Manager Release 3.0.4.0.0 - Production
(c) Copyright 1997, Oracle Corporation. All Rights Reserved.
Oracle8 Enterprise Edition Release 8.0.4.0.0 - Production
With the Partitioning and Objects options
PL/SQL Release 8.0.4.0.0 - Production
SVRMGR> Connected.
SVRMGR> ORACLE instance started.
Total System Global Area 4569280 bytes
Fixed Size 47296 bytes
Variable Size 4235264 bytes
Database Buffers 204800 bytes
Redo Buffers 81920 bytes
Database mounted.
Database opened.
SVRMGR>
Server Manager complete.
31.) Oracle should now be running.
To test open an rlogin from ccp. Do su - oracle and login to oracle using
svrmgrl and shutdown the database while it is being monitored by HA
% svrmgrl
SVRMGR> connect internal
SVRMGR> shutdown immediate
The database will shutdown and HA will discover that the db is not running
and start it up again.
If you need to stop Oracle:
32.) Stop the instance monitoring
#haoracle stop "instance"
33.) Shutdown Oracle.
% svrmgrl
SVRMGR> connect internal
SVRMGR> shutdown immediate
SVRMGR> quit
***** NOTES *****
|
© R. Davies. 1999, Grenville Consulting Ltd.