Posted by: Charles Kim, Oracle ACE Director and VMware vExpert

We will review the basics of installing Red Hat Linux Enterprise 6 Update 4 for the Intel 64-bit platform in a virtualized infrastructure to prepare an environment to install an Oracle cluster and database(s). To simplify the process and to demonstrate package installation procedures, we will select the option to install the Basic Server and required packages for Oracle databases afterwards. We will also go through a process of creating a local yum repository from the installation media to install packages with dependencies. As the final lesson, we will configure and customize Linux environment.

If you have a Red Hat subscription, you can download RHEL 6 ISO image files from Red Hat’s Software & Download Center customer portal. If you do not already have a subscription, you can obtain a free 30 evaluation subscription from Each of the DVD ISO images are about 3-4 GB in size. After you download the ISO image, create a bootable DVD and USB and reboot the system to start the installation.

In the Boot Menu, if there is no response within 60 seconds, the default option to Install or upgrade an existing system using the GUI will be executed.

You will be given the option to perform a disk check on the installation media. Click on Skip.

The Welcome screen does not accept any actionable inputs to respond to. Click on Next to continue.

Select the language preference to be used for the installation. Please choose English from this option and click on Next

Rhel keyboard
Please select the default U.S. English and click on Next

Rhel basic storage
Select the Basic Storage type and click on Next

Rhel storage device warning

Since this is a fresh install, click on Yes, discard any data button

Enter computer name

Add hostname for the node
Click on Configure Network
Click on Edit

Edit system eth0

Change the Method to Manual
Supply IP and Netmask
Click on Apply
Then click on Close
Then Click on Next

Enter time zone

Select your timezone
Click on Next

Enter root password

Enter the password for root
Click on Next

Weak password

If this is a non-development environment, you will want to choose a more secure password. Since this is my lab, I will choose to Click on Use Anyway and continue.


Click on Review and Modify partition layout
Click on Next

Select a device

Click on Create

Add a partition

Select /tmp for Mount Point
Enter 4096 for Size (MB)
Click on OK

Format warnings

Click on Format

Warning storage configuration

Click on Write changes to disk

Boot loader

Click Next from the Boot loader list screen

Basic server

Select Basic Server and click on Next
It will perform a dependency check and start to perform the installation

Packages completed


Let’s remount our DVD so that we can copy all the RPMs from the DVD to a centralized location on the file system:
Mount cd

In order to setup a local Yum repository, we need to install the createrepo package. The createrepo package has dependencies on two additional packages: deltarpm and python-deltarpm. To successfully install the createrepo package, we will invoke the rpm command with the -ihv option and provide the names of all three packages:
Rpm install

We have successfully installed the createrepo package. The next step will be to copy all the RPMs from the DVD to an area on the local file system. In my example, I am copying the files to the /tmp file system but you will want to select a more permanent location.

We need to create a local yum repository (local.repo) file with the following entries:

[root@rac1 yum.repos.d]# cat /etc/yum.repos.d/local.repo
name=Local Repository

Notice the baseurl parameter. You will need to replace this parameter with the location of your local directory where you placed all the RPMs. After the files are copied, we will invoke the createrepo command and provide the location of the directory where the RPMs were copied to:

We have successfully created our local yum repository. Now we are ready to install required packages for oracle with yum. Let’s install the rsync RPM for demonstration purposes:

[root@rac1 Packages]# yum install rsync
Loaded plugins: product-id, security, subscription-manager
This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register.
Repository rhel-source is listed more than once in the configuration
Repository rhel-source-beta is listed more than once in the configuration
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package rsync.x86_64 0:3.0.6-9.el6 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

 Package                                 Arch                                     Version                                       Repository                               Size
 rsync                                   x86_64                                   3.0.6-9.el6                                   local                                   334 k

Transaction Summary
Install       1 Package(s)

Total download size: 334 k
Installed size: 682 k
Is this ok [y/N]: y
Downloading Packages:
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
  Installing : rsync-3.0.6-9.el6.x86_64                                                                                                                                   1/1 
  Verifying  : rsync-3.0.6-9.el6.x86_64                                                                                                                                   1/1 

  rsync.x86_64 0:3.0.6-9.el6                                                                                                                                                  


Now you are ready to install the remaining packages required by oracle. Here’s a comprehensive list for Oracle Database 11g Release 2:

