DBA Tips Archive for Oracle

  


Install Oracle9i R2 on Red Hat Linux 7.3 - 8.0

by Jeff Hunter, Sr. Database Administrator


Contents

  1. Overview
  2. Swap Space Considerations
  3. Install the Java Development Kit (JDK)
  4. Create Oracle Account and Directories
  5. Downloading / Unpacking the Oracle9i Installation Files
  6. Run the Oracle Installer
  7. Errors during the Relink Phase of the Install
  8. Configuration Files / Scripts


Overview

This article is a comprehensive guide for installing Oracle9i Release 2 on the Red Hat Linux 8.0 operating environment. Keep in mind the following assumptions throughout this article:

Swap Space Considerations

Install the Java Development Kit (JDK)

In order to use Oracle's HTTP [Apache] Server, you will need to download the appropiate SDK from Sun.

As per the JDK documentation, install JDK under /usr/local.
Then create a symbolic link to the JDK under /usr/local/java.

Create Oracle Account and Directories
Create Oracle User Account:

# groupadd -g 115 dba
# useradd -u 173 -c "Oracle Software Owner" -d /u01/app/oracle -g "dba" -m -s /bin/bash oracle
# passwd oracle

Create Oracle Directories:

# mkdir /u01
# mkdir /u01/app
# mkdir /u01/app/oracle
# mkdir /u01/app/oracle/admin
# mkdir /u01/app/oracle/admin/O920DB
# mkdir /u01/app/oracle/admin/O920DB/adhoc
# mkdir /u01/app/oracle/admin/O920DB/adump
# mkdir /u01/app/oracle/admin/O920DB/arch
# mkdir /u01/app/oracle/admin/O920DB/backups
# mkdir /u01/app/oracle/admin/O920DB/bdump
# mkdir /u01/app/oracle/admin/O920DB/cdump
# mkdir /u01/app/oracle/admin/O920DB/create
# mkdir /u01/app/oracle/admin/O920DB/dba
# mkdir /u01/app/oracle/admin/O920DB/exp
# mkdir /u01/app/oracle/admin/O920DB/logbook
# mkdir /u01/app/oracle/admin/O920DB/pfile
# mkdir /u01/app/oracle/admin/O920DB/release
# mkdir /u01/app/oracle/admin/O920DB/report
# mkdir /u01/app/oracle/admin/O920DB/tuning
# mkdir /u01/app/oracle/admin/O920DB/udump
# mkdir /u01/app/oracle/product
# chown -R oracle:dba /u01/app/oracle

# mkdir /u03
# mkdir /u03/app
# mkdir /u03/app/oradata
# mkdir /u03/app/oradata/O920DB
# chown -R oracle:dba /u03/app/oradata

# mkdir /u04
# mkdir /u04/app
# mkdir /u04/app/oradata
# mkdir /u04/app/oradata/O920DB
# chown -R oracle:dba /u04/app/oradata

# mkdir /u05
# mkdir /u05/app
# mkdir /u05/app/oradata
# mkdir /u05/app/oradata/O920DB
# chown -R oracle:dba /u05/app/oradata

# mkdir /u06
# mkdir /u06/app
# mkdir /u06/app/oradata
# mkdir /u06/app/oradata/O920DB
# chown -R oracle:dba /u06/app/oradata

# mkdir /u07
# mkdir /u07/app
# mkdir /u07/app/oradata
# mkdir /u07/app/oradata/O920DB
# chown -R oracle:dba /u07/app/oradata

# mkdir /u08
# mkdir /u08/app
# mkdir /u08/app/oradata
# mkdir /u08/app/oradata/O920DB
# chown -R oracle:dba /u08/app/oradata

# mkdir /u09
# mkdir /u09/app
# mkdir /u09/app/oradata
# mkdir /u09/app/oradata/O920DB
# chown -R oracle:dba /u09/app/oradata

# mkdir /u10
# mkdir /u10/app
# mkdir /u10/app/oradata
# mkdir /u10/app/oradata/O920DB
# chown -R oracle:dba /u10/app/oradata

