How to Install and Getting Started on Oracle 11 G R2 Database for RHEL6 Linux

April 12, 2012 | By Regaz.

This an Easy and Step-by-Step Guide to Install and Quickly Getting-Started the Oracle 11g R2 Database on a Red Hat Enterprise Linux 6.x System.

To have a Nice Journey through this WoWtUt Relax and Take the Time of Reading, Understanding and Executing Carefully the Instructions Contained here.

To the Article Bottom you Find Links to Oracle 11g Database Detailed Troubleshooting Guides.

How to Install Oracle 11g R2 Database on Oracle Linux 6
  1. Download the Database Release
    Oracle 11g R2
  2. Open a Terminal Window
    (Press “Enter” to Execute Commands)

  3. Login as SuperUser:

    If Got “User is Not in Sudoers file” then see: How to Enable sudo

  4. Make Network Configuration

    Check you hostname and IP is on /etc/hosts.

    Get your hostname:


    Get your IP:


    You will Find your Ip under the Output “lo” Section.

    Check if Hostname and IP are already inserted into the Enabled Hosts File.

    cat /etc/hosts

    If It’s Not Present then Insert it!

    nano /etc/hosts

    Insert: .

    Example: ‘ localhost.localdomain localhost’

    Ctrl+Shift+v to Paste Content on nano
    Ctrl+x to Save and Exit
    from nano Editor :)

    Add you Host IP to the List of Hosts Granted of Connection with the X Server

    xhost +yourIP

    Example: #xhost +

  5. If you Do Not Dispose of RHEL Subscription.

    How to Setup YUM
  • Install dependencies

    sudo yum install binutils glibc compat-libstdc++-33 glibc-common 
    glibc-devel glibc-headers elfutils-libelf elfutils-libelf-devel
    elfutils gcc gcc-c++ ksh libaio libaio-devel libgcc libstdc++-devel
    make numactl-devel sysstat mksh
  • Add Groups and User

    groupadd -g 502 oinstall
    groupadd -g 503 dba
    groupadd -g 504 oper
    groupadd -g 505 asmadmin
    useradd -u 502 -g oinstall -G dba,asmadmin,oper -s /bin/bash -m oracle
    passwd oracle

    Take Note of the oracle User Pass :)

  • Create the directories where Oracle will be installed and give right ownership and permission

    mkdir -p /u01/app/oracle/product/11.2.0/
    chown -R oracle:oinstall /u01
    chmod -R 775 /u01
  • Set Kernel’s Parameters

    nano /etc/sysctl.conf

    Then hit Ctrl+x to Save and Exit from nano EditorAdd or amend the following lines in the /etc/sysctl.conf file.

    #### Oracle 11g Kernel Parameters ####
    fs.suid_dumpable = 1
    fs.aio-max-nr = 1048576
    fs.file-max = 6815744
    kernel.shmall = 818227
    kernel.shmmax = 4189323264
    kernel.shmmni = 4096
    # semaphores: semmsl, semmns, semopm, semmni
    kernel.sem = 250 32000 100 128
    net.ipv4.ip_local_port_range = 9000 65500

    Comment out these lines below than give an error
    #net.bridge.bridge-nf-call-ip6tables = 0
    #net.bridge.bridge-nf-call-iptables = 0
    #net.bridge.bridge-nf-call-arptables = 0

    nano /etc/security/limits.conf

    Add the following lines to the /etc/security/limits.conf file.

    #### oracle User Settings 4 Oracle 11g ####
    oracle soft nproc 2047
    oracle hard nproc 16384
    oracle soft nofile 1024
    oracle hard nofile 65536
    oracle soft stack 10240

    nano /etc/selinux/config

    Disable Secure Linux by editing the /etc/selinux/config file, making sure the SELINUX flag is set as follows.


    Run the following command to Load the New Kernel Parameters.

    /sbin/sysctl -p
  • Unzip the Oracle 11g Database, Set oracle as Owner and Move it into the oracle’s Home

    cd </path/2>
    chown -R oracle:oinstall database
    mv database /home/oracle
  • Add Paths to oracle’s .bashrc
    Login as Oracle

    su oracle

    Edit .bashrc file

    nano ~/.bashrc


    # Oracle Settings
    TMP=/tmp; export TMP
    TMPDIR=$TMP; export TMPDIR
    ORACLE_BASE=/u01/app/oracle; export ORACLE_BASE
    ORACLE_HOME=$ORACLE_BASE/product/11.2.0/dbhome_1; export ORACLE_HOME
    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

    Replace [HOSTNAME] with IP and [DBSID] with SID Name
    In this Example Respectively:

    Load New .bashrc Settings.


    Latest and Optional to Add Cross-Shell Compatibility edit also oracle’s .bashrc.

    nano ~/.bashrc

    Add as Latest Entry the Line.

  • Install the Oracle 11g Software
    cd /home/oracle/database

    If you Get: “Check if the DISPLAY variable is set. Failed”. Look Link Below.

    Link2+ Oracle 11g Database Troubleshooting.

    Linux Start Oracle 11g R2 Installation

    On the first screen If you Do Not Dispose of an Oracle Subscription Just Leave Blank eMail and Un-Check the Demand of Security Update Support then Click on Next
    Linux Oracle 11g R2 Installation Step 1 - Disabling Security Updates

    Then Confirm on Warning and Follow.
    Linux Oracle 11g R2 Installation - Confirm on Missing eMail Warning

    On “Select Installation Option” Select “Install database software only” and Click on Next
    Linux Oracle 11g R2 Installation Step 2

    On Step 3 Leave Default “Single instance database installation” and Click on Next
    Linux Oracle 11g R2 Installation Step 3

    On Step 4 Select your Language and Click on Next
    Linux Oracle 11g R2 Installation Step 4On Step 5 Leave Default Enterprise Edition and Click on Next
    Linux Oracle 11g R2 Installation Step 5

    On “Installation Location” Set All As Here Below and Click on Next


    These are the Same Settings Inserted into the .bashrc File…

    Linux Oracle 11g R2 Installation Step 6

    On “Create Inventory” if you Setup the Path on .bashrc Like Here Leave Default and Click on Next
    Linux Oracle 11g R2 Installation Step 7

    On “Operating System Groups” if you Setup the Path on .bashrc Like Here Leave Default and Click on Next
    Linux Oracle 11g R2 Installation Step 8

    On “Prerequisite Checks” you will Get Easily a “Warning Message” about some Missing Requirements.

    Just Check: “Ignore All” and Follow Up with Installation…

    Linux Oracle 11g R2 Installation Step 9

    On the “Summary” Click on “Save Response File” to Take Note of Settings and then Click on Finish
    Linux Oracle 11g R2 Installation Step 10

    The Installation Product Procedure should Start… Wait Until Successful Achievement. Linux Oracle 11g R2 Installation Step 11
    Right Before the End of Process a Pop-Up Window will Show the Path to Two Configuration Scripts you Need to Execute on Terminal!

    Latest Oracle Should Confirm you of a Successful Installation End.) Linux Oracle 11g R2 Installation Step 12

  • How to Create and Run an Oracle 11g Listener:

    Oracle 11g DB Listener Guide
  • Linux Penguin Oracle 11g
  • Create an Oracle 11g Database
  • After you have Access to the “Enterprise Manager” on Browser by the URL shown on the Latest Screen.
    On a Localhost for Example you Should Access the Enterprise Manager by the Address:

    And you can Login with:
    Username: SYS
    Password: oracleDatabasePassword
    From the Drop-down below Select >> Connect as SYSDBA
    You Should be able to Access the Database by the Enterprise Manager!

    How Managing, Start & Stop Oracle 11g R2 Database by SQLPlus Commands
    SQLPlus Oracle 11g DB Quick Start

    Oracle 11g Database Troubleshooting Guides

    Enjoy this “Step by Step” Clear Installation and Getting Started…
    Good Luck! :)

    Tags: , , , , , , , , , ,