Blog

Step by Step Installation of Oracle Database 11g on Linux

Oracle Database 11g Installation

System Administrator Task

STEP1:

  • Creating required operating system groups and user
  • Create dba group

# groupadd –g 700 dba

  • Create oracle user and assign to dba group.

#  useradd –u 701 –g dba –d  /home/oracle –m –c   “oracle 11g owner”   oracle

STEP 2:

  • Set the password of the oracle user

# passwd  oracle

  • Choose the mount point where software needs to be staged.

/opt

STEP 3:

  • Change the ownership and permissions

On necessary directories like /opt,/u01,/u02,/backup and etc.

# chown –r  oracle:dba     /opt
# chmod  –r  755              /opt
# chown –r  oracle:dba     /u01
# chown –r  oracle:dba     /u02
# chown –r  oracle:dba     /backup
# chmod  –r  755              /u02
# chmod  –r  755              /backup

STEP 4:

  • Copy the oracle 11g software in this stage area and change the ownership and

#cd  /media/cdrecorder

# cd oracle
#cp  -f  linux_11gr1_database.zip  /opt/oracle11g.zip
# cd  /opt
# chown –r oracle:dba   oracle11g.zip
# chmod  –r 755   oracle11g.zip

STEP 5:

  • Performing the pre-installation tasks check the size of physical ram

# grep  memtotal   /proc/meminfo

NOTE: During the installation it will say failed when it checks the available physical ram is less than 900 mb , no problem even if you have less than 900mb (if it’s for testing purpose), you can continue with the installation.

  • Check the size of swap space

# grep swaptotal /proc/meminfo

  • Check the free disk space in“/tmp” directory

# df -k /tmp

  • Check the free space available on the system.

# df –k

Want To Get DBA Training From Experts? Enroll Now For Free Demo On Oracle DBA Training.

STEP 6:

  • Checking the software requirements
  • The version of linux is installed.

# uname –a

  • Check the following required packages are installed.

Binutils-2.15.92.0.2-18
compat-libstdc++-33.2.3-47.3
elfutils-libelf-0.97-5
elfutils-libelf-devel-0.97-5
glibc-2.3.9.4-2.19
glibc-common-2.3.9.4-2.19
glibc-devel-2.3.9.4-2.19
gcc-3.4.5-2
gcc-c++-3.4.5-2
libaio-devel-0.3.105-2
libaio-0.3.105-2
libgcc-3.4.5
libstdc++-3.4.5-2
libstdc++-devel-3.4.5-2
make-3.80-5
sysstat-5.0.5
unixodbc-2.2.11
unixodbc-devel-2.2.11

  • To check rpms are installed or not.

# rpm –q libaio-devel-0.3.105-2

# rpm –q unixodbc-devel-2.2.11
Like this check for all the above rpms.

Install the missing packages or rpms.

  • To install rpms are installed or not.

Insert the operating system dvd

Go to the dvd mounted location ie., /media/cdrecorder
Or
If your dvd is not mounted then mount it on /mnt directory by using following command

#mount /dev/cdrom /mnt
#cd /mnt
#cd  server
# rpm –ivh unixodbc-devel-2.2.11.3-1.i386.rpm
Or
# rpm –uvh unixodbc-devel-2.2.11.3-1.i386.rpm

NOTE:

If  you are installed oracle enterprise linux 5 no need to perform  or check the rpms

Ie., step 6 in this document.

STEP 7:

  • Configuring kernel parameters.
  • Add the below parameters in  /etc/sysctl.conf

Fs.file-max = 76800
Kernel.shmall = 2097152
Kernel.shmmax  = 2147483648(half of the ram size)
Kernel.shmmni  =  4096
Kernel.sem = 250  32000  100 128
Net.ipv4.ip_local_port_range  =  1024     65000
Net.core.rmem_default = 4194304
Net.core.rmem_max = 4194304
Net.core.wmem_default = 262144
Net.core.wmem_max  =  262144

STEP 8:

  • To change the current values of the kernel parameters.

# /sbin/sysctl –p

STEP 9:

  • Add the following lines in the  /etc/security/limits.conffile

Oracle    soft         nproc      2047
Oracle    hard        nproc      16384
Oracle    soft         nofile      1024
Oracle    hard       nofile     65536

STEP 10:

  • Add or edit the following line in the /etc/pam.d/login file.

Session  required/lib/security/pam_limits.so

Session   required pam_limits.so

STEP 11:

  • Modify the selinux=disabled in /etc/selinux/config file.

#vi /etc/selinux/config

Selinux=enabled—–? modified to disabled

:wq (save and quite)

STEP 12:

  • After performing all these steps we need to restart the sever or system.

# reboot

Or

# init  6

STEP 13:

  • Now login as a root user and fire the below command for to enable the graphical mode.

# xhost +

Checkout Oracle DBA Interview Questions

DATABASE ADMINISTRATOR TASK:

STEP 14:

  • Now login as an oracle user and add the following environment variables in

.bash_profile file.

$vi .bash_profile
Export  oracle_base=/opt /oracle
Export oracle_home=/opt/oracle/product/11.1.0
Export oracle_sid=orcl
Export path=$oracle_home/bin:$path:.
:wq (save & quite)

STEP 15:

  • Run the .bash_profile by using following command.

$ .   .bash_profile

STEP 16:

  • Now move to the stage directory and extract the oracle11g zip file.

$  cd     /opt
$ ls –lrt
$ unzip oracle11g.zip
$ ls –lrt

STEP 17:

  • Now move to the database directory and  run or execute the runinstaller file.

$ cd database
$ ./runinstaller

Explore Oracle DBA Sample Resumes! Download & Edit, Get Noticed by Top Employers!Download Now!

Now we get the graphical wizard here and fallow the necessary steps to install the

Oracle software.

     Here requirements and warnings are negligible.

Now open new terminal.
And login as a root user.
Then execute or run these two scripts.
#/opt/orainventory/orainstroot.sh (press enter)
#/opt/oracle/product/11.1.0/root.sh (press enter)

Now press the yes button for exit this wizard.

 

Related Articles:

How To Create A Oracle Database – DBA Tutorial

Oracle DataBase Architecture Overview

Access To Network Services In Oracle Database - Oracle DBA


RELATED COURSES

Get Updates on Tech posts, Interview & Certification questions and training schedules