Daniel Calderon Mori
Daniel Calderon Mori

Reputation: 5776

Failed dependencies when installing Oracle XE to Ubuntu

I'm trying to follow the instructions in https://docs.oracle.com/cd/E17781_01/install.112/e18802/toc.htm to install Oracle XE in my Ubuntu 15 virtual machine.

But when running this command:

sudo rpm -ivh downloads/oracle-xe-11.2.0-1.0.x86_64.rpm

I get the following error:

error: Failed dependencies:
    glibc >= 2.3.4 is needed by oracle-xe-11.2.0-1.0.x86_64
    libaio >= 0.3.104 is needed by oracle-xe-11.2.0-1.0.x86_64
    /bin/sh is needed by oracle-xe-11.2.0-1.0.x86_64

I installed those 2 first packages by using:

sudo apt-get install libc6

and

sudo apt-get install libaio1

but I'm still getting that error. What am I doing wrong?

Upvotes: 2

Views: 4743

Answers (1)

Munir
Munir

Reputation: 3612

First, create a /bin/sh using ln -svf bash /bin/sh.
After that, you can follow the instructions at http://meandmyubuntulinux.blogspot.de/2012/05/installing-oracle-11g-r2-express.html

The gist of the instructions is:

unzip oracle-xe-11.2.0-1.0.x86_64.rpm.zip
sudo apt-get install alien libaio1 unixodbc
sudo alien --scripts -d oracle-xe-11.2.0-1.0.x86_64.rpm
sudo vim /sbin/chkconfig

In vim:

#!/bin/bash
# Oracle 11gR2 XE installer chkconfig hack for Ubuntu
file=/etc/init.d/oracle-xe
if [[ ! `tail -n1 $file | grep INIT` ]]; then
echo >> $file
echo '### BEGIN INIT INFO' >> $file
echo '# Provides: OracleXE' >> $file
echo '# Required-Start: $remote_fs $syslog' >> $file
echo '# Required-Stop: $remote_fs $syslog' >> $file
echo '# Default-Start: 2 3 4 5' >> $file
echo '# Default-Stop: 0 1 6' >> $file
echo '# Short-Description: Oracle 11g Express Edition' >> $file
echo '### END INIT INFO' >> $file
fi

Back in terminal:

update-rc.d oracle-xe defaults 80 01
sudo chmod 755 /sbin/chkconfig
sudo vim /etc/sysctl.d/60-oracle.conf

In vim:

# Oracle 11g XE kernel parameters  
fs.file-max=6815744  
net.ipv4.ip_local_port_range=9000 65000  
kernel.sem=250 32000 100 128 
kernel.shmmax=536870912 

In terminal:

sudo service procps start
sudo ln -s /usr/bin/awk /bin/awk 
mkdir /var/lock/subsys 
touch /var/lock/subsys/listener 

sudo dpkg --install oracle-xe_11.2.0-2_amd64.deb

The blog has the full set of instructions and requirements for running Oracle. I have only provided the ones to install Oracle XE, since the question is about installation.

Upvotes: 1

Related Questions