0% found this document useful (0 votes)
32 views9 pages

Oracle RAC Installation Guide

The document outlines the setup process for a RAC (Real Application Clusters) environment, detailing the configuration of network interfaces, hostname settings, and user permissions across multiple nodes. It includes steps for installing necessary software, configuring ASM (Automatic Storage Management), and creating disk groups and Oracle databases. Additionally, it emphasizes the importance of network connectivity and proper user setup for seamless operation within the cluster environment.

Uploaded by

bolisettyvaas
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
32 views9 pages

Oracle RAC Installation Guide

The document outlines the setup process for a RAC (Real Application Clusters) environment, detailing the configuration of network interfaces, hostname settings, and user permissions across multiple nodes. It includes steps for installing necessary software, configuring ASM (Automatic Storage Management), and creating disk groups and Oracle databases. Additionally, it emphasizes the importance of network connectivity and proper user setup for seamless operation within the cluster environment.

Uploaded by

bolisettyvaas
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd

RAC

rac1 node1/machine1/server1/compute1/instance1 - store softwares


rac2 node2/machine2/server2/compute2/instance2 - store softwares
shareddisk storage/set of disk (Diskgroup) - to store files

rac1-node1 rac2-node2
NIC1 NIC1
NIC2 NIC2
(Network Interface Card)

2 NIC Per Node

NIC1-->for PublicIP/VIP/SCANIP Purpose


