Top Banner
Home Metalink Oracle 11gR2 Oracle 11gR2 +++ Oracle Tops 5 Oracle DB 10g & 11g Tops " Si j'étais riche, je pisserais tout le temps. " Alphonse Allais (1854-1905) October 8, 2009 Installing Oracle Database 11g Release 2 on Linux x86 (RHEL and OEL 5 covered) Posted by aki oracleref under Oracle Technical References | Tags: 11g, 11gr2, database, install, linux, oel5, rhel5 | Leave a Comment 1. Overview For the purpose of education and evaluation only, we provide a walkthrough of installing Oracle Database 11g Release 2 on Linux. We take the approach of using minimum number of steps for accomplishing this installation. Note that this guide does not cover the installation of the Linux operating system. This guide assumes a server with the following hardware requirements: A single CPU, 1024 Mb of RAM, and one disk drive (IDE, SCSI, or FireWire) with at least 7 Gb of free space: 1024 Mb of disk space in the /tmp directory, 3.8 Gb of local disk space for the database software, and about 1.5 Gb of swap disk space. This procedure is based on Metalink Note: 880936.1: Requirements for Installing Oracle 11gR2 RDBMS on RHEL (and OEL) 5 on 32-bit x86 Installing Oracle Database 11g Release 2 on Linu... http://oracleref.wordpress.com/2009/10/08/install... 1 of 20 21/06/2011 13:35
20

Install oracle11gr2 rhel5

Nov 29, 2014

Download

Documents

 
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Install oracle11gr2 rhel5

HomeMetalinkOracle 11gR2Oracle 11gR2 +++Oracle Tops 5

Oracle DB 10g & 11g Tops" Si j'étais riche, je pisserais tout le temps. " Alphonse Allais (1854-1905)

October 8, 2009

Installing Oracle Database 11g Release 2 onLinux x86 (RHEL and OEL 5 covered)

Posted by aki oracleref under Oracle Technical References | Tags: 11g, 11gr2,database, install, linux, oel5, rhel5 |Leave a Comment

1. Overview

For the purpose of education and evaluation only, we provide a walkthrough ofinstalling Oracle Database 11g Release 2 on Linux. We take the approach ofusing minimum number of steps for accomplishing this installation. Note thatthis guide does not cover the installation of the Linux operating system.

This guide assumes a server with the following hardware requirements:

A single CPU,1024 Mb of RAM,and one disk drive (IDE, SCSI, or FireWire) with at least 7 Gb of freespace:

1024 Mb of disk space in the /tmp directory,

3.8 Gb of local disk space for the database software,

and about 1.5 Gb of swap disk space.

This procedure is based on Metalink Note: 880936.1: Requirements forInstalling Oracle 11gR2 RDBMS on RHEL (and OEL) 5 on 32-bit x86

Installing Oracle Database 11g Release 2 on Linu... http://oracleref.wordpress.com/2009/10/08/install...

1 of 20 21/06/2011 13:35

Page 2: Install oracle11gr2 rhel5

As preliminary step, let us verify the prerequisites for installing Oracle 11gR2RDBMS:

Required kernel version:

Red Hat Enterprise Linux Server 5.2 (or greater), which is Kernel2.6.18-92 or ewer.

Required packages versions:

C.f. Oracle Metalink Note: 880936.1

Swap Disk Space Considerations:

Installing Oracle Database 11g Release 2 requires a minimum of1024Mb of memory. Swap disk space should be proportional to thesystem’s physical memory:

With RAM as 1024 Mb to 2048 Mb, Swap Disk Space should be 1.5 xRAM

To check the amount of memory we have:

$ cat /proc/meminfo | grep MemTotal

MemTotal: 1048576 kB

To check the amount of swap space we have allocated:

$ cat /proc/meminfo | grep SwapTotal

SwapTotal: 1572864 kB

2. Configuring Linux for the Installation ofOracle Database 11g Release 2

This section walks through the steps required to configure Linux for installingOracle Database 11g Release 2. These steps are written for Bourne, Korn andbash shells.Firstly, open a terminal window and login as the root user.

2.1 Setting Kernel Parameters

The kernel parameters presented in this section are recommended values asdocumented by Oracle Metalink note 880936.1.

Installing Oracle Database 11g Release 2 on Linu... http://oracleref.wordpress.com/2009/10/08/install...

2 of 20 21/06/2011 13:35

Page 3: Install oracle11gr2 rhel5

i. Setting Shared Memory

Setting SHMMAX

We can determine the value of SHMMAX by performing the following:

$ cat /proc/sys/kernel/shmmax

536870912

Should you need to alter the default setting for SHMMAX without rebooting themachine:

$ sysctl -w kernel.shmmax=536870912

Should you need to make this change permanent, insert the kernel parameter inthe /etc/sysctl.conf startup file:

