By: Brian E. Lavender (brian@brie.com)
July 14, 1999
Oracle Linux system requirements:
glibc 2.0.7
Minimum kernel: 2.0.34
This article is the handout I gave at my presentation describing how to install Oracle on Linux at the Sacramento Linux Users Group on Wednesday, July 14, 1999.
Download Oracle8.0.5 server (805ship.tgz) from ftp://ftp.oracle.com/pub/www/oracle8/linux/ . Do a basic system install with Debian 2.1 (SLINK). It's the one that is approximately 140 megabytes. Add the tcl8.0-dev package. If you must have XFree86 3.3.3.1 make sure you grab the packages for SLINK. See http://www.netgod.net/x/ for the packages. The Oracle tar ball 805ship.tgz contains the document 805ig.pdf in the unixdoc/server.805 directory. There is also a website describing installation of Oracle on Red Hat http://jordan.fortwayne.com/oracle/rh6x.html . This site deals with glibc 2.1 issues faced with using Red Hat 6.0. along with various issues faced here too. Debian 2.1 contains glibc 2.0.7 along with the 2.0.36 kernel, so Oracle 8.0.5 is directly compatible.
The installation process is broken into three major phases: Pre-Install, Main Install, and Post Install. For each phase, tasks are performed by root and the oracle user.
Add the group dba. Make the user oracle a member of this group
# cat /etc/group dba:x:101:oracle
Add the user oracle. His default group is dba
# cat /etc/passwd oracle:x:1001:101:Oracle User,,,:/home/oracle/product/8.0.5:/bin/bash
As the oracle user, create the following directories. The u directories are where the data files will be stored.
/home/oracle/product/8.0.5 /home/oracle/src /home/oracle/u02 /home/oracle/u03 /home/oracle/u04 /home/oracle/doc /home/oracle/product/8.0.5/doc/server.805
Copy the tar ball to /home/oracle/src. Unpack it
$ cd /home/oracle/src $ tar zxf 805ship.tgz
Set up your environment. Edit your .bash_profile for this. "Dot" it to activate it.
$ cat /home/oracle/product/8.0.5/.bash_profile umask 022 ORACLE_BASE=/home/oracle ORACLE_HOME=/home/oracle/product/8.0.5 LD_LIBRARY_PATH=/lib:/usr/lib:/usr/local/lib:/usr/X11R6/lib:$ORACLE_HOME/lib ORACLE_SID=orcl PATH=$PATH:$ORACLE_HOME/bin TMPDIR=/tmp ORACLE_TERM=vt100 SRCHOME=/home/oracle/src export ORACLE_BASE ORACLE_HOME LD_LIBRARY_PATH ORACLE_SID PATH TMPDIR export ORACLE_TERM SRCHOME $ . ./.bash_profile ^ space
Make the following changes to accommodate the Oracle Installer. Create the sym link for docs as the oracle user. This appears to be a flaw in the installer. Create the sym link for the tcl library as root.
$ cd /home/oracle/product/8.0.5/doc/server.805 $ ln -s /home/oracle/doc ./install # ln -s /usr/lib/libtcl8.0.so.1 /usr/lib/libtcl.so
Modify and run the oratab.sh script. In the script, replace the variable GROUPS with GROUPSFOO.
$ cd /home/oracle/src/orainst $ vi oratab.sh (change the variable GROUPS to GROUPSFOO) $ su (Don't use a dash here. You need to maintain the oracle user environment) # ./oratab.sh # exit
Make sure you are the oracle user, and your environment is configured as previously done in your .bash_profile. You can check your environment with the env command.
$ env (Verify proper oracle environment) $ cd /home/oracle/src/orainst $ ./orainst
The installer will proceed through a series of windows. On the window that contains the below option, select it.
(o) Default Install (o) Install, Upgrade, or DeInstall Software. "Install New Product - Create DB Objects".
Confirm that these values are set when the installer prompts you
ORACLE_BASE /home/oracle ORACLE_HOME /home/oracle/product/8.0.5 ORACLE_SID orcl
When prompted for which items to install, select everything but the Java stuff. I did not check for proper Java support, so we will leave this as an exercise for those who wish to use the Java Oracle support. Tab over to Install. Hit the space bar. A window will warn you about ULIMIT settings. Ignore this and hit ok. You can tweak it later. A window will prompt for the three database mount points.
Point 1: /home/oracle/u02 Point 2: /home/oracle/u03 Point 3: /home/oracle/u04
Documentation format
( ) HTML ( ) PDF (o) BOTH
The installer will chug away. Once it finishes it will display "Installer Actions Complete". Exit the manager. The server will have started and you will have the sample scott/tiger database installed.
As the root user
$ cd $ORACLE_HOME/orainst $ su (no dash) # root.sh [Y] Enter proper local bin [/usr/lbin] /usr/local/bin # exit
As oracle user
$ svrmgrl > connect internal > @ $ORACLE_HOME/rdbms/admin/catrep.sql > quit
You should also modify the SYS and SYSTEM user passwords. We will leave that as an user exercise.
Start the tns listener to allow for external connections.
$ lsnrctl start
You should see a bunch of stuff scroll by and it will confirm the listener started. That's it. To allow an ordinary user to connect add this to his .bash_profile
ORAENV_ASK=NO . /usr/local/bin/oraenv LD_LIBRARY_PATH=/lib:/usr/lib:/usr/local/lib:/usr/X11R6/lib:$ORACLE_HOME/lib EDITOR=emacs (or your favorite editor) export LD_LIBRARY_PATH EDITOR
As an ordinary user test your install.
$ sqlplus scott/tiger@orcl SQL> select * from tab; TNAME TABTYPE CLUSTERID ------------------------------ ------- ---------- BONUS TABLE DEPT TABLE DUMMY TABLE EMP TABLE SALGRADE TABLE