ORACLE 19C-RAC GRID INSTALLATION
Environment Details:
No. of servers: 2 (node 1 ,node2).
Version : Oracle linux 7.9
Ssh and network configuration complted on both the node.
Follow the steps for configuring Network between two node RAC from below mentioned link:
https://www.linkedin.com/posts/umesh-shinde-989187209_oracle-linux-installation-activity-
7141727733537046528-OGsK?utm_source=share&utm_medium=member_desktop
--------------------------------------------------------------
1. Prerequisites:
Connect to OEL 7.9 server via putty and install the below packages
yum -y install oracleasm*
yum -y install kmod-oracleasm*
Add below OS groups
echo "password" | passwd --stdin grid
echo "password" | passwd --stdin oracle
groupadd -g 54327 asmdba
groupadd -g 54328 asmoper
groupadd -g 54329 asmadmin
usermod -u grid -g oinstall -G dba,asmdba,asmoper,asmadmin,racdba grid
usermod -u oracle -g oinstall -G dba,asmdba,asmoper,asmadmin,racdba grid
2. Configure Oracle ASM
oracleasm configure -i
Load / initiate Oracle ASM
oracleasm init
3. Create new virtual disk for ASM.
Click on virtual manager > create> select VHD> preallocate full size> give 20 gb size for asm data
>finish.
Then click on disk and select property.
Make type =shared
Again, create one more disk for OCR data.
And follow same thing.
Run below commands to create partitions on newly added disk:
fdisk -l | grep /dev/sd
printf "o\nn\np\n1\n\n\nw\n" | sudo fdisk /dev/sdb
printf "o\nn\np\n1\n\n\nw\n" | sudo fdisk /dev/sdc
4. Create separate ASM Disk for each
partition
oracleasm createdisk ASMDATA1 /dev/sdb1
oracleasm createdisk ASMOCR /dev/sdc1
oracleasm scandisks
oracleasm listdisks
To check asm disks
ls -lrt /dev/oracleasm/disks
configuaring swap using /swap mount point.
umount /swap
vi /etc/fstab
Edit swap filesystem.
/dev/mapper/ol-swap /swap swap defaults 12
Now run below commands.
mkswap -L swap /dev/mapper/ol-swap
swapon -a
swapon -s
5. Install Grid Software
Edit Grid user Bash_Profile but take .bash_profile backup before editing
it
su – grid
vi .bash_profile
Node 1:
# .bash_profile
# Get the aliases and functions
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi
# User specific environment and startup programs
ORACLE_SID=+ASM1; export ORACLE_SID
ORACLE_BASE=/grid/app/grid1; export ORACLE_BASE
ORACLE_HOME=/grid/app/grid/product/19.0.0/grid_home; export ORACLE_HOME
ORACLE_TERM=xterm; export ORACLE_TERM
JAVA_HOME=/usr/bin/java; export JAVA_HOME
TNS_ADMIN=$ORACLE_HOME/network/admin; export TNS_ADMIN
PATH=.:${JAVA_HOME}/bin:${PATH}:$HOME/bin:$ORACLE_HOME/bin
PATH=${PATH}:/usr/bin:/bin:/usr/local/bin
export PATH
umask 022
PATH=$PATH:$HOME/.local/bin:$HOME/bin
export PATH
Node2:
# .bash_profile
# Get the aliases and functions
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi
# User specific environment and startup programs
ORACLE_SID=+ASM2; export ORACLE_SID
ORACLE_BASE=/grid/app/grid1; export ORACLE_BASE
ORACLE_HOME=/grid/app/grid/product/19.0.0/grid_home; export ORACLE_HOME
ORACLE_TERM=xterm; export ORACLE_TERM
JAVA_HOME=/usr/bin/java; export JAVA_HOME
TNS_ADMIN=$ORACLE_HOME/network/admin; export TNS_ADMIN
PATH=.:${JAVA_HOME}/bin:${PATH}:$HOME/bin:$ORACLE_HOME/bin
PATH=${PATH}:/usr/bin:/bin:/usr/local/bin
export PATH
umask 022
PATH=$PATH:$HOME/.local/bin:$HOME/bin
export PATH
Create the Directories for Oracle Grid installation
mkdir -p /grid/app/grid
mkdir -p /grid/app/grid/product/19.0.0/grid_home
chown -R grid:asmadmin /grid/app/grid
mkdir -p /grid/app/grid1
chown -R grid:asmadmin /grid/app/grid1
mkdir -p /grid/app/oraInventory
Copy the grid software under grid home and unzip it
Unzip grid zip file using grid user
Run below command for CVU utility on below location/
/grid/app/grid/product/19.0.0/grid_home/cv/rpm
Using root user
rpm -Uvh cvuqdisk*
scp ./cvuqdisk* root@node2:/tmp
on node 2 run below command from /tmp location
rpm -Uvh cvuqdisk*
6. Pre-check for RAC Setup
Pre-check for CRS installation using Cluvfy
./runcluvfy.sh stage -pre crsinst -n node1,node2 -verbose
./sshUserSetup.sh -user oracle -hosts "node1 node2" -noPromptPassphrase -confirm -advanced
./runcluvfy.sh stage -pre crsinst -n node1,node2 -verbose -fixup
Start the gridSetup.sh which will install grid software.
Set display on your environment.
By root user:
Export display=:0.0
Xhost +
Then by grid user
Export display=:0.0
Xhost +
Cd $ORACLE_HOME
7. Start Installation
./gridSetup.sh
Select the Configure Oracle Grid Infrastructure for a New Cluster option, then
click the Next button
Accept the Configure an Oracle Standalone Cluster option by clicking
the Next button.
Enter the cluster name my-cluster, SCAN name db-scan and SCAN port 1521,
then click the Next button.
On the “Cluster Node Information” screen, click the Add button.
Enter the details of the second node in the cluster, then click the OK button.
Click the SSH connectivity button and enter the password for the oracle
user. Click the Setup button to configure SSH connectivity, and the Test
button to test it once it is complete. Once the test is complete, click the
Next button.
Check the public and private networks are specified correctly as ASM &
Private. Click the Next button.
Accept the Use Oracle Flex ASM for Storage option by clicking the Next
button.
Select the No option, as we don’t want to create a separate disk group for
the GIMR in this case. Click the Next button.
First Browse the path /dev/oracleasm/disks* using change discovery path
/dev/oracleasm/disks*
Enter the credentials and click the Next button.
Accept the default IPMI option by clicking the Next button.
Deselect EM. Click the Next button
Set the groups to oinstall and click the Next button. Accept the warnings
on the subsequent dialog by clicking the Yes button.
1. Asmadmin
2. Asmdba
3. asmdba
Click the Next button
Select base location to grid1 not grid.
Accept the default inventory directory by click the Next button
Click the Next button.
Check the Ignore All checkbox and click the Next button.
Double check and click the Install button
When prompted, run the configuration scripts on each node one by one
Root script ouput:
8. Configure ASM Diskgroups
The grid installer allows you to only create one diskgroup (CRS). We
need to start the asmca utility in order to create DATA and FRA
diskgroup which are required for database installation. Click on Create
================ END ===================