$ echo “kernel.shmmax=536870912″ >> /etc/sysctl.conf

Setting SHMMNI

We can determine the value of SHMMNI by performing the following:

$ cat /proc/sys/kernel/shmmni

4096

The default setting for SHMMNI should be adequate for the Oracle11g Release2 installation.

Setting SHMALL

The default size of SHMALL is 2097152 and can be queried using:

$ cat /proc/sys/kernel/shmall

2097152

The default setting for SHMALL should be adequate for the Oracle11g Release2 installation.

To determine all shared memory limits:

$ ipcs -lm

Installing Oracle Database 11g Release 2 on Linu... http://oracleref.wordpress.com/2009/10/08/install...

3 of 20 21/06/2011 13:35

Page 4: Install oracle11gr2 rhel5

—— Shared Memory Limits ——–

max number of segments = 4096

max seg size (kbytes) = 4194303

max total shared memory (kbytes) = 1073741824

min seg size (bytes) = 1

ii. Setting Semaphore Kernel Parameters

We can alter the default setting for all semaphore settings without rebooting themachine by making the changes directly using the following command:

$ sysctl -w kernel.sem=”250 32000 100 128″

We should then make this change permanent by inserting the kernel parameterin the /etc/sysctl.conf startup file:

$ echo “kernel.sem=250 32000 100 128″ >> /etc/sysctl.conf

To determine all semaphore limits:

$ ipcs -ls

—— Semaphore Limits ——–

max number of arrays = 128

max semaphores per array = 250

max semaphores system wide = 32000

max ops per semop call = 32

semaphore max value = 32767

We can also use the following command:

$ cat /proc/sys/kernel/sem

250 32000 100 128

iii. Setting File Handles

To determine the maximum number of file handles for the entire system:

Installing Oracle Database 11g Release 2 on Linu... http://oracleref.wordpress.com/2009/10/08/install...

4 of 20 21/06/2011 13:35

Page 5: Install oracle11gr2 rhel5

$ cat /proc/sys/fs/file-max

6815744

Should you need to alter the default setting for the maximum number of filehandles without rebooting the machine:

$ sysctl -w fs.file-max=6815744

Should you need to make this change permanent, insert the kernel parameter inthe /etc/sysctl.conf startup file:

$ echo “fs.file-max=6815744″ >> /etc/sysctl.conf

We can query the current usage of file handles by using the following:

$ cat /proc/sys/fs/file-nr

825 0 6815744

iv. Setting IP Local Port Range

We should configure the system to allow a local port range of 9000 through65500 as recommended by Oracle.

We Use the following command to determine the value of ip_local_port_range:

$ cat /proc/sys/net/ipv4/ip_local_port_range

9000 65500

Should you need to alter the default setting for the local port range withoutrebooting the machine:

$ sysctl -w net.ipv4.ip_local_port_range=”9000 65500″

Should you need to make this change permanent, insert the kernel parameter inthe /etc/sysctl.conf startup file:

$ echo “net.ipv4.ip_local_port_range = 9000 65500″ >> /etc/sysctl.conf

v. Activating All Kernel Parameters for the System

At this point, we have covered all the required Linux kernel parameters neededfor a successful Oracle Database 11gR2 installation and configuration.

We can reboot to ensure all of these parameters are set in the kernel or we can

Installing Oracle Database 11g Release 2 on Linu... http://oracleref.wordpress.com/2009/10/08/install...

5 of 20 21/06/2011 13:35

Page 6: Install oracle11gr2 rhel5

run the following command as root.

$ /sbin/sysctl –p

net.ipv4.ip_forward = 0

net.ipv4.conf.default.rp_filter = 1

net.ipv4.conf.default.accept_source_route = 0

kernel.sysrq = 0

kernel.core_uses_pid = 1

net.ipv4.tcp_syncookies = 1

kernel.msgmnb = 65536

kernel.msgmax = 65536

net.core.rmem_default = 262144

net.core.rmem_max = 4194304

net.core.wmem_default = 262144

net.core.wmem_max = 1048576

kernel.shmmax = 536870912

kernel.sem = 250 32000 100 128

fs.file-max = 6815744

net.ipv4.ip_local_port_range = 9000 65500

2.2 Creating Groups and User for Oracle

Open a terminal window and login as the root user.

$ /usr/sbin/groupadd -g 501 oinstall

$ /usr/sbin/groupadd -g 502 dba

$ /usr/sbin/groupadd -g 503 oper

$ /usr/sbin/groupadd -g 504 asm

Installing Oracle Database 11g Release 2 on Linu... http://oracleref.wordpress.com/2009/10/08/install...

6 of 20 21/06/2011 13:35

Page 7: Install oracle11gr2 rhel5

$ /usr/sbin/groupadd -g 505 asmdba

