Oracle 11g installation on Oracle Enterprise Linux

Posted: December 1, 2015 in System Administration
Tags: , , , , , , ,

Oracle 11g installation on Oracle Enterprise Linux 5

  • Add Required User and Groups

>>Switch as root<<

groupadd oinstall

groupadd  dba

groupadd oper

useradd –g oinstall –G dba,oper –d /home/oracle oracle

passwd oracle

  • Set host name

vim /etc/hosts

insert below line

192.168.1.202 dbserver5.com dbserver5

  • Set kernel parameters

vim /etc/sysctl.conf

insert the following lines in the above file(sysctl.conf)

# For 11g, Oracle-Validated setting for fs.file-max is 6815744

# For 10g, uncomment ‘fs.file-max = 327679’, and comment ‘fs.file-max = 6553600’ entry and re-run sysctl -p

# fs.file-max = 327679

fs.file-max = 6815744

# Oracle-Validated setting for kernel.msgmni is 2878

kernel.msgmni = 2878

# Oracle-Validated setting for kernel.msgmax is 8192

kernel.msgmax = 8192

# Oracle-Validated setting for kernel.msgmnb is 65536

kernel.msgmnb = 65536

# Oracle-Validated setting for kernel.sem is ‘250 32000 100 142’

kernel.sem = 250 32000 100 142

# Oracle-Validated setting for kernel.shmmni is 4096

kernel.shmmni = 4096

# Oracle-Validated setting for kernel.shmall is 1073741824

kernel.shmall = 1073741824

# Oracle-Validated setting for kernel.shmmax is 4398046511104 on x86_64 and 4294967295 on i386 architecture. Refer Note id 567506.1

kernel.shmmax = 4398046511104

# Oracle-Validated setting for kernel.sysrq is 1

kernel.sysrq = 1

# Oracle-Validated setting for net.core.rmem_default is 262144

net.core.rmem_default = 262144

# For 11g, Oracle-Validated setting for net.core.rmem_max is 4194304

# For 10g, uncomment ‘net.core.rmem_max = 2097152’, comment ‘net.core.rmem_max = 4194304’ entry and re-run sysctl -p

# net.core.rmem_max = 2097152

net.core.rmem_max = 4194304

# Oracle-Validated setting for net.core.wmem_default is 262144

net.core.wmem_default = 262144

# For 11g, Oracle-Validated setting for net.core.wmem_max is 1048576

# For 10g, uncomment ‘net.core.wmem_max = 262144’, comment ‘net.core.wmem_max = 1048576’ entry for this parameter and re-run sysctl -p

# net.core.wmem_max = 262144

net.core.wmem_max = 1048576

# Oracle-Validated setting for fs.aio-max-nr is 3145728

fs.aio-max-nr = 3145728

# For 11g, Oracle-Validated setting for net.ipv4.ip_local_port_range is 9000 65500

# For 10g, uncomment ‘net.ipv4.ip_local_port_range = 1024 65000’, comment ‘net.ipv4.ip_local_port_range = 9000 65500’ entry and re-run sysctl -p

# net.ipv4.ip_local_port_range = 1024 65000

net.ipv4.ip_local_port_range = 9000 65500

# Oracle-Validated setting for vm.min_free_kbytes is 51200 to avoid OOM killer

vm.min_free_kbytes = 51200

  • Set Processor Limits

vim /etc/security/limits.conf

# Oracle-Validated setting for nofile soft limit is 131072

oracle   soft   nofile    131072

# Oracle-Validated setting for nofile hard limit is 131072

oracle   hard   nofile    131072

# Oracle-Validated setting for nproc soft limit is 131072

oracle   soft   nproc    131072

# Oracle-Validated setting for nproc hard limit is 131072

oracle   hard   nproc    131072

# Oracle-Validated setting for core soft limit is unlimited

oracle   soft   core    unlimited

# Oracle-Validated setting for core hard limit is unlimited

oracle   hard   core    unlimited

# Oracle-Validated setting for memlock soft limit is 50000000

oracle   soft   memlock    50000000

# Oracle-Validated setting for memlock hard limit is 50000000

oracle   hard   memlock    50000000

  • Make /u01/app/oracle/ directory and set ownership

mkdir –p /u01/app/oracle

chown –R oracle:oinstall /u01/app/oracle/product/11.2.0/db_1/

chmod –R 775 /u01/app/oracle/product/11.2.0/db_1/

  • Set bash profile

Insert the following lines

# Oracle Settings

TMP=/tmp; export TMP

TMPDIR=$TMP; export TMPDIR

ORACLE_HOSTNAME=ol5-112.localdomain; export ORACLE_HOSTNAME

ORACLE_UNQNAME=DB11G; export ORACLE_UNQNAME

ORACLE_BASE=/u01/app/oracle; export ORACLE_BASE

ORACLE_HOME=$ORACLE_BASE/product/11.2.0/db_1; export ORACLE_HOME

ORACLE_SID=DB11G; export ORACLE_SID

PATH=/usr/sbin:$PATH; export PATH

PATH=$ORACLE_HOME/bin:$PATH; export PATH

LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib; export LD_LIBRARY_PATH

CLASSPATH=$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib; export CLASSPATH

  • Set the display variable

xhost +

echo $DISPLAY

note the result of the above command

switch as oracle

su – oracle

DISPLAY=<result>:0.0; export DISPLAY

http://www.thegeekstuff.com/2010/06/xhost-cannot-open-display/

  • Install the following packages if they are not already present.

# From Oracle Linux 5 DVD

#Mount the OEL ISO image into the virtual vachine.

cd /media/cdrom/Server

rpm -Uvh binutils-2.*

rpm -Uvh compat-libstdc++-33*

rpm -Uvh compat-libstdc++-33*.i386.rpm

rpm -Uvh elfutils-libelf*

rpm -Uvh gcc-4.*

rpm -Uvh gcc-c++-4.*

rpm -Uvh glibc-2.*

rpm -Uvh glibc-common-2.*

rpm -Uvh glibc-devel-2.*

rpm -Uvh glibc-headers-2.*

rpm -Uvh ksh*

rpm -Uvh libaio-0.*

rpm -Uvh libaio-devel-0.*

rpm -Uvh libgomp-4.*

rpm -Uvh libgcc-4.*

rpm -Uvh libstdc++-4.*

rpm -Uvh libstdc++-devel-4.*

rpm -Uvh make-3.*

rpm -Uvh sysstat-7.*

rpm -Uvh unixODBC-2.*

rpm -Uvh unixODBC-devel-2.*

rpm -Uvh numactl-devel-*

cd /

  • Create database using dbca
  • Create lisner.ora and tnsnames.ora using netca
  • Create sql.ora
  • Execute runinstaller

cd /database/

./runinstaller

Kill All Processes belonging to database

ps -ef |grep ora_|grep pc00sb

Start the sqlplus

sqlplus

startup;

               Possible Errors

<<<<If Oracle installer buttons(back,next,cancel) doesn’t display properly>>>>

Press alt+i  or alt+n for going to next screen.

<<<<If Oracle installer buttons(back,next,cancel) doesn’t display properly>>>>

Press alt+i  or alt+n for going to next screen.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s