11gR2 Database Installation with ASM on OEL5

I will be listing down steps for 11g Release 2 installation on Linux x86. There has been few changes incorporated in 11gR2 which must be given due consideration before starting installation. ASM instance now runs from new Oracle Home called Grid Infrastructure.

If you wish to use ASM for storing database files, then you should install first Oracle grid infrastructure for a standalone server. It is also required if you wish to use Oracle Restart feature (Provides for automatic restart of DB and other components after a hardware or software failure or whenever your database host computer restarts) for single instance.

Environment used for this setup
Operating System – Oracle Enterprise Linux Release 5(OEL5) on Vmware
Physical Ram – 1Gb

Asmlib for labeling ASM Disks.Refer to following OTN article for configuring asmlib and creating disks.

Software can be downloaded from OTN at following link

Oracle Database 11g Release 2 Grid Infrastructure ( for Linux x86

Oracle Database 11g Release 2 ( for Linux x86

All the pre-requisites for installation can be found here

I have tried to shorten it by keeping things which are relevant to our setup.

Check Packages


If you have yum installed on your machine, then it is very easy to install the packages. You can copy the list of packages in a text file and insert ‘yum install ‘ in beginning and execute it as root. This will install any missing packages. To know more about setting up yum, refer to my previous post

If Kernel parameters are not setup correctly, Oracle 11g OUI provides you  a fixup script and also ability to resume the installation process without need to re-run the earlier steps. Please refer to article here

Users,Roles and Groups for Installation

osdba group for ASM – Membership in the OSDBA group allows access to the files managed by Automatic Storage Management. It can be same as database osdba group. We will be using group dba in our setup.
OSASM group – Members of the OSASM group can use SQL to connect to an Automatic Storage Management instance as SYSASM using operating system authentication. The SYSASM privileges permit mounting and dismounting disk groups, and other storage administration tasks. SYSASM privileges provide no access privileges on an RDBMS instance. We will use asmadmin

OSOPER group – Similar to SYSOPER privilege in RDBMS, this is used for limited privileges like starting up and stopping the Oracle ASM instance. We will not be using separate group for it, will be selecting dba in our setup

oinstall – This is similar to previous releases, and used for Oracle Inventory group

I am using oracle user for installing Grid Infrastructure and Oracle Database Software. You can have a separate user say oragrid with oinstall membership and permission on oracle inventory directory.

Create Base directory where software will be installed. I used /u02/app/oracle

Add users and groups

/usr/sbin/groupadd -g 501 dba
/usr/sbin/groupadd -g 504 asmadmin
/usr/sbin/groupadd oinstall

/usr/sbin/useradd -u 502 -g oinstall -G dba,asmadmin oracle

Add following entries to /etc/security/limits.conf

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

Add or edit the following line in the /etc/pam.d/login file, if it does not already exist:

session    required     pam_limits.so

Add/replace following entries in /etc/sysctl.conf

fs.aio-max-nr = 1048576
fs.file-max = 6815744
kernel.shmall = 2097152
kernel.shmmax = 536870912
kernel.shmmni = 4096
kernel.sem = 250 32000 100 128
net.ipv4.ip_local_port_range = 9000 65500
net.core.rmem_default = 262144
net.core.rmem_max = 4194304
net.core.wmem_default = 262144
net.core.wmem_max = 1048586

Execute following command as root to change the current kernel parameters:

/sbin/sysctl -p

Copy following in your login profile.

if [ $USER = "oracle" ]; then
        if [ $SHELL = "/bin/ksh" ]; then
              ulimit -p 16384
              ulimit -n 65536
              ulimit -u 16384 -n 65536
umask 022

We need to start with Grid Infrastructure installation. Unzip the contents and execute  runInstaller . This would require 2.8Gb of disk space.


Please click on image below for  displaying screenshots for 11gR2 Grid Infrastructure installation


Execute root.sh from Grid ORACLE_HOME as root user

The following environment variables are set as:
    ORACLE_OWNER= oracle
    ORACLE_HOME=  /u02/app/oracle/product/11.2.0/grid

Enter the full pathname of the local bin directory: [/usr/local/bin]:
The file "dbhome" already exists in /usr/local/bin.  Overwrite it? (y/n)
[n]: y
   Copying dbhome to /usr/local/bin ...
The file "oraenv" already exists in /usr/local/bin.  Overwrite it? (y/n)
[n]: y
   Copying oraenv to /usr/local/bin ...
The file "coraenv" already exists in /usr/local/bin.  Overwrite it? (y/n)
[n]: y
   Copying coraenv to /usr/local/bin ...

Entries will be added to the /etc/oratab file as needed by
Database Configuration Assistant when a database is created
Finished running generic part of root.sh script.
Now product-specific root actions will be performed.
2009-09-02 05:07:26: Checking for super user privileges
2009-09-02 05:07:26: User has super user privileges
2009-09-02 05:07:26: Parsing the host name
Using configuration parameter file: /u02/app/oracle/product/11.2.0/grid/crs/install/crsconfig_params
Creating trace directory
Creating OCR keys for user 'oracle', privgrp 'oinstall'..
Operation successful.
CRS-4664: Node db11g successfully pinned.
Adding daemon to inittab
CRS-4123: Oracle High Availability Services has been started.
ohasd is starting

db11g     2009/09/02 05:09:24     /u02/app/oracle/product/11.2.0/grid/cdata/db11g/backup_20090902_050924.olr
Successfully configured Oracle Grid Infrastructure for a Standalone Server
Updating inventory properties for clusterware
Starting Oracle Universal Installer...

Checking swap space: must be greater than 500 MB.   Actual 2399 MB    Passed
The inventory pointer is located at /etc/oraInst.loc
The inventory is located at /u01/app/oraInventory
'UpdateNodeList' was successful.

To install Database software, Unzip the contents of both the zip files and execute runInstaller . Ensure you have 3.95Gb of free disk space


Please click on image for  displaying screenshots for 11gR2 Database installation .


You are done 🙂


Value /Commands to Check

Physical RAM >1 Gb

grep MemTotal /proc/meminfo

Swap should be 1.5 times the RAM.

In our case it will be 1.5G
grep SwapTotal /proc/meminfo

/dev/shm to be configured to use MEMORY_TARGET

# df -h /dev/shm/

1Gb of /tmp space

df -h /tmp

Disk space Requirement for Grid Infrastructure Software (Enterprise edition)

2.95 Gb

Disk space Requirement for Database Software (Enterprise edition)

3.95 Gb

Packages for OEL5


Amit Bansal

Experienced professional with 16 years of expertise in database technologies. In-depth knowledge of designing and implementation of Disaster Recovery / HA solutions, Database Migrations , performance tuning and creating technical solutions. Skills: Oracle,MySQL, PostgreSQL, Aurora, AWS, Redshift, Hadoop (Cloudera) , Elasticsearch, Python

This Post Has 50 Comments

  1. Amit

    Hi All,

    Screenshots for the installation are present here


    I was not able to figure out , how to implement delay mechanism in viewlet builder so you would see there is very less time gap between slides. I would recommend using the "Forward" button on bottom right to view slides one by one.

    Update :- I have been able to insert a delay in the slides 🙂
    Hope this helps..


    1. Gaurav

      Hi Amit,

      Links provided are not working as being incomplete.


      1. Amit

        Thanks Gaurav. I have corrected the link now. Let me know in case you still face issues.


  2. Jia Lu

    Can you give out the way to set ASM or put it on Cast?

      1. JrOraDBA

        Hi Amit,

        I am also upgrading to 11gR2 from 11gR1 and in your screenshot I get the same error INS-20802. You said it was because of the '+ASM1' entry in the /etc/oratab file. However, i get the same error and I am not running a RAC. When I look at my entry in the /etc/oratab file, I only see the new ASM entry for 11.2.0 Oracle ASM Home. Do you have any idea how I could resolve the issue?


  3. mike

    11g doku says ksh and I installed the ksh package on centos, but when I run the installer it fails and says pdksh is not installed… any ideas?

  4. Guireg

    Very good article, helpful ! Thanx very much !

  5. Kabbo

    Hi Amit,
    uname -r
    Do you know, exactly, which ASM library should I install for my kernel? My os is OEL5 update 4?

  6. Aman....


    I am not able to create the disks! I have added a disk to my vm, did the partition of it using fdisk and also asmlib is running as well. But when I am trying to create the disk from the aslib, it gives me the error that the creation is failed. Can you help in mentioning the steps to add the disks first from the o/s ? ASlib is fine wouold work I believe once the device is there.


    1. Amit


      Can you please give output of fdisk -l /dev/sdb . Want to ensure if you have created a partition on it.


      1. Amit

        Steps should be like

        #fdisk -l /dev/sdb
        Disk /dev/sdb: 41.9 GB, 41943040000 bytes
        64 heads, 32 sectors/track, 40000 cylinders
        Units = cylinders of 2048 * 512 = 1048576 bytes
           Device Boot      Start         End      Blocks   Id  System
        /dev/sdb1               1       40000    40959984   83  Linux

        Once you have created a partition on device, you need to create a ASM disk

        # /usr/sbin/oracleasm createdisk VOL1 /dev/sdb1
  7. Aman....

    Yes, I have done it and in the morning,I was able to create two disks as well. But they are not visible from the Grid Infrastrucure. But the disks are visible from the asmlib interface properly. Just they are not shown when the installation starts and the disk group creation screen appears. So what could be the reason for it.

    I can’t post the output at the moment but can confirm that I have created teh partition on teh disk as well as the disks got created from asmlib. Now the problem lies that they created disks are not visible.

  8. Aman....

    This is what I have,

    [[email protected] yum.repos.d]# /etc/init.d/oracleasm listdisks
    [[email protected] yum.repos.d]#

    But I am not able to see these disks when I am running the installer.

    1. Amit


      I think I too faced this issue. I put asm_diskstring parameter as /dev/oracleasm/disks/ASM*

      You can see the same in screenshot of the installations.


  9. Emmanuel

    Please can you send me instruction on how to install Oracle 11g R2 ASM standalone. This installation is without RAC setup

  10. sachin

    Can u plz help me out, osdba group user is creating CRD file,but they are getting owner by oracle user, why so

  11. Amit


    I am not sure what CRD actually means. Could you please provide following information

    a) which file you are looking. its directory location and also ls -ltr output
    b) Output of ps -ef|grep pmon
    If this is RAC, then also give output of ps -ef|grep d.bin


    1. sachin

      Regarding the 11gR2, new DBA group OS user can connect as sysdba, but the problem is that CRD files(controlfile,redologfile,datafiles) and other directories(like ADR diag) created by this user(from SQL prompt ,recursive by oracle) are automatically getting owned by Oracle Software owner i.e.,oracle user.
      Plz. provide me a solution to solve this problem.

  12. sachin

    Regarding the 11gR2, new DBA group OS user can connect now as sysdba, but the problem is that CRD files and other directories(like diag) created by this user(from SQL prompt ,recursive by oracle) are automatically getting owned by Oracle Software owner i.e.,oracle user.
    I think this due to the limited privileges from this test download version of 11gR2.
    Plz, guide me for further process to proceed.

  13. dong

    Good article,Thank you very much.

  14. ehnois

    Hello, how are you doing?
    I would like to know if it’s possible to install the Grid package after the Database 11gR2. The case is that I wasn’t planning to use the ASM feature at the time of the installation, but now, I would like to test it. Is it necessary to install all from scratch again? Following the Oracle guide, installing the Grid package first and then the Database ?
    Thank you for your help.

  15. Aishwarya Kambale

    Hi Amit,

    Thanks for the quick guide for 11gr2 installation. It’s very helpful. I went through the entire blog including the two videos. You have installed GRID and then just created and configured the Database. I am new to Oracle and especially 11gr2.

    My question is: Do we require to install the software(oracle binaries) if grid is installed before?

    I installed and configured GRID successfully on standalone server. But when i try to configure LISTENER for the oracle software, it says that the LISTENER is already configured.

    1. Amit

      Hi Aishwarya,

      Grid software (for standalone installation i,e non-RAC) is required if you wish to use ASM. Otherwise to use DB, you need to install DB software alone. So answer to your first question is Yes.

      Listener will be running from GRID_HOME. Check using ps -ef|grep tns
      You should see a listener running from your grid home


  16. Williams Laverde

    Hi, Amit
    Do I have to install and configure ASMLib Before get into Grid Infra?

    Do you have the steps to configure your VM on Vmware and OEL5

    1. Amit

      Yes, you need to insall it before as you will be configuring and creating ASM instance and diskgroup.

      I don’t have steps to conifgure my Vm. You can try http://oracle-base.com for steps.


      1. Williams Laverde

        Thank you Amit for your answer

  17. Gabriel

    Hi Amit, do you know how can i create a rac database 11gr2 on silent mode? Need an example shell script.

    Thanks in advance

    1. Amit


      You can use dbca in silent mode. Find below syntax for same

      dbca -silent                             \
             -nodelist prod-001,prod-002\
             -createDatabase                     \
             -templateName General_Purpose.dbc   \
             -gdbName ORCL                       \
             -sid ORCL                           \
             -SysPassword oracle      \
             -SystemPassword oracle             \
             -emConfiguration NONE               \
             -storageType ASM                    \
               -asmSysPassword oracle \
               -diskGroupName DG_DATA01             \
             -characterSet AL32UTF8         \
             -totalMemory 3500


      1. Gabriel

        Thanks very much Amit. Keep in touch.


  18. mike

    I have a new install on a fresh VM Linux machine and I keep getting the INS-32025. I am trying to do the grid infrastructure install for a standalone database so that I can use ASM with 11GR2. I made sure the ORACLE_HOME and ORACLE_BASE are UNset. I get to the screen that asks for the oracle base and oracle home and no matter what i put, it fails. I have no oracle software installed, no oratab, no oracle anything on this machine. Any ideas please?

    1. Amit


      Yeah it sounds strange. Can you create a new directory manually and ensure that its empty and retry the operation. If it fails you would definitely need to contact support as this could be bug.


  19. Ahmed B.


    When I try to install Grid infrastructure using os user different from the one to install DB, I faced a problem.

    When I reached to creating db phase and the dbca started creating the db, it retuned the following errors:

    PRCR-1079: Failed to start resource ora.oradb.db
    ORA-12547: TNS lost contact
    CRS-2674: start ora.oradb.db on ‘srv07’ failed

    In order to see which command exactly caused the error, I created the scripts from DBCA and started to execute the commands manually. It turned out the errors were generated in the last stage of db creation as follows:

    [[email protected] scripts]$ /u01/app/oracle/product/11.2.0/db_1/bin/srvctl start database -d oradb
    PRCR-1079 : Failed to start resource ora.oradb.db
    ORA-12547: TNS:lost contact
    ORA-12547: TNS:lost contact
    CRS-2674: Start of ‘ora.oradb.db’ on ‘srv07’ failed

    1. Amit

      Is this user part of same ‘osdba’ group as that of user which installed software?
      If not then add it.


  20. Mexman

    How to resolves the issue of start ASM in the step to upgrade with OUI? I use the ‘grid’ user to upgrade from to1.2.0.2.


  21. Prasant

    sir i want to install oracle in my home pc for prctice which is exact i have taken training from oracle. in oracle training i just install grid and database but the asmdisk already created that i dont know how to create so kinly can u guide me how to create ASM disk then what are the prerequisite requirement for install grid and database 11g in oracle linux 5. i m using VMware.

  22. Whitepaper

    Great it help me .I too saved the same problem.While installing 11GR2 on Vmware.Disks were not visible.Though i may able to see them from oracleasm listdisks.

    I use same solution as describled :-set asm_diskstring parameter to /dev/oracleasm/disks/D*

  23. jeff

    I’ve encountered a error when running root.sh

    Using configuration parameter file: /u01/app/oracle/product/11.2.0/grid/crs/install/crsconfig_params
    Creating trace directory
    Failure with signal 11 from command: /u01/app/oracle/product/11.2.0/grid/bin/crsctl pin css -n ora-south
    Creating local-only OCR (/u01/app/oracle/product/11.2.0/grid/bin/crsctl pin css -n ora-south) … failed

    OS linux 5 Update 2

    please help,

    Thank you

    please help

    1. Amit


      My Oracle Support has few articles on this error. Would recommend checking them


Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.