NIC2-->For PrivateIP(Node to Node Communication Purpose/Network Heart
Beat / Cache Fusion

Node1
Node2
enp0s3------->PublicIP - [Link] PublicIP -
[Link]
SubnetMask - [Link] SubnetMask -
[Link]

enp0s8------->PrivateIP - [Link] PublicIP - [Link]


SubnetMask - [Link] SubnetMask -
[Link]

On Node1 :

cat /etc/hostname

hostnamectl set-hostname rac1

cat /etc/hostname

su -

hostname

On Node2 :

cat /etc/hostname

hostnamectl set-hostname rac2

cat /etc/hostname

su -

hostname
on All nodes

ifconfig enp0s3
ifconfig enp0s8

On Node1 On Node2
ping [Link] ping [Link]
control+c - to cancel control+c - to cancel

ping [Link] ping [Link]


control+c - to cancel control+c - to cancel

on All nodes - Keep Same entry


vi /etc/hosts
## below lines don't change
[Link] [Link] localhost
::1 localhost6.localdomain6 localhost6

#Public IP
[Link] rac1
[Link] rac2

#PRIVATE IP
[Link] racp1
[Link] racp2

#Virtual IP
[Link] racvip1
[Link] racvip2

#SCAN IP
[Link] scan-01
[Link] scan-01
[Link] scan-01
[Link] scan-01

:wq!

To check the IP is used or not


ping [Link]

PublicIP and PrivateIP Before Installation it should be pingable

VIP and SCANIP Before Inatallation it should NOT be pingable -


Once After GI installation and after [Link] completion VIP and SCANIP will be
pingable.

To Make Node1 as a DNS Server do below step - Only On Node1


***************************************************************
ps -ef |grep dnsmasq
kill -9 <PID>
systemctl start dnsmasq
systemctl is-enabled dnsmasq
systemctl enable dnsmasq
systemctl is-enabled dnsmasq
Add the DNS Server Details on Each Node
***************************************************************
From Node1/Node2 - Initial it will NOT work

nslookup scan-01

In the below file Add DNS Server IP - in our case Node1 server Public IP is the DNS
Server IP - [Link]
On - Node1 - ambasarac1
------------------------
vi /etc/sysconfig/network-scripts/ifcfg-enp0s3
##Go to end of the file Add below line on this file keep other lines as it is
DNS1=[Link]
:wq!
systemctl restart NetworkManager
[root@rac1 ~]# cat /etc/[Link]
# Generated by NetworkManager
nameserver [Link]

[root@rac1 ~]#nslookup scan-01

On All Nodes:
Disable SELINUX and Disable Firewall

vi /etc/sysconfig/selinux
#Remaining lines keep as it is = change the below line
SELINUX=disabled

:wq!

systemctl disable firewalld

Reboot the OS

init 6

------------------------
On All Nodes - as a root user

nmcli - Network Manager CommanLine Interface

nmcli device status


virsh net-destroy default
virsh net-autostart default --disable
virsh net-undefine default
chkconfig libvirtd off
nmcli device status
======================================
groupadd -g 1001 oinstall
groupadd -g 1100 asmadmin
groupadd -g 1200 dba
groupadd -g 1201 oper
groupadd -g 1300 asmdba
groupadd -g 1301 asmoper

useradd -u 2101 -g oinstall -G asmdba,asmadmin,asmoper,dba grid


useradd -u 2100 -g oinstall -G asmdba,dba,oper oracle

passwd grid
g
g
passwd oracle
o
o

Create directories - On All-nodes as root user


********************************************************
mkdir -p /u01/app/grid
mkdir -p /u01/app/19.3.0/grid
mkdir -p /u01/app/oracle/product/19.3.0/dbhome_1
mkdir -p /u01/app/oraInventory

chown -R grid:oinstall /u01/app/grid


chown -R grid:oinstall /u01/app/19.3.0/grid
chown -R grid:oinstall /u01/app/oraInventory
chown -R oracle:oinstall /u01/app/oracle

chmod -R 775 /u01/app/grid


chmod -R 775 /u01/app/19.3.0/grid
chmod -R 775 /u01/app/oracle
chmod -R 775 /u01/app/oraInventory

Create Partition as a root user only from ONE node


-----------------------------------------------------
fdisk /dev/sdb
n
p
1
enter
+2G

n
p
2
enter
+5G

n
p
3
enter
+5G

n
e
4--->partition number auto selected
enter
enter

n
enter
+5G

n
enter
+5G

n
enter
+1G

n
enter
+1G

n
enter
+1G

n
enter
+1G

w ------------->Write/Save and Quit

----------------------------------------
On All Nodes as a root
partprobe /dev/sdb

lsblk -fm /dev/sdb


fdisk -l /dev/sdb
parted -l

On All Nodes Configure ASM Libraries as root user


******************************************************************
Oracle ASM Library Driver/RPM Installation we have to do it as a root user on All
Nodes
cd /softwares/ASMLibRPMs/
rpm -ivh *.rpm

Oracle ASM Library Driver configuration- we have to do it as a root user on All


Nodes
oracleasm configure -i
OS username grid
OS groupname asmadmin
Every boot driver to load/start y
Every boot Label has to be scan y

oracleasm init

Only From ONE Any ONE Node - as a root user - provide the Label
******************************************************************

<-labelname-> <-partitionname->
oracleasm createdisk DISKB1 /dev/sdb1
oracleasm createdisk DISKB2 /dev/sdb2
oracleasm createdisk DISKB3 /dev/sdb3
oracleasm createdisk DISKB5 /dev/sdb5
oracleasm createdisk DISKB6 /dev/sdb6
oracleasm createdisk DISKB7 /dev/sdb7
oracleasm createdisk DISKB8 /dev/sdb8
oracleasm createdisk DISKB9 /dev/sdb9
oracleasm createdisk DISKB10 /dev/sdb10
On All Nodes - as a root user - To re-read the disk-headers
******************************************************************
oracleasm scandisks
ls -l /dev/oracleasm/disks/
oracleasm listdisks
On All Nodes - Disable the NTP Configuration File - as a root user
*************************************************************************
ls -l /etc/[Link]*
mv /etc/[Link] /etc/ntp.conf_OLD
ls -l /etc/[Link]*
As a root user Only From ONE Node
----------------------------------
Provide the Permission for Stage Location(Downloaded location where we placed
software)
chmod -R 777 /softwares/[Link].0
On Windows - From Mobaxterm-Only From ONE Node
*************************************
ssh grid@[Link]
g
cd /softwares/[Link].0/
unzip LINUX.X64_193000_grid_home.zip -d /u01/app/19.3.0/grid

--------------------------------------------
Configure ssh user setup / password less connectivity / user equivalance
-----------------------------------------------------------
as a grid user only from ONE Node
su - grid

cd /u01/app/19.3.0/grid/deinstall
./[Link] -user grid -hosts "rac1 rac2" -advanced -confirm -
noPromptPassphrase

./[Link] -user oracle -hosts "rac1 rac2" -advanced -confirm -


noPromptPassphrase

init 0 Power-off
init 1 SingleUser
init 2 MultiUser
init 3 MultiUser+Network
init 5 MultiUser+Network+GUI
init 6 Reboot

[root@rac1 ~]# runlevel


N 5
[root@rac1 ~]# who -r
run-level 5 2023-05-02 17:20
[root@rac1 ~]#

clusterware/crsinst/cluster software/ GI installation

Grid Infrastructure

grid user - Only From ONE Node


cluvfy - Cluster Verification Utility

cd /u01/app/19.3.0/grid
./[Link] comp nodecon -n rac1,rac2 -verbose

[grid@rac1 grid]$ ./[Link] comp nodecon -n rac1,rac2 -verbose


[grid@rac1 grid]$ ./[Link] stage -pre crsinst -fixup -n rac1,rac2 -verbose -
orainv oinstall

as a root user do the missing RPM installation on All Nodes


----------------------------------------------

1)ksh-20120801-137.0.1.el7.x86_64.rpm
2)libaio-devel-0.3.109-13.el7.x86_64.rpm
3)kmod-oracleasm-2.0.8-21.0.1.el7.x86_64.rpm
4)oracleasmlib-2.0.12-1.el7.x86_64.rpm
5)oracleasm-support-2.1.11-2.el7.x86_64.rpm