$ /usr/sbin/useradd -m -u 501 -g oinstall -G dba,oper,asm, asmdba -d/home/oracle -s /bin/bash -c “Oracle Software Owner” oracle

$ id oracle

uid=501(oracle) gid=501(oinstall) groups=501(oinstall), 502(dba),503(oper), 504(asm), 505(asmdba)

Set the password for the oracle account:

$ /usr/sbin/passwd oracle

Verify That the User nobody exists

$ id nobody

uid=99(nobody) gid=99(nobody) groups=99(nobody)

2.3 Creating the Oracle Base Directory

Create the directory for the software installation and assign ownership tooracle:oinstall.

$ mkdir -p /u01/app/oracle

$ chown -R oracle:oinstall /u01/app

$ chmod -R 775 /u01/app

/u01 owned by root./u01/app owned by oracle:oinstall with 775 permissions./u01/app/oracle owned by oracle:oinstall with 775 permissions.

2.4 Setting /home/oracle/.bash_profile for the Oracle user

# .bash_profile

# Get the aliases and functions

if [ -f ~/.bashrc ]; then

. ~/.bashrc

fi

Installing Oracle Database 11g Release 2 on Linu... http://oracleref.wordpress.com/2009/10/08/install...

7 of 20 21/06/2011 13:35

Page 8: Install oracle11gr2 rhel5

umask 022

# User specific environment and startup programs

export ORACLE_BASE=/u01/app/oracle

export ORACLE_HOME=$ORACLE_BASE/product/11.2.0/dbhome_1

export PATH=/usr/sbin:$PATH

export PATH=$ORACLE_HOME/bin:$PATH

export ORACLE_TERM=xterm

export LD_LIBRARY_PATH=$ORACLE_HOME/lib

export LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:/lib:/usr/lib:/usr/local/lib

export CLASSPATH=$ORACLE_HOME/JRE

export CLASSPATH=${CLASSPATH}:$ORACLE_HOME/jlib

export CLASSPATH=${CLASSPATH}:$ORACLE_HOME/rdbms/jlib

export TEMP=/tmp

export TMPDIR=/tmp

2.5 Setting Shell Limits for the Oracle User

To improve the performance of the software on Linux systems, Oraclerecommends to increase the following shell limits for the oracle user:

Shell Limit Item in limits.conf Hard Limit

Maximum number

of open file descriptors nofile 65536

Maximum number

of processes available to a single user nproc 16384

To make these changes, the following is run as root:

$ cat >> /etc/security/limits.conf <<EOF

oracle soft nproc 2047

Installing Oracle Database 11g Release 2 on Linu... http://oracleref.wordpress.com/2009/10/08/install...

8 of 20 21/06/2011 13:35

Page 9: Install oracle11gr2 rhel5

oracle hard nproc 16384

oracle soft nofile 1024

oracle hard nofile 65536

EOF

$ cat >> /etc/pam.d/login <<EOF

session required /lib/security/pam_limits.so

session required pam_limits.so

EOF

Update the default shell startup file for the “oracle” UNIX account.

For the Bourne, Bash, or Korn shell, we add the following lines to the/etc/profile file by running the following command:

cat >> /etc/profile <<EOF

if [ \$USER = "oracle" ]; then

if [ \$SHELL = "/bin/ksh" ]; then

ulimit -p 16384

ulimit -n 65536

else

ulimit -u 16384 -n 65536

fi

umask 022

fi

EOF

3. Installing Oracle Database 11g Release 2

Login as operating system user “oracle” to the Linux box. To install the Oracle

Installing Oracle Database 11g Release 2 on Linu... http://oracleref.wordpress.com/2009/10/08/install...

9 of 20 21/06/2011 13:35

Page 10: Install oracle11gr2 rhel5

Database 11gR2 software on linux, you must user the GUI installer.From OTNwebsite, we downloaded Oracle 11gR2 software:

1. Oracle Database 11g Release 2 (11.2.0.1.0) for Linux x86

linux_11gR2_database_1of2.zip (1,285,396,902 bytes)

linux_11gR2_database_2of2.zip (995,359,177 bytes)

2. Oracle Database 11gR2 Examples:

linux_11gR2_examples.zip (505,570,137 bytes)

3. Oracle De-install Utility (11.2.0.1.0) for Linux x86

linux_11gR2_deinstall.zip (124,457,540 bytes)

As the “oracle” user account, we extracted the three downloaded packages to atemporary directory.

We used “/home/oracle/wkdir/11gr2″.

$ su – oracle

$ mkdir -p /home/oracle/wkdir/11gr2

$ cd /home/oracle/wkdir/11gr2

$ unzip linux_11gR2_database_1of2.zip

$ unzip linux_11gR2_database_2of2.zip

Installing the Oracle Database 11gR2 software procedurestep-by step:

$ cd /home/oracle/wkdir/11gr2

$ cd database

$ ./runInstaller

