Monday, 21 November 2016

Oracle 12c silent installation using response file.

Let us assume,You have extracted the RDBMS software zip file, created Oracle user and groups. 

-- Before proceeding with the installation, We need to make few changes in the server ( Pre Checks ).

  1.  Change the kernel parameter in the /etc/sysctl.conf file.

fs.file-max = 6815744
kernel.sem = 250 32000 100 128
kernel.shmmni = 4096
kernel.shmall = 1073741824
kernel.shmmax = 4398046511104
net.core.rmem_default = 262144
net.core.rmem_max = 4194304
net.core.wmem_default = 262144
net.core.wmem_max = 1048576
fs.aio-max-nr = 1048576
net.ipv4.ip_local_port_range = 9000 65500
 -- Even we can proceed with the installation without updating the kernel parameters. But in future we may face a performance issue.

-- kernel.shmax and kernel.shmall values already will be there when you installed the OS. However the above values are the recommendation from Oracle.

To make the changes effective, fire the sysctl -p command.

  2. Add the following lines in the /etc/security/limits.conf file.


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


3. Install the below packages if not already installed.

yum install binutils -y
yum install compat-libcap1 -y
yum install compat-libstdc++-33 -y
yum install compat-libstdc++-33.i686 -y
yum install gcc -y
yum install gcc-c++ -y
yum install glibc -y
yum install glibc.i686 -y
yum install glibc-devel -y
yum install glibc-devel.i686 -y
yum install ksh -y
yum install libgcc -y
yum install libgcc.i686 -y
yum install libstdc++ -y
yum install libstdc++.i686 -y
yum install libstdc++-devel -y
yum install libstdc++-devel.i686 -y
yum install libaio -y
yum install libaio.i686 -y
yum install libaio-devel -y
yum install libaio-devel.i686 -y
yum install libXext -y
yum install libXext.i686 -y
yum install libXtst -y
yum install libXtst.i686 -y
yum install libX11 -y
yum install libX11.i686 -y
yum install libXau -y
yum install libXau.i686 -y
yum install libxcb -y
yum install libxcb.i686 -y
yum install libXi -y
yum install libXi.i686 -y
yum install make -y
yum install sysstat -y
yum install unixODBC -y
yum install unixODBC-devel -y

 4. Append the below lines in the .bashrc file, which will present in the home directory of the oracle user.


# Oracle Settings
export TMP=/tmp
export TMPDIR=$TMP

export ORACLE_HOSTNAME=localhost.localdomain
export ORACLE_UNQNAME=orcl
export ORACLE_BASE=/u01/app/oracle
export ORACLE_HOME=$ORACLE_BASE/product/12.1.0/db_1
export ORACLE_SID=orcl

export PATH=/usr/sbin:$PATH
export PATH=$ORACLE_HOME/bin:$PATH

export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib
export CLASSPATH=$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib

 5. Create the necessary directories for Oracle home and Inventory location.

$mkdir -p /u01/app/oracle/product/12.1.0/db_1
$mkdir -p /u01/app/oracle/oraInventory 



 6. Preparing response file. Below are the important parameters for installing the Oracle RDBMS software.

oracle.install.responseFileVersion=/oracle/install/rspfmt_dbinstall_response_schema_v12.1.0
oracle.install.option=INSTALL_DB_SWONLY
ORACLE_HOSTNAME=localhost.localdomain
UNIX_GROUP_NAME=oinstall
INVENTORY_LOCATION=/u01/app/oracle/oraInventory
SELECTED_LANGUAGES=en
ORACLE_BASE=/u01/app/oracle/
ORACLE_HOME=/u01/app/oracle/product/12.1.0/db_1
oracle.install.db.InstallEdition=EE
oracle.install.db.DBA_GROUP=dba
oracle.install.db.OPER_GROUP=dba
oracle.install.db.BACKUPDBA_GROUP=dba
oracle.install.db.DGDBA_GROUP=dba
oracle.install.db.KMDBA_GROUP=dba
SECURITY_UPDATES_VIA_MYORACLESUPPORT=false
DECLINE_SECURITY_UPDATES=true
oracle.installer.autoupdates.option=SKIP_UPDATES



- Installation.

Go the directory where you have extracted the software and run it as Oracle user.

$./runInstaller -showProgress -silent -responseFile <Responsefile location>db_install.rsp

- showProgress with the help of this parameter we can get to know which status are we in and how much percent it got completed.

Once the installation is done, we need to run 2 script as a root user.


/u01/app/oracle/oraInventory/orainstRoot.sh 
/u01/app/oracle/product/12.1.0/db_1/root.sh
 
 
Now you can create your database.
 
Cheers..!!
 
Happy Learning..!!




 
















































 

No comments:

Post a Comment