# mkdir /opt/bin
# chown oracle:dba /opt/bin

Oracle Environment Variable Settings:

An example ".bash_profile" is provided in the Configuration Files / Scripts section below.

Ensure to set the environment variable: LD_ASSUME_KERNEL=2.2.5

NOTE: Failing to set the LD_ASSUME_KERNEL parameter will cause the Oracle Universal Installer to hang!

Downloading / Unpacking the Oracle9i Installation Files

Run the Oracle Installer

As the "oracle" user account:

Errors during the Relink Phase of the Install
During the "Link Phase" of the install, you will get an error while trying to make/install CTX. (The same issue exists in 9.0.1 on Red Hat Linux).

The following errors will exist in $ORACLE_HOME/install/make.log

/lib/libdl.so.2: undefined reference to `__ctype_b_loc@GLIBC_2.3'
/lib/libdl.so.2: undefined reference to `_dl_addr@GLIBC_PRIVATE'
/lib/libdl.so.2: undefined reference to `_dl_open@GLIBC_PRIVATE'
/lib/libdl.so.2: undefined reference to `_dl_close@GLIBC_PRIVATE'
/lib/libdl.so.2: undefined reference to `_dl_sym@GLIBC_PRIVATE'
/lib/libdl.so.2: undefined reference to `_dl_vsym@GLIBC_PRIVATE'
collect2: ld returned 1 exit status
make: *** [ctxhx] Error 1

This error occurs when the following is executed:

/usr/bin/make -f ins_ctx.mk install ORACLE_HOME=/u01/app/oracle/product/9.2.0

Solution

The solution is to edit the file $ORACLE_HOME/ctx/lib/env_ctx.mk and go to "INSO_LINK =", add a "$(LDLIBFLAG)dl" to the line and save it.

Here is the full line with the added "$(LDLIBFLAG)dl" flag:

INSO_LINK = -L$(CTXLIB) $(LDLIBFLAG)m $(LDLIBFLAG)dl $(LDLIBFLAG)sc_ca $(LDLIBFLAG)sc_fa $(LDLIBFLAG)sc_ex $(LDLIBFLAG)sc_da $(LDLIBFLAG)sc_ut $(LDLIBFLAG)sc_ch $(LDLIBFLAG)sc_fi $(LLIBCTXHX) $(LDLIBFLAG)c -Wl,-rpath,$(CTXHOME)lib $(CORELIBS) $(COMPEOBJS)

Set LD_ASSUME_KERNEL

You will also need to enter LD_ASSUME_KERNEL=2.2.5 in your .profile (or .bash_profile if you are using BASH) for the "oracle" user account so that they you can run programs like "dbssist" and "netca".

Return and Retry

After making the above change, return to the popup error dialog box and hit "Retry". It should continue from here with no errors.

Configuration Files / Scripts
Example:
    .bash_profile
$HOME/.bash_profile for the "oracle" user account.
    initO920DB.ora
Sample instance parameter script for Oracle9i. Place this file in ~oracle/admin/O920DB/pfile before running the RUN_CRDB.sh script below.
    create_database920.tar
An example "create database" set of scripts. Untar the file to ~oracle/admin/O920DB/create. If you decide to change the name of the ORACLE_SID, here are the files that need to be changed:
  • crdb.sh
  • create_database.sql
The main script to run is: RUN_CRDB.sh.


Copyright (c) 1998-2014 Jeffrey M. Hunter. All rights reserved.

All articles, scripts and material located at the Internet address of http://www.idevelopment.info is the copyright of Jeffrey M. Hunter and is protected under copyright laws of the United States. This document may not be hosted on any other site without my express, prior, written permission. Application to host any of the material elsewhere can be made by contacting me at jhunter@idevelopment.info.

I have made every effort and taken great care in making sure that the material included on my web site is technically accurate, but I disclaim any and all responsibility for any loss, damage or destruction of data or any other property which may arise from relying on it. I will in no case be liable for any monetary damages arising from such loss, damage or destruction.

Last modified on
Monday, 02-Jan-2012 15:09:26 EST
Page Count: 26485