Installing Oracle Database 11g Release 2 on Linu... http://oracleref.wordpress.com/2009/10/08/install...

10 of 20 21/06/2011 13:35

Page 11: Install oracle11gr2 rhel5

Make sure the Install database software only is selected and click Next.

Installing Oracle Database 11g Release 2 on Linu... http://oracleref.wordpress.com/2009/10/08/install...

11 of 20 21/06/2011 13:35

Page 12: Install oracle11gr2 rhel5

Make sure the Single instance database installation is selected andclick Next.

At the Language Selection screen, make sure English is on the list ofSelected Languages and click Next.

Installing Oracle Database 11g Release 2 on Linu... http://oracleref.wordpress.com/2009/10/08/install...

12 of 20 21/06/2011 13:35

Page 13: Install oracle11gr2 rhel5

Make sure the Installation Type Enterprise Edition is selected andclick Next.

Installing Oracle Database 11g Release 2 on Linu... http://oracleref.wordpress.com/2009/10/08/install...

13 of 20 21/06/2011 13:35

Page 14: Install oracle11gr2 rhel5

At the Installation Location window, make sure that the Oracle Base andOracle Home are set and click Next.

You need to specify your Inventory Directory. The location should be set to/u01/app/oraInventory. Accept the default Operating System Group Name,oinstall. Click Next.

Installing Oracle Database 11g Release 2 on Linu... http://oracleref.wordpress.com/2009/10/08/install...

14 of 20 21/06/2011 13:35

Page 15: Install oracle11gr2 rhel5

Product-specific Prerequisite Checks.

Installing Oracle Database 11g Release 2 on Linu... http://oracleref.wordpress.com/2009/10/08/install...

15 of 20 21/06/2011 13:35

Page 16: Install oracle11gr2 rhel5

At the Summary screen, review what will be installed and click Finish.

You will see the progress window.

Installing Oracle Database 11g Release 2 on Linu... http://oracleref.wordpress.com/2009/10/08/install...

16 of 20 21/06/2011 13:35

Page 17: Install oracle11gr2 rhel5

When prompted, execute /u01/app/orainstRoot.sh and /u01/app/oracle/product/11.2.0/dbhome_1/root.sh as the root user and then click Ok.

End of Installation

4. Verifying Oracle Database 11g Release 2Software Installation

To verify the Oracle Database 11gR2 software installation on Linux, open aterminal window as the user oracle, and run:

$ /u01/app/oracle/product/11.2.0/dbhome_1/oui/bin/runInstaller

Installing Oracle Database 11g Release 2 on Linu... http://oracleref.wordpress.com/2009/10/08/install...

17 of 20 21/06/2011 13:35

Page 18: Install oracle11gr2 rhel5

5. De-Installing Oracle Database 11g Release 2

With Oracle Database 11gR2, Oracle Corp. delivers a new utility namedOracle De-install Utility.

From OTN, download and unzip the following software:

Oracle De-install Utility (11.2.0.1.0) for Linux x86

linux_11gR2_deinstall.zip (124,457,540 bytes)

Its syntax is as follows:

To deinstall the Oracle Database 11gR2 software on Linux, open a terminalwindow as the user oracle, and run:

$ /home/oracle/wkdir/11gr2/deinstall/deinstall –home $ORACLE_HOME–local

Installing Oracle Database 11g Release 2 on Linu... http://oracleref.wordpress.com/2009/10/08/install...

18 of 20 21/06/2011 13:35

Page 19: Install oracle11gr2 rhel5

Like Be the first to like this post.

Notify me of follow-up comments via email.

Notify me of new posts via email.

Post CommentPost Comment

Leave a Reply

Download MonitorMonitor & block user downloads in real time.Download 30 day Trial!www.gfi.com/web-monitor

Cursos LINUX LPI - GREENModo texto/terminal, Debian, RedHat Sistemas,Redes, Samba, Firewallwww.green.com.br

Learn Languages for FreeFree Online Courses for English Spanish, French,Chinese and More!www.Livemocha.com

Enter your comment here...

Guest Log InLog In Log InLog In Log InLog In

Email (required) Your email address will not be published.

Name (required)

Website

Installing Oracle Database 11g Release 2 on Linu... http://oracleref.wordpress.com/2009/10/08/install...

19 of 20 21/06/2011 13:35

Page 20: Install oracle11gr2 rhel5

Archived Entry

Post Date :October 8, 2009 at 1:22 PMCategory :Oracle Technical ReferencesTags: 11g, 11gr2, database, install, linux, oel5, rhel5Do More :You can leave a response, or trackback from your own site.

Blog at WordPress.com. — Theme: Connections by www.vanillamist.com.

Installing Oracle Database 11g Release 2 on Linu... http://oracleref.wordpress.com/2009/10/08/install...

20 of 20 21/06/2011 13:35