Tuesday, August 1, 2023

GRID , RAC , STANDALONE GRID OR ORACLE DATABASE SINGLE INSTANCE INSTALLATION

 Set SELinux to Permissive Mode permanently

To Change Hostname In Oracle Linux:-

* # nmcli general hostname <new_name.domain.com>

* # service systemd-hostnamed restart

1. Edit /etc/selinux/config

Change the SELINUX value to "SELINUX=permissive"

1.1 Edit 

The /etc/sysconfig/network file specifies additional information that is valid to all network interfaces on the system. The following entries from /etc/sysconfig/network define that IPv4 networking is enabled, IPv6 networking is not enabled, the host name of the system, and the IP address of the default network gateway:

NETWORKING=yes
NETWORKING_IPV6=no
HOSTNAME=host20.mydomain.com
GATEWAY=192.168.1.1

2. Reboot the server

network adapter 1:- host only network 

network adapter 2:- internal network 

network adapter 3:- bridged adapter 

3. Some important files in linux:-

/etc/nsswitch.conf

/etc/resolv.conf

/etc/sysconfig/network 

/etc/hosts









****************************************************************

** cat /etc/hosts 

[root@pune ~]# cat /etc/hosts
127.0.0.1   localhost localhost.shaikh.com localhost4 localhost4.shaikh.com4
::1         localhost localhost.shaikh.com localhost6 localhost6.shaikh.com6
# Private Net
192.168.10.1 pune-priv.shaikh.com   pune-priv
192.168.10.2 sakri-priv.shaikh.com  sakri-priv
# Public Net
192.168.56.71 pune.shaikh.com   pune
192.168.56.72 sakri.shaikh.com  sakri
# Virtual Net
192.168.56.81 pune-vip.shaikh.com   pune-vip
192.168.56.82 sakri-vip.shaikh.com  sakri-vip
# SCAN
192.168.56.91 city-scan.shaikh.com       city-scan
192.168.56.92 city-scan.shaikh.com      city-scan
192.168.56.93 city-scan.shaikh.com      city-scan
******************************************************************

do sshUserSetup.sh on first node on login as grid, oracle, root user 
$ su - grid
$ cd $ORACLE_HOME
$ find . -name "sshUserSetup.sh"
$ ./sshUserSetup.sh -user grid -hosts "pune sakri" -noPromptPassphrase -confirm - advanced 
$su - oracle 
$cd $ORACLE_HOME
$ find . -name "sshUserSetup.sh"
$ ./sshUserSetup.sh -user oracle-hosts "pune sakri" -noPromptPassphrase -confirm - advanced  

***********************************************************************
.bash_profile >> ORACLE user 
-----------------------------------------------
# .bash_profile

# Get the aliases and functions
if [ -f ~/.bashrc ]; then
        . ~/.bashrc
fi


export TMP=/tmp
export TMPDIR=$TMP
export ORACLE_BASE=/u02/app/oracle
export ORACLE_HOME=$ORACLE_BASE/product/19c/dbhome_1
export ORACLE_SID=pune
export ORACLE_TERM=xterm
export BASE_PATH=/usr/sbin:$PATH
export PATH=$ORACLE_HOME/bin:$BASE_PATH
export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib
export CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib
===================================================

.bash_profile >> grid user
------------------------------------------------------
# .bash_profile

# Get the aliases and functions
if [ -f ~/.bashrc ]; then
        . ~/.bashrc
fi

export TMP=/tmp
export TMPDIR=$TMP
export ORACLE_BASE=/u01/app/grid
export ORACLE_HOME=/u01/app/19c/gridhome_1
export ORACLE_SID=+ASM1
export ORACLE_TERM=xterm
export BASE_PATH=/usr/sbin:$PATH
export PATH=$ORACLE_HOME/bin:$BASE_PATH
export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib
export CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib
=====================================================
************************************************************************
mkdir -p /u01/app/grid
mkdir -p /u01/app/19c/gridhome_1
mkdir -p /u02/app/oracle
mkdir -p /u02/app/oracle/product/19c/dbhome_1
mkdir -p /u01/app/oraInventory
chown -R grid:oinstall /u01
chown -R oracle:oinstall /u02
chown -R grid:oinstall /u01/app/oraInventory
chmod -R 775 /u01
chmod -R 775 /u02

mkdir -p /u02/app/oracle
mkdir -p /u02/app/oracle/product/19c/dbhome_1
mkdir -p /u02/app/oraInventory
chown -R oracle:oinstall /u02
chmod -R 775 /u02
*************************************************************************
groupadd -g 5001 oinstall
groupadd -g 5002 dba
groupadd -g 5003 oper
groupadd -g 5004 asmadmin
groupadd -g 5005 asmdba
groupadd -g 5006 asmoper

useradd -u 5007 -g oinstall -G dba,oper,asmdba oracle
useradd -u 5008 -g oinstall -G asmadmin,asmdba,asmoper,dba grid

usermod -g oinstall -G dba,oper,asmdba oracle
usermod -g oinstall -G asmadmin,asmdba,asmoper,dba grid


passwd oracle
passwd grid

-----------------------------------------------------------
vim /etc/security/limits.conf

oracle   soft    nofile  1024
oracle   hard    nofile  65536
oracle   soft    nproc   16384
oracle   hard    nproc   16384
oracle   soft    stack   10240
oracle   hard    stack   32768
oracle   soft    memlock  134217728
oracle   hard    memlock  134217728


grid     soft    nofile  1024
grid     hard    nofile  65536
grid     soft    nproc   16384
grid     hard    nproc    16384
grid     soft    stack    10240
grid     hard    stack    32768
grid     soft    memlock  134217728
grid     hard    memlock  134217728


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

disable firewalld.service

#systemctl stop firewalld.service
#systemctl disable firewalld.service
===============================================================
NETWORK TIMING
# systemctl enable chronyd.service
# systemctl restart chronyd.service
==============================================================

su - root
# cd /tmp
# wget https://download.oracle.com/otn_software/asmlib/oracleasmlib-2.0.17-1.el8.x86_64.rpm
# wget https://public-yum.oracle.com/repo/OracleLinux/OL8/addons/x86_64/getPackage/oracleasm-support-2.1.12-1.el8.x86_64.rpm
# yum localinstall ./oracleasm-support-2.1.12-1.el8.x86_64.rpm ./oracleasmlib-2.0.17

to install oracle 19c preinstall rpm on oracle linux 9:-
curl -o oracle-database-preinstall-19c-1.0-2.el8.x86_64.rpm https://yum.oracle.com/repo/OracleLinux/OL8/appstream/x86_64/getPackage/oracle-database-preinstall-19c-1.0-2.el8.x86_64.rpm

other way around:- 
dnf localinstall package_name  ;  ---> if you have download on server
dnf install package_name 
dnf install bind 
dnf update oracleasm  or dnf install oracleasm 

*****************************************************************************





orainstRoot.sh :-
this will configure the Oracle Inventory Directory (keeps track of all oracle software installation on the server)
root.sh :-
runs on all nodes after each node in the RAC cluster. 
task performed :- 
1. crsd, ocssd, evm, ocr, olr and crs on each node.

No comments:

Post a Comment

Enable OpenSSH on Windows 11

Step 1: Install OpenSSH Server You can do this via PowerShell (run as Administrator ): Check if it's already available: Get-WindowsCapab...