Optional(if rac setup with SAN storage)

[root@rac1 ASMLibRPMs]# cat [Link]


iscsiadm -m discovery -t sendtargets -p [Link]
systemctl restart iscsi

cd /softwares/19cRPMs

[root@rac2 19cRPMs]# ls
ksh-20120801-137.0.1.el7.x86_64.rpm libaio-devel-0.3.109-13.el7.x86_64.rpm
[root@rac2 19cRPMs]# rpm -ivh *.rpm
warning: ksh-20120801-137.0.1.el7.x86_64.rpm: Header V3 RSA/SHA256 Signature, key
ID ec551f03: NOKEY
Preparing... ################################# [100%]
Updating / installing...
1:libaio-devel-0.3.109-13.el7 ################################# [ 50%]
2:ksh-20120801-137.0.1.el7 ################################# [100%]
[root@rac2 19cRPMs]# pwd

[grid@rac1 grid]$./[Link]

DB Software Installation
--------------------------------
===================================================================================
================
as a oracle user on All Node - ambasarac1/ambasarac2
-----------------------------------------------------
mkdir -p /u01/app/oracle/product/19.3.0/dbhome_1

as a oracle user on First Node - ambasarac1


-------------------------------------------

cd /softwares/[Link].0/
unzip LINUX.X64_193000_db_home.zip -d /u01/app/oracle/product/19.3.0/dbhome_1
[oracle@rac1 db_home_1]./runInstaller

Set Bash Profile For Grid and Oracle User

On Node1:
---------
vi ~grid/.bash_profile
##at the end of the file add below lines do not modify other lines

export ORACLE_BASE=/u01/app/grid
export ORACLE_HOME=/u01/app/19.3.0/grid
export PATH=$ORACLE_HOME/bin:$PATH
export LD_LIBRARY_PATH=$ORACLE_HOME/lib
export PATH=$ORACLE_HOME/bin:$PATH
export ORACLE_SID=+ASM1
alias sqlplus='rlwrap sqlplus'
alias rman='rlwrap asmcmd'

:wq!

. ~grid/.bash_profile

On Node2:
---------
vi ~grid/.bash_profile
##at the end of the file add below lines do not modify other lines

export ORACLE_BASE=/u01/app/grid
export ORACLE_HOME=/u01/app/19.3.0/grid
export PATH=$ORACLE_HOME/bin:$PATH
export LD_LIBRARY_PATH=$ORACLE_HOME/lib
export PATH=$ORACLE_HOME/bin:$PATH
export ORACLE_SID=+ASM2
alias sqlplus='rlwrap sqlplus'
alias rman='rlwrap asmcmd'

:wq!

. ~grid/.bash_profile

===================================================================================
============================================

===================================================================================
============================================
On Node1:
---------
vi ~oracle/.bash_profile
##at the end of the file add below lines do not modify other lines

export ORACLE_BASE=/u01/app/oracle
export ORACLE_HOME=/u01/app/oracle/product/19.3.0/dbhome_1
export PATH=$ORACLE_HOME/bin:$PATH
export LD_LIBRARY_PATH=$ORACLE_HOME/lib
export PATH=$ORACLE_HOME/bin:$PATH
export ORACLE_SID=racdb1
alias sqlplus='rlwrap sqlplus'
alias rman='rlwrap rman'

:wq!

. ~oracle/.bash_profile

On Node2:
---------
vi ~oracle/.bash_profile
##at the end of the file add below lines do not modify other lines

export ORACLE_BASE=/u01/app/oracle
export ORACLE_HOME=/u01/app/oracle/product/19.3.0/dbhome_1
export PATH=$ORACLE_HOME/bin:$PATH
export LD_LIBRARY_PATH=$ORACLE_HOME/lib
export PATH=$ORACLE_HOME/bin:$PATH
export ORACLE_SID=racdb2
alias sqlplus='rlwrap sqlplus'
alias rman='rlwrap rman'

:wq!

. ~oracle/.bash_profile

