• Arun Kumar

Oracle 12c Silent Installation on Linux

In this article we will be looking at Oracle 12cR2 silent installation on Oracle Linux 7.7. The steps are same for any version of Oracle Linux. Read Oracle 12cR2 installation on Oracle Linux 7 in case you would like to install Oracle using GUI method. We will be using Oracle Linux 7 and Oracle Database softwares for this activity.

We will also be looking at database creation via DBCA.

Oracle 12c Prerequisites

Use the YUM repository to perform all the pre-install steps. Make sure your VM is able to ping google.com before executing below command

yum install -y oracle-database-server-12cR2-preinstall

Set password for the oracle user

passwd oracle

Create directories which will hold Oracle software installation

mkdir -p /u01/app/oracle/product/
chown -R oracle:oinstall /u01
chmod -R 775 /u01

Setup Oracle user bash_profile

su - oracle
vi .bash_profile

Delete all and paste below. Make sure to change environment variables according to your environment

# .bash_profile

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

# User specific environment and startup programs
export ORACLE_HOME=/u01/app/oracle/product/
export ORACLE_BASE=/u01/app/oracle
export ORACLE_SID=prod

export NLS_LANG=american_america.al32utf8
export NLS_DATE_FORMAT="yyyy-mm-dd:hh24:mi:ss"


export PATH

Export the bash profile

. .bash_profile

Install Oracle 12c Software

Download Oracle 12c and copy the 12c software file to /tmp location and unzip. Start the run installer to perform installation


unzip -qo /tmp/linuxx64_12201_database.zip

cd $ORACLE_HOME/database

./runInstaller -ignoreSysPrereqs -showProgress -silent       \
oracle.install.option=INSTALL_DB_SWONLY                      \
ORACLE_HOSTNAME=${HOSTNAME}                                  \
UNIX_GROUP_NAME=oinstall                                     \
INVENTORY_LOCATION=/u01/app/oraInventory                     \
SELECTED_LANGUAGES=en,en_GB                                  \
ORACLE_HOME=${ORACLE_HOME}                                   \
ORACLE_BASE=${ORACLE_BASE}                                   \
oracle.install.db.InstallEdition=EE                          \
oracle.install.db.OSDBA_GROUP=dba                            \
oracle.install.db.OSOPER_GROUP=dba                           \
oracle.install.db.OSBACKUPDBA_GROUP=dba                      \
oracle.install.db.OSDGDBA_GROUP=dba                          \
oracle.install.db.OSKMDBA_GROUP=dba                          \
oracle.install.db.OSRACDBA_GROUP=dba                         \
DECLINE_SECURITY_UPDATES=true                                \

DBCA Create 12c Database

Fire DBCA to create 12c database

#for GUI database creation 

#for silent database creation
dbca -silent -createDatabase                   \
-templateName General_Purpose.dbc              \
-gdbName ${ORACLE_SID}                         \
-sid ${ORACLE_SID}                             \
-createAsContainerDatabase false               \
-emConfiguration NONE                          \
-datafileDestination /u01/db_files             \
-storageType FS                                \
-characterSet AL32UTF8                         \
-totalMemory 2048                              \
-recoveryAreaDestination /u01/FRA              \
-sampleSchema true

Further Read


Recent Posts

See All

Oracle Optimizer determines the cost of each execution plan based on database, schema, table and other statistics. The changes inside database result in stale statistics. As a DBA, you must gather sta

Imagine an application user gave accidental salary hike of 50% instead of 5% to all employees! To initiate a database point-in-time recovery, we must know the exact time the query was executed against