Oracle Database 12c Release 2 (12.2) Installation On Oracle Linux 7.6 (OL7.6)
Unpack Files
12.2.0.1
unzip linuxx64_12201_database.zip |
Host File
login as a root then, edit the host file “/etc/hosts”.
192.168.75.130 labdbT2.localdomain labdbT2 |
Oracle Installation Prerequisites
Perform either the Automatic Setup or the Manual Setup to complete the basic prerequisites. so I prefer Automatic Setup.
Automatic Setup
We can follow the instructions at http://public-yum.oracle.com to set up the yum repository for OL, then perform the following command.
# yum install oracle-rdbms-server-12cR2-preinstall -y |
All necessary prerequisites will be performed automatically.
It is probably worth doing a full update as well, but this is not strictly speaking necessary.
# yum update |
Create new groups and users.
I have group oinstall, dba and oper and oracle user before then, I used groupmod and usermod commands, if you don’t have them before You have to use groupadd and useradd command
groupmod -g 201 oinstall groupmod -g 202 dba groupmod -g 203 oper groupadd -g 204 asmadmin groupadd -g 206 asmdba groupadd -g 205 asmoperusermod -u 202 -g oinstall -G dba,asmdba,oper oracle passwd oracle |
Create the directories in which the Oracle software will be installed.
mkdir -p /oracle/product/12.2.0/db chown -R oracle:oinstall /oracle chmod -R 775 /oracle |
Login as root and issue the following command.
xhost +192.168.75.130 |
Log in as the oracle user and add the following lines at the end of the “.bash_profile” file.
# Oracle Settings TMP=/tmp; export TMP TMPDIR=$TMP; export TMPDIRORACLE_HOSTNAME=dblabT2.localdomain; export ORACLE_HOSTNAME ORACLE_UNQNAME=DB12C; export ORACLE_UNQNAME ORACLE_BASE=/oracle; export ORACLE_BASE ORACLE_HOME=$ORACLE_BASE/product/12.2.0/db; export ORACLE_HOME ORACLE_SID=DB12C; export ORACLE_SIDPATH=/usr/sbin:$PATH; export PATH PATH=$ORACLE_HOME/bin:$PATH; export PATHLD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib; export LD_LIBRARY_PATH CLASSPATH=$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib; export CLASSPATH |
Create the directories oraInventory
# mkdir -p /oracle/oraInventory # chown -R oracle:oinstall /oracle/oraInventory # chmod -R 775 /oracle/oraInventory |
Installation
Log into the oracle user. If you are using X emulation then set the DISPLAY environmental variable.
export DISPLAY=192.168.75.130:0.0 |
Start the Oracle Universal Installer by following the command in the database directory.
./runInstaller |