===================================================================================
============================================

ASM Diskgroup Creation


---------------------------
Only From ONE Node
as a grid user
. oraenv
+ASM1
sqlplus / as sysasm
sql>asmca

OR

create diskgroup FRA externeal redundancy disk '/dev/oracleasm/disks/DISK3';

Create Oracle Database

-----------------------------
dbca

Common questions

Powered by AI

The 'oracleasm configure -i' command is executed on all nodes to configure the Oracle ASM Library kernel module to start automatically on boot and to identify the user and group responsible for all ASM operations. Ensuring this configuration across all nodes is significant because it safeguards consistent management of ASM disk services, initializes the ASM volumes at boot, and provides the foundation for storage management in the cluster. Any misconfiguration could lead to inconsistencies or failures in accessing shared storage .

The configuration of unique hostnames (e.g., 'hostnamectl set-hostname rac1') for each RAC node is fundamental for distinct node identification within the cluster. This aids in ensuring that each node's resources and tasks are properly managed and monitored, supporting robust cluster operations. By establishing distinct hostnames, the cluster can accurately handle inter-node communication, load balancing, and failover processes, reducing the risk of operational conflicts and enhancing overall system reliability and administrative tractability .

If the SCAN IP is pingable before the Grid Infrastructure installation, it could indicate that the IP is already in use, which may lead to conflicts once the RAC is set up. The SCAN is supposed to start receiving pings only post-installation after the Grid Infrastructure is configured and 'root.sh' script is completed. This ensures that SCAN IPs only begin to resolve and respond to network pings in a RAC-aware manner, providing the intended single point of access for client connections without pre-existing network conflicts .

In Oracle RAC, the SCAN (Single Client Access Name) and Virtual IP (VIP) addresses are pivotal for efficient and fail-safe connectivity. The SCAN provides a single domain name via which clients can connect to any of the available RAC instances, allowing for seamless workload distribution and connection failover. This abstracts the physical IP addressing of individual nodes. VIPs, on the other hand, are used as a failover mechanism; if a node fails, the VIP can be moved to another node in the cluster to maintain network connectivity and client session reliability without disruptions .

The 'oracleasm scandisks' command is necessary across all nodes to ensure each node in the RAC recognizes the newly created ASM disks. This command scans for available diskgroups and ensures the node can see and utilize the new storage resources. It is crucial for maintaining coherence and consistency across the cluster regarding storage availability and ensures all nodes have access to the same diskgroup resources necessary for the Oracle RAC database operations .

Private IP addresses in a RAC (Real Application Cluster) setup are crucial for inter-node communication. These IPs are used for the private communication between the RAC nodes, which includes tasks such as the node-to-node communication for cluster heartbeat and the Cache Fusion process. The Private IPs ensure that the nodes in the cluster can exchange necessary synchronization and data exchange packets efficiently without exposing these communications to the wider network .

Configuring passwordless SSH in a RAC setup is vital for automation and ease of cluster management. It allows for seamless communication and script execution across the nodes, reducing the need for manual login credentials input, which can lead to security and efficiency issues when managing or configuring the database nodes. This setup is crucial for high availability and dynamic reconfigurations as it allows scripts, such as ones for synchronization or updates, to be executed across nodes without manual intervention, thus enhancing automation .

The procedure involves creating necessary directories such as /u01/app/grid and applying appropriate ownership and permissions. For instance, the directories are created using commands like 'mkdir -p /u01/app/grid' and ownership is assigned using 'chown -R grid:oinstall /u01/app/grid'. The permissions are set to 775 to provide the grid user with necessary read, write, and execute rights, while other users have read and execute access. This step is critical to ensure that the Oracle Grid Infrastructure can be correctly installed and accessed for operations without permission issues, thus aligning with security and functionality prerequisites in a RAC setup .

Disabling SELinux and the firewall in a RAC setup is done to ensure that there are no interruptions or blocked communications between the nodes and the required services during the configuration. SELinux, when enabled, can impose security policies that might restrict processes required by the RAC setup, leading to failures in inter-node communication or service setups. Similarly, the firewall can block necessary ports used in the RAC environment, causing nodes to be unable to communicate properly or services to function incorrectly .

DNS configuration is essential in a RAC environment to resolve the hostnames of the RAC nodes and the SCAN addresses. Proper DNS setup ensures that client connections can be dynamically directed to available RAC instances. It provides a mechanism for addressing and querying node availability, thus facilitating efficient load balancing and failover management in the cluster. Without accurate DNS configuration, clients may experience connection failures or unbalanced load distribution among RAC nodes .

You might also like