View Full Version : Successfully installed Oracle 10g on Knoppix 3.4

06-06-2004, 11:26 AM
I have finally managed to get Oracle 10g RDBMS to successfully install on Knoppix 3.4(including the relinking). I have put together a short installation guide that will help make the installation a breeze.

Here ya go:
Trick oracle into thinking that we are installing oracle rdbms on a supported linux distribution:
echo "Red Hat Enterprise Linux AS release 3 (Taroon)" > /etc/redhat-release

Ensure you have swap space equal to at least twice the amount of memory.

Creating Oracle User Accounts
su - root
groupadd dba #group of users to be granted with SYSDBA privilege
groupadd oinstall # group owner of Oracle files
useradd -c "Oracle software owner" -g oinstall -G dba oracle
passwd -d /home/oracle -s /bin/bash oracle

Creating Oracle Directories
In this example, make sure that the /opt filesystem is large enough, see Oracle Disk Space for more information. If /opt is not on a separate filesystem, then make sure the root filesystem "/" has enough space.
su - root
mkdir /opt/oracle
mkdir /opt/oracle/product
mkdir /opt/oracle/product/10g
chown -R oracle.oinstall /opt/oracle

Downloading and Unpacking Oracle Software
gunzip ship.db.cpio.gz
cpio -idmv<ship.db.cpio
rm ship.db.cpio
chown -R oracle.oinstall Disk1 # cpio unzips the files into Disk1 directory

Changing System Parameters
Change kernel parameters by adding the following lines in /etc/sysctl.conf:
kernel.shmall = 2097152
kernel.shmmax = 2147483648
kernel.shmmni = 4096
kernel.sem = 250 32000 100 128
fs.file-max = 65536
net.ipv4.ip_local_port_range = 1024 65000

To make these above parameters persistent type:
sysctl -e -p /etc/sysctl.conf

Use the following commands to check the values:
/sbin/sysctl -a | grep sem
/sbin/sysctl -a | grep shm
/sbin/sysctl -a | grep file-max
/sbin/sysctl -a | grep ip_local_port_range

Add the following lines to /etc/security/limits.conf file:
* soft nproc 2047
* hard nproc 16384
* soft nofile 1024
* hard nofile 65536

Add the following line to the /etc/pam.d/login file, if it does not already exist:
session required /lib/security/pam_limits.so

Setting Oracle Environment
Set the following Oracle environment variables in oracle user ".bash_profile" script before you start runInstaller.
# Oracle Environment
export ORACLE_BASE=/opt/oracle
export ORACLE_HOME=/opt/oracle/product/10g
export ORACLE_SID=OraDb10g # Make sure you create a new Db with the same ORACLE_SID
export ORACLE_TERM=xterm
export DISPLAY=:0.0
# export TNS_ADMIN= Set if sqlnet.ora, tnsnames.ora, etc. are not in $ORACLE_HOME/network/admin
export ORA_NLS33=$ORACLE_HOME/ocommon/nls/admin/data
# Set shell search paths

Create Symbolic LInks
Run the following at the prompt:
su - root
cd /usr/lib
ln -s libstdc++-libc6.2-2.so.3 libstdc++-libc6.1-1.so.2

Setup other symbolic links by running the following at the prompt:
ln -s /usr/bin/basename /bin/basename
rm /usr/bin/gcc
ln -s /usr/bin/gcc-2.95 /usr/bin/gcc
ln -s /usr/bin/rpm /bin/rpm
ln -s /usr/bin/awk /bin/awk

Setup Display
Run the following at the prompt as the userID who is running xwindows:
xhost +

Then run the following at the prompt:
su oracle
export DISPLAY=:0.0
cd Disk1 #Or whereever the oracle software source is located

A GUI installer should popup which allows you to configure the rest of the installation.

Have fun with the installation and let me know if you encounter any problems.


06-06-2004, 01:18 PM
Thanks 4 the tutorial. :wink:

02-09-2005, 11:40 PM
great instructions! :)

worked great for me with knoppix 3.7, except for a glitch with the passwd command
in the Creating Oracle User Accounts section.
here's a useradd line that sets everything up ok, without needing to use the
passwd command (which doesn't take a directory option).

useradd -s /bin/bash -d /home/oracle -c "Oracle software owner" -g oinstall -G dba oracle

also, i noticed that because of a redhat-ism, a symlink issued by the gui installer failed.
here's the corrected command to be issued by root after the installer finishes:

ln -s /etc/init.d/init.cssd /etc/rc2.d/S96init.cssd

05-10-2005, 02:22 PM
A quick question. Has anybody thought of (or achieved) the following ? Namely a 10g DB installation against a Live Knoppix CD with (a) any mods to Knoppix or (b) installed software being written to an external disk ?

As I undestand it this would allow one to walk up to a PC, reboot with Knoppix and have a working 10g database set up automatically.

07-05-2005, 11:25 PM
For future reference, rahulreddy's notes have proven worthwile when installing to debian 3.1 (sarge) too.

A few remarks might help those attemptiing the same:

Sarge may not by default have all the packages that knoppix includes. Here are the ones I added to my base system (not entirely convinced Oracle needs all these, but this is negligible in comparison with the monster-sized software that Oracle itself is): "apt-get gcc-2.95 g++-2.95 rpm". I also suggest you "apt-get tora". Tora (http://tora.sourceforge.net/) is a nice gui database IDE.

I had to create a symbolic link from /etc/oratab to /var/opt/oracle. This is required for very useful scripts like dbstart/dbshut to work. Do not forget to replace the default N value to Y in oratab once you have created a database instance.

I know the documentation proposes the system parameter "kernel.shmmax = 2147483648" as mentioned above, but it also suggests one uses half the physical memory size in bytes. So this value seems to corresponf to the max addressable memory of 4Gb under 32 bits. I've set mine to 256000000, for my system has 512Mb.

Here's a link (http://www.oracle.com/technology/documentation/database10g.html) to more documentation than you ever wanted about Oracle 10g ;-)

In order to connect to your new database, you'll need client middleware. Oracle now has what they call an instant client (http://www.oracle.com/technology/tech/oci/instantclient/instantclient.html), which exists for windows, linux and other platforms and is relatively compact. Download at least the basic and sql*plus packages. Then the syntax to connect to oracle is slightly unusual but works fine: "sqlplus user/pass@//server.domain:1521/instance". You may also need the (small) sdk component if you intend to compile say perl or python oracle extensions.

I'll add to this note if I notice something else, but I am really happpy to have 10g running on debian rather than one of the Oracle-endorsed distros (SusSE or RHEL only).

01-20-2006, 02:02 PM
Did anyone succeeded installing Oracle XE with HTMLDB on Knoppix???

If so, please post a small how-to

There is also a similar tread on Ora Forums fyi

07-06-2006, 07:37 PM
Hey Rahul..is the steps are same for installing oracle 9i..