•	binutils- (x86_64)
•	compat-libstdc++-33-3.2.3-69.el6 (x86_64)
•	glibc-2.12-1.7.el6 (x86_64)
•	ksh-*.el6 (x86_64) 
•	libaio-0.3.107-10.el6 (x86_64)
•	libgcc-4.4.4-13.el6 (x86_64)
•	libstdc++-4.4.4-13.el6 (x86_64)
•	make-3.81-19.el6 (x86_64)
•	compat-libcap1-1.10-1 (x86_64)
•	gcc-4.4.4-13.el6 (x86_64)
•	gcc-c++-4.4.4-13.el6 (x86_64)
•	glibc-devel-2.12-1.7.el6 (x86_64)
•	libaio-devel-0.3.107-10.el6 (x86_64)
•	libstdc++-devel-4.4.4-13.el6 (x86_64)
•	sysstat-9.0.4-11.el6 (x86_64)
•	unixODBC-2.2.11-7.1.x86_64.rpm 
•	unixODBC-2.2.11-7.1.i386.rpm 
•	UnixODBC-devel-2.2.11-7.1.x86_64.rpm 
•	UnixODBC-devel-2.2.11-7.1.i386.rpm

Optional 32-bit Client Software

•	compat-libstdc++-33-3.2.3-69.el6 (i686)
•	glibc-2.12-1.7.el6 (i686)
•	glibc-devel-2.12-1.7.el6 (i686)
•	libaio-0.3.107-10.el6 (i686)
•	libaio-devel-0.3.107-10.el6 (i686)
•	libgcc-4.4.4-13.el6 (i686)
•	libstdc++-4.4.4-13.el6 (i686)
•	libstdc++-devel-4.4.4-13.el6 (i686)

In addition to the above mention RPMs, here’s some additional set of executables that may be of interest to you as an administrator:

•	screen
•	wget
•	rsync
•	nmon
•	uuencode

Next, let’s modify our kernel parameters in /etc/sysctl.conf. In your environment, if the kernel parameter value is higher than the value listed below, you should not lower the value. Range values (such as net.ipv4.ip_local_port_range) should match accordingly. Parameters like SHMMAX should be adjusted accordingly to the amount of physical memory on the database server (i.e. For example, I generally tell customers that a good number to start is ½ or 2/3 or more of physical memory depending on how much physical memory that they have and how much PGA and number of dedicated server processes they expect). SHMALL is also derived based on physical RAM size / pagesize.

# --Setting up Kernel Parameters for Oracle Database 11g R2 installation

# Controls the maximum shared segment size, in bytes
kernel.shmmax = 4398046511104

# Controls the maximum number of shared memory segments, in pages
kernel.shmall = 1073741824
# For 11g, recommended value for file-max is 6815744
fs.file-max = 6815744
# For 10g, uncomment 'fs.file-max 327679', comment other entries for this parameter and re-run sysctl -p
# fs.file-max:327679
kernel.msgmni = 2878
kernel.sem = 250 32000 100 142
kernel.shmmni = 4096
net.core.rmem_default = 262144
# For 11g, recommended value for net.core.rmem_max is 4194304
net.core.rmem_max = 4194304
# For 10g, uncomment 'net.core.rmem_max 2097152', comment other entries for this parameter and re-run sysctl -p
# net.core.rmem_max=2097152
net.core.wmem_default = 262144
# For 11g, recommended value for wmem_max is 1048576
net.core.wmem_max = 1048576
# For 10g, uncomment 'net.core.wmem_max 262144', comment other entries for this parameter and re-run sysctl -p
# net.core.wmem_max:262144
fs.aio-max-nr = 3145728
# For 11g, recommended value for ip_local_port_range is 9000 65500
net.ipv4.ip_local_port_range = 9000 65500
# For 10g, uncomment 'net.ipv4.ip_local_port_range 1024 65000', comment other entries for this parameter and re-run sysctl -p
# net.ipv4.ip_local_port_range:1024 65000
# Added min_free_kbytes 50MB to avoid OOM killer on EL4/EL5
vm.min_free_kbytes = 51200
fs.file-max = 6815744

To activate these new settings into the running kernel space, run the “sysctl –p” command as root.

As the final steps, we need to create the dba, oinstall, and asmadmin groups and the oracle user account. The following set of scripts can be leveraged to automate this process:

/usr/sbin/groupadd -g xxxx oinstall
/usr/sbin/groupadd -g xxxx dba
/usr/sbin/groupadd -g xxxx asmadmin

Where xxx is the gid that conforms to your corporate standards.

useradd -u xxxx -g xxxx -s /bin/bash -d /home/oracle -c "Oracle Admin" oracle
passwd oracle

Where xxxx is the uid and gid that conforms to your corporate standards.

Lastly, we will create the directories for grid infrastructure and oracle database software:

mkdir –p /u01/app/11.2.0/grid
mkdir -p /u01/app/oracle/product
mkdir -p /u01/app/oraInventory
mkdir –p /u01/app/oracle/general

chown -R oracle:oinstall /u01/app
chmod -R 775 /u01/app

Please set the home directory for oracle to be: /home/oracle
Please make sure we have the nobody user created

Comments are closed