Note: Installing Oracle 11gR1 on Ubuntu 8.10 Intrepid Ibex is now published.
Note: I have now published “Installing Oracle 11g on Ubuntu Linux 7.10 (Gutsy Gibbon)”
Note: This page focuses on Ubuntu installs. Oracle has published a web page for successfully installing Linux on unsupported platforms that you may find helpful.
I come from a MySQL background, and I have been given the challenge of learning Oracle. I can’t just play around with our customers’ databases, but I remembered that Paul Vallée said that there is nothing wrong with learning on company time. So I decided to install my own Oracle database, which I’ll be free to destroy in every way I can think of… and of course, free to bring it back to life. Recovering from crashes will probably be the most difficult part of my adventures in the Oracle world, but let’s take one step at a time, shall we?
Now, onto Oracle 11g (beta 5) on Ubuntu 7.04 (Feisty Fawn). One little issue is that Ubuntu is unsupported by Oracle. So, through this text, we will trick the Oracle installer into thinking it’s actually running on a Red Hat box.
Step Zero
This tutorial was based on a document which can be found here. I have adapted it for Oracle 11g.
Get a copy of Ubuntu 7.04 and install on a machine. I’m using the 32-bit version here (as well as for Oracle). Next, make sure your system is up-to-date. A simple apt-get update
followed by a apt-get upgrade
will do the trick, although you may prefer using the GUI Synaptic Package Manager — it’s entirely up to you what method you choose. However, I much prefer to use the command line.
As you go through updates, sometimes a reboot will be needed (usually to boot from a newer, recently-updated kernel). Sometimes it’ll just ask you to restart your web browser or some other program as a new version is installed.
It’s important to have a few gigabytes of free disk space and a total of 1 GB of memory before starting this. This 1 GB of memory can be RAM alone or the combination of RAM and swap space. Of course, since everything runs faster when in RAM, the more of it, the better.
Very important: get Java running before trying to move on. My guess is that almost any JRE (java runtime) or JDK (java development kit) will work. I’m not sure which is the minimum version required: I used Sun JDK 1.5.
Step One
Install some system requirements. There are a few packages that I had to install on this box (it was a recently installed system which didn’t have all these packages). After several attempts of installing Oracle, the equivalent command-line for installing all the necessary packages at once was something like this:
# apt-get install gcc make binutils lesstif2 libc6 libc6-dev rpm libmotif3 libaio libstdc++5 gawk alien libg++2.8.1.3-glibc2.2 ksh gcc-3.3 g++-3.3 libstdc++5
It’s possible that when installing the packages mentioned above, the installer will install some other prerequisites as well, as these packages themselves may have prerequisites.
Step Two
Choose where you are going to install your Oracle 11g server and create the ORACLE_BASE
directory. This is the place where Oracle will be installed. Make sure there is at least 3 GB on the partition/mount point before moving to the next step. After installed, my basic installation took about 3.4 GB on disk (without the starter database!). As your database grows, it will need more space. Reserve a total of at least 6 GB for the unpacked installer and the basic installation. You can get rid of the installer files afterwards.
# mkdir -p /u01/app/oracle
Step Three
Add a few users and change groups to make the installer more comfortable. Remember, we are tricking the installer to think it’s installing on a Red Hat box.
# addgroup oinstall # addgroup dba # addgroup nobody # useradd -g oinstall -G dba -p password -d /home/oracle -s /bin/bash oracle # usermod -g nobody nobody
The usermod
command is needed since because when running, the installer looks for a user called nobody
which is part of a group named nobody
(in Ubuntu, the user nobody
it’s assigned to nogroup
by default).
Step Four
Make some symlinks. Apparently, the installer uses absolute paths, so it must find the binaries in the right places.
# ln -s /usr/bin/awk /bin/awk # ln -s /usr/bin/rpm /bin/rpm # ln -s /usr/bin/basename /bin/basename
Step Five
We need to mimic the /etc/rc.d
directory structure of a Red Hat box. We do this with more symlinks:
# mkdir /etc/rc.d # ln -s /etc/rc0.d /etc/rc.d/rc0.d # ln -s /etc/rc2.d /etc/rc.d/rc2.d # ln -s /etc/rc3.d /etc/rc.d/rc3.d # ln -s /etc/rc4.d /etc/rc.d/rc4.d # ln -s /etc/rc5.d /etc/rc.d/rc5.d # ln -s /etc/rc6.d /etc/rc.d/rc6.d # ln -s /etc/init.d /etc/rc.d/init.d
Step Six
I’ve created a file called /etc/redhat-release
and put only one line on it. The same can be achieved by issuing the following as root:
echo "Red Hat Linux release 4" > /etc/redhat-release
Step Seven
We tweak the system default limits on a few items. The shared-memory are specially important, since Oracle relies on shared memory for process communications. There is a file called /etc/sysctl.conf
and it should have these lines on it:
fs.file-max = 65535 kernel.shmall = 2097152 kernel.shmmax = 2147483648 kernel.shmmni = 4096 kernel.sem = 250 32000 100 128 net.ipv4.ip_local_port_range = 1024 65000 net.core.rmem_default = 1048576 net.core.rmem_max = 1048576 net.core.wmem_default = 262144 net.core.wmem_max = 262144
Now that they are in a config file, these limits will be issued automatically at the next boot sequence. For now, we need to make the system re-read the config file:
# sysctl -p
Now, what do those parameters and values actually mean?
fs.file-max
sets the maximum number of open files that can be handled by the Linux kernel.kernel.shmall
determines the total amount of shared memory to be allocated in pages. In this example, I’ve set it to 8GB, which is way above the amount of memory I can handle in my box, even with swap.kernel.shmmax
controls the maximum amount of memory to be allocated for shared memory which in this example is 2GB.kernel.shmmni
defines the maximum number of segments system-wide.net.core.rmem_default
andnet.core.rmem_max
define the default and maximum read buffer queue for network operations (1 MB in this example)net.core.wmem_default
andnet.core.wmem_max
define the default and maximum write buffer queue for network operations (256 KB in this example)net.ipv4.ip_local_port_range
tells the kernel the port ranges that will be used for outbound connections.kernel.sem
has four parameters:SEMMSL
– semaphores per arraySEMMNS
– max semaphores system-wide (SEMMNI*SEMMSL
)SEMOPM
– max operations per semop callSEMMNI
– max number of semaphore arrays
To check your current semaphores configuration, you can run cat /proc/sys/kernel/sem
or ipcs -ls
. On my machine, after the modifications on sysctl.conf
, these commands output:
# cat /proc/sys/kernel/sem 250 32000 100 128 # ipcs -ls ------ Semaphore Limits -------- max number of arrays = 128 max semaphores per array = 250 max semaphores system wide = 32000 max ops per semop call = 100 semaphore max value = 32767
(I really don’t know if these are enough or too much, but I’ll keep you posted.)
For a better understanding of these kernel-tweaking settings, I’d recommend these resources:
- schogini.us/wordpress/index.php/2005/11/01/setting-semaphores/
- performancewiki.com/linux-tuning.html
- pythian.com/blogs/245/the-mysterious-world-of-shmmax-and-shmall
Step Eight
Add these lines to /etc/security/limits.conf
, letting the oracle
user use more resources than the defaults allowed. You may notice that all these values are a power of 2 minus one. When soft limits are exceeded, you’ll get a warning; the hard limits can’t be exceeded in any situation: you’ll get an error. I’m not completely sure, but I think these limits apply to each session/login (and since Oracle doesn’t exactly log in to the machine, my best guess is these limits apply per instance running).
oracle soft nproc 2047 oracle hard nproc 16383 oracle soft nofile 1023 oracle hard nofile 65535
Step Nine
Make sure the limits.conf
is being interpreted as the oracle
user logs in by adding these lines to /etc/pam.d/login
. You will want to make sure that is actually happening, since the defaults are way lower and you may get all sorts of problems.
session required /lib/security/pam_limits.so session required pam_limits.so
Step Ten
Unpack and prepare the installation.
# cd /path/to/zipfile # unzip linux_11gR1b5_database.zip
(And wait… wait a bit more… go get a cup of coffee…)
After your second cup of coffee, you should have a multi-gigabyte set of files; this is our installer.
# chown -R oracle:oinstall database # chown -R oracle:oinstall /u01/app/oracle
Step Eleven
Fire up the installer as the oracle
user itself. This is what you will probably see on the output window:
# su - oracle $ cd /path/to/extracted/zip/file $ ./runInstaller Starting Oracle Universal Installer... Checking Temp space: must be greater than 80 MB. Actual 58633 MB Passed Checking swap space: must be greater than 150 MB. Actual 2900 MB Passed Checking monitor: must be configured to display at least 256 colors. Actual 16777216 Passed Preparing to launch Oracle Universal Installer from /tmp/OraInstall2007-07-11_04-38-56PM. Please wait ... Oracle Universal Installer, Version 11.1.0.2.0 Production Copyright (C) 1999, 2007, Oracle. All rights reserved. ulimit: 1: Illegal option -u ulimit: 1: Illegal option -u rpm: To install rpm packages on Debian systems, use alien. See README.Debian. error: cannot open Packages index using db3 - No such file or directory (2) error: cannot open Packages database in /var/lib/rpm rpm: To install rpm packages on Debian systems, use alien. See README.Debian. error: cannot open Packages index using db3 - No such file or directory (2) error: cannot open Packages database in /var/lib/rpm
There are a few errors that can be safely ignored: the ulimit
and the RPM-related errors, since the limits don’t restrict the installer and since we actually don’t have a RPM database on the machine — we are running on Ubuntu, remember?
After a few moments, you will be prompted to choose where to install the Oracle server. You’ll notice that I asked the installer to not create a starter database — I did that later. Choose the Oracle Base and correct the group if needed. I personally recommend sticking with the defaults if you are a newbie like me.
As you press the Next button, you will be prompted where to install the Inventory — leave it that way unless you know what you are doing (if this were the case, you wouldn’t be reading this text anyways). Also correct the OS group name if needed and hit Next.
Since I’ve chosen to install the server in the same directory as the oracle
user’s HOME
directory, the installer will issue a warning. I simply ignored it and continued with the installation.
After that warning, I tried to perform some prerequisite tests, and yes — some will fail. Just mark the failed boxes and hit Next (after trying a few times to fix those issues, I’ve decided to call the installer’s bluff and… it worked!)
After all this warning stuff, it’ll ask you to check the list of products to be installed. I was amazed when I read that 122 different products would be installed on my box. Hit Next.
Go get some coffee.
And some more coffee.
And even more coffee.
You may like to go to the washroom after so much time drinking coffee. Remember: I was installing on a 3 GHz machine with 1 GiB of RAM with SATA2 disks — this box is supposed be blazing fast.
At some point, it will ask you to run some commands as root
. Do that when it asks, since the install depends on a few modifications on the base system (like creating the /etc/oratab
file).
$ sudo -s Password: # /u01/app/oracle/oraInventory/orainstRoot.sh Changing permissions of /u01/app/oracle/oraInventory to 770. Changing groupname of /u01/app/oracle/oraInventory to oinstall. The execution of the script is complete # /u01/app/oracle/product/11.1.0/db_1/root.sh Running Oracle 11g root.sh script... The following environment variables are set as: ORACLE_OWNER= oracle ORACLE_HOME= /u01/app/oracle/product/11.1.0/db_1 [: 185: ==: unexpected operator [: 189: ==: unexpected operator Copying dbhome to /usr/local/bin ... Copying oraenv to /usr/local/bin ... Copying coraenv to /usr/local/bin ... Creating /etc/oratab file... Entries will be added to the /etc/oratab file as needed by Database Configuration Assistant when a database is created Finished running generic part of root.sh script. Now product-specific root actions will be performed. Finished product-specific root actions.
After these scripts finish their execution (the errors seem to be ignorable), hit the OK button and you’ll have a window that (probably) will look like this one:
Just hit OK to get out the installer. The basic installation is… not over yet.
To allow Oracle start on boot-up, create a file called oracledb
(or whatever name you want to call it) and put it in /etc/init.d
with the contents below. This script was copied and pasted from a tutorial by Graham Williams. It will read the /etc/oratab
and fire up any instances it finds.
#!/bin/bash # # /etc/init.d/oracledb # # Run-level Startup script for the Oracle Instance, Listener, and Web Interface export ORACLE_HOME=/u01/app/oracle export PATH=$PATH:$ORACLE_HOME/bin ORA_OWNR="oracle" # if the executables do not exist -- display error if [ ! -f $ORACLE_HOME/bin/dbstart -o ! -d $ORACLE_HOME ] then echo "Oracle startup: cannot start" exit 1 fi # depending on parameter -- startup, shutdown, restart # of the instance and listener or usage display case "$1" in start) # Oracle listener and instance startup echo -n "Starting Oracle: " su $ORA_OWNR -c "$ORACLE_HOME/bin/lsnrctl start" su $ORA_OWNR -c $ORACLE_HOME/bin/dbstart touch /var/lock/oracle su $ORA_OWNR -c "$ORACLE_HOME/bin/emctl start dbconsole" echo "OK" ;; stop) # Oracle listener and instance shutdown echo -n "Shutdown Oracle: " su $ORA_OWNR -c "$ORACLE_HOME/bin/lsnrctl stop" su $ORA_OWNR -c $ORACLE_HOME/bin/dbshut rm -f /var/lock/oracle su $ORA_OWNR -c "$ORACLE_HOME/bin/emctl stop dbconsole" echo "OK" ;; reload|restart) $0 stop $0 start ;; *) echo "Usage: `basename $0` start|stop|restart|reload" exit 1 esac exit 0
After saving the file, make it executable
# chmod a+x /etc/init.d/oracledb
and if you want, make it run at every boot:
# update-rc.d oracledb defaults 99 Adding system startup for /etc/init.d/oracledb ... /etc/rc0.d/K99oracledb -> ../init.d/oracledb /etc/rc1.d/K99oracledb -> ../init.d/oracledb /etc/rc6.d/K99oracledb -> ../init.d/oracledb /etc/rc2.d/S99oracledb -> ../init.d/oracledb /etc/rc3.d/S99oracledb -> ../init.d/oracledb /etc/rc4.d/S99oracledb -> ../init.d/oracledb /etc/rc5.d/S99oracledb -> ../init.d/oracledb
Before finishing, add the following lines to your /etc/profile
. Be careful, since these values are valid system-wide. So make sure the paths are set according to your particular setup (if you have been doing everything according to this text, you should be fine).
export ORACLE_BASE=/u01/app/oracle export ORACLE_HOME=/u01/app/oracle/product/11.1.0/db_1 export ORACLE_SID=ORCL export PATH=$PATH:/u01/app/oracle/product/11.1.0/db_1/bin
Last operation: add yourself to the dba
group. You can use usermod
or just edit the /etc/groups
file and add your username at the end of the line that starts with dba
(my username is ‘bott’):
dba:x:1002:oracle,bott
If you chose to not create a starter database during your install, you’ll have to do two extra steps. You should create a listener (with netca
) and after that, create the starter database (also with netca
). If you chose to have the installer create a database for you, then you should be fine, since when doing that, it asks for a password for the default accounts (SYS
, SYSTEM
, and DBSNMP
, SYSMAN
if you choose to install it with the enterprise manager option selected).
If everything has gone well, open a terminal window and, as the oracle
user, type:
$ sqlplus SQL*Plus: Release 11.1.0.5.0 - Beta on Wed Jul 11 17:11:53 2007 Copyright (c) 1982, 2007, Oracle. All rights reserved. Enter user-name:
If you see these messages (and I sincerely hope you do) you’re all set! That means that you have finished a quite long install of Oracle 11g and you are ready to begin destroying it, just as I plan to as I take my first steps with Oracle. Some might say that going from Oracle to MySQL would make for an easier transition — I really don’t know, but I will post further entries on my experiences as I go.
Anyway, I would greatly appreciate your feedback, especially if we can improve this tutorial so that more people can benefit from it.
So now, dear reader, we hope we have helped you figure out something you needed to know. It turns out that you can help us here at Pythian with something we need to know! If you are aware of a DBA requirement within your organization, salaried or consulting, please pop in your email address here:
We respect your privacy and will not share your address with any third party. As a thank you for just participating, we will enter you into a monthly draw for a year’s membership in the ACM, which includes access to 600 books from the O’Reilly Bookshelf Online, 500 books from Books24x7 and 3000 online courses from SkillSoft, including tons of courseware on Oracle, SQL Server, and MySQL.
Augusto Bott.
68 Comments. Leave new
Great job Augusto. I am now very tempted to destroy my Enterprise Linux 5 setup again and go afterall with Ubuntu. One of the reasons is that Ubuntu probably gives me a better desktop experience (and hopefully WPA wireless access) and better community support. As said. Thank you very much for sharing !
[…] 1st, 2007 I didn’t install Oracle 11g. Augusto Bott over at Pythian group installed 11g on Ubuntu, which is really cool considering how Ubuntu is not officially supported and all. What’s the […]
[…] Augusto Bott of Pythian Group Blog on Installing Oracle 11g on Ubuntu Linux 7.04 […]
Great tutorial Augusto,
Especially nice was the script you included to autostart the DB and listeners. That is what usually trips folks up when installing Oracle DB.
Great instructions! I was successful after getting all of the packages installed correctly.
I would recommend running apt-get one at a time to make sure.
lesstif2 wouldn’t update or is no longer available but that didn’t seem to matter.
Just wanted to get my hands on the newly released copy of 11g and I had an Ubuntu desktop handy.
April Sims
OCP 8i/9i/10g Database Administrator
Very good text…
Than’s my friend
I install here oracle 11g for ubuntu 7.04
16/08/2007
Marcio Novelli
system analyst
MarÃlia – S.P
Brazil
Hi,
I believe that on step seven these
net.core.rmem_default = 1048576
net.core.rmem_max = 1048576
net.core.wmem_default = 262144
net.core.wmem_max = 262144
are not correct values. according to the Oracle11g documentation they should be more like
See; 2.7 Configuring Kernel Parameters
rmem_default 4194304
rmem_max 4194304
wmem_default 262144
wmem_max 262144
https://download.oracle.com/docs/cd/B28359_01/install.111/b32002/toc.htm
@Kari,
You are probably right – thanks for the input. This text was written before the ‘official’ documents were released and were based on other howtos and your input made me wonder: why Oracle would raise their recommended default OS receive buffer size from 1M to 4M?
Anyway… thanks again.
Sir,
As per your instructions I tried to intall ORACLE 11g on my UBUNTU system which is Ubuntu 6.06 LTS Desktop Edition.
I reached till step 11. But after running the script runInstaller of ORACLE 11g the intallation gets stuck at 17%. I’m getting the same errors as you repoerted like to install rpm package use alien, cannot open package database in /var/lib/rpm etc.
Could you please help me out.
One more thing whenever I work in oracle user mode I’ve to set DISPLAY variable.
@Anurag,
I haven’t really tried it with 6.06 LTS, so your input is welcome. Is there any disk activity when it seems stuck on the 17%? Did you check if you’re hitting swap on your machine (so the installation seems stuck but instead is trying to free up some RAM to move on?). The DISPLAY variable should be carried on if you ‘sudo -s’ (from your ‘regular user’). The dash sign on the ‘su -‘ command means it’ll force the command interpreter to re-read the environment variables (I had to set DISPLAY anyway since I was installing on a remote machine). See the following example on the behaviour of the ‘-‘ parameter for ‘su’:
[email protected]:~$ echo $DISPLAY
:0.0
[email protected]:~$ sudo -s
Password:
[email protected]:/home/bott$ echo $DISPLAY
:0.0
[email protected]:~# su – oracle
[email protected]:~$ echo $DISPLAY
[email protected]:~$ exit
exit
[email protected]:~# su oracle
[email protected]:/home/bott$ echo $DISPLAY
:0.0
I don’t know what is happening. Coz when I tried to install 11g without the starter database the setup was stuck at 21%.
The display variable is quite correct as per your instruction. There is no other disk activity apart from OUI.
Regarding SWAP how can I check it. When I tried to install it second time I left OUI to do its work whole night ( 7hours ).
My system conf is: Intel 865GBF motherboard, two 80-80 GB ATA harddisks, 512+256 RAM DDR1, P-4 with HT 2.9GHz
I forgot to mention about swap space. It is 1GB.
@Anurag,
I don’t think I’m following what you mean – so I believe it’s best to give you some pointers/clues to check what can be happening. The installation gets stuck at 17% or at 22%? How can you tell the difference on disk activity between the Oracle installer or anything else? Have you checked ‘top’, ‘iostat’ or ‘sar’ (on package ‘sysstat’)? The machine I was working on had 1 GiB of RAM and if touched the swap space, was just a little bit… My best idea so far would be investigating a bit further with the tools I’ve mentioned.
Anyways – good luck!
Couple of days back I installed my first Linux (Ubuntu 7.04). Today i began Oracle 11g installation using procedure documented by you. Thank you.
I encountered a couple of problems while implementing Step 7.
command “sysctl.conf -p” didn’t work until i specified the full path of the file. Current active directory is ‘/etc’. Not specifying the complete path causes the following error to be generated “bash: sysctl.conf: command not found”.
Secondly, attempt to re-read the file failed producing the following errors.
/etc/sysctl.conf: line 28: fs.file-max: command not found
/etc/sysctl.conf: line 29: kernel.shmall: command not found
/etc/sysctl.conf: line 30: kernel.shmmax: command not found
/etc/sysctl.conf: line 31: kernel.shmmni: command not found
/etc/sysctl.conf: line 32: kernel.sem: command not found
/etc/sysctl.conf: line 33: net.ipv4.ip_local_port_range: command not found
/etc/sysctl.conf: line 34: net.core.rmem_default: command not found
/etc/sysctl.conf: line 35: net.core.rmem_max: command not found
/etc/sysctl.conf: line 36: net.core.wmem_default: command not found
/etc/sysctl.conf: line 37: net.core.wmem_max: command not found
When i look under \proc\sys\ directory i see the files mentioned in the above commands. I’m not sure if the two are related.
What should i do to get past this problem? If you deal strictly with Oracle and not configuration, can you please direct me to a website where i can find help.
Ami i missing an entry in the “system path” environment variable or something?
Thanks Again.
WindowsGuy,
use “sysctl -p” instead (not “sysctl.conf”)
Thank Alex. That worked. I didn’t realize suppressing file extension is mandatory.
Hi,
When i try to run installer (step 11), i get the following message ….
Can you please help me out?
>>
Starting Oracle Universal Installer…
Checking Temp space: must be greater than 80 MB. Actual 100126 MB Passed
Checking swap space: must be greater than 150 MB. Actual 3812 MB Passed
Checking monitor: must be configured to display at least 256 colors
>>> Could not execute auto check for display colors using command /usr/X11R6/bin/xdpyinfo. Check if the DISPLAY variable is set. Failed
Step 11.
For some reason “su – oracle” doesn’t carry over the $DISPLAY settings.
I had to run the following command from the extracted directory.
sudo -u oracle ./runInstaller
WindowsGuy,
“I didn’t realize suppressing file extension is mandatory.”
“Suppressing” file extension is mandatory to call the right thing, yes :)
[[email protected] ~]# whereis sysctl
sysctl: /sbin/sysctl /etc/sysctl.conf /usr/share/man/man2/sysctl.2.gz /usr/share/man/man8/sysctl.8.gz
[…] stated on my first post on this blog, I’m a MySQL DBA trying to draw a map of this new (to me) world called Oracle. […]
[…] For reference, see also Augusto’s item, Installing Oracle 11g on Ubuntu Linux 7.04. Bookmark online using:These icons link to social bookmarking sites where readers can share and […]
I have ubuntu 7.0.4 installed with following packages. I am installing oracle 11g one of the requirement is I need to have package glibc-2.3.4-2.19 or higher. Can some one guide me how I can install this package? or any workaround for this?
Error during oracle Installation:
Checking Recommended glibc version
Expected result: ATLEAST=2.3.4-2.19
Actual Result: package glibc is not installed
I do not have yum repogitory configured.
# apt-get install glibc-2.3.4-2.19
Reading package lists… Done
Building dependency tree
Reading state information… Done
E: Couldn’t find package glibc-2.3.4-2.19
#apt-get install gcc make binutils lesstif2 libc6 libc6-dev rpm libmotif3 libaio libstdc++5 gawk alien libg++2.8.1.3-glibc2.2 ksh gcc-3.3 g++-3.3 libstdc++5
Reading package lists… Done
Building dependency tree
Reading state information… Done
gcc is already the newest version.
make is already the newest version.
binutils is already the newest version.
lesstif2 is already the newest version.
libc6 is already the newest version.
libc6-dev is already the newest version.
rpm is already the newest version.
libmotif3 is already the newest version.
Note, selecting libaio1 instead of libaio
libaio1 is already the newest version.
libstdc++5 is already the newest version.
gawk is already the newest version.
alien is already the newest version.
libg++2.8.1.3-glibc2.2 is already the newest version.
ksh is already the newest version.
gcc-3.3 is already the newest version.
g++-3.3 is already the newest version.
libstdc++5 is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 3 not upgraded.
[email protected]:/home/pbandaru# apt-get install gibg++2.8.1.3-glibc2.4
Reading package lists… Done
Building dependency tree
Reading state information… Done
E: Couldn’t find package libg++2.8.1.3-glibc2.4
[email protected]:/home/pbandaru#
#/home/pbandaru# uname -a
Linux 2.6.20-15-generic #2 SMP Sun Apr 15 07:36:31 UTC 2007 i686 GNU/Linux
Appreciate your immediate response.
-Prakash
@Prakash,
Checked on my box (which runs Feisty):
[email protected]:~$ dpkg –list | grep -i libc6
ii libc6 2.5-0ubuntu14 GNU C Library: Shared libraries
ii libc6-dev 2.5-0ubuntu14 GNU C Library: Development Libraries and Hea
ii libc6-i686 2.5-0ubuntu14 GNU C Library: Shared libraries [i686 optimized]
I’m sure you probably already have it – just make sure you have the ‘dev’ lib also (if I’m not mistaken Oracle needs to build and link some runtime libs).
Cheers!
Hi. I’m trying to install Oracle 10g on ubuntu Feisty Fawn. When I try to run runInstaller. I get the following error
.oui not found
any ideas why?
@Bo,
It seems the installer is complaining about not finding
oui
(Oracle Universal Installer). That’s odd – as far as I know, the Oracle Installer ships its own Java Virtual Machine on the installation package. I’ve done some browsing around and found references to possible incorrect session variables, possible left overs from another misconfigured JVM. Try listing the session variables on your system withenv
and perhaps getting rid of any suspicious variables/values withunset
.Cheers!
Hi, I also got the .out not found — then I realized that I had inadvertently d/l the x86 version and I’m on an x64 arch.
$ file /install/.out
indicated this is an ELF 32-bit LSB executable…when you try to run this on x64, it just says “file not found”.
I just checked Oracle’s site, and there is no download for x64 11g (yet), so I’m stuck with 10gR2 for now.
@davis,
I really haven’ tried that, but you may want to try installing 32 bit libraries with
sudo apt-get install linux32 ia32*
. As far as I know, that’s the way to go with many 32 bit applications in a 64 bit Ubuntu. Let us know the outcome and good luck!The install goes fine until the Linking phase when it tells me that all this stuff can’t be found or linked.
During the Pre-requisite check, it is telling me I don’t have glibc installed as well.
Error message:
—
Checking Recommended glibc version
Expected result: ATLEAST=2.3.4-2.19
Actual Result: package glibc is not installed
—
seems I should have it just fine
—
[email protected]:/home/oracle# dpkg –list | grep -i libc6
ii libc6 2.5-0ubuntu14 GNU C Library: Shared libraries
ii libc6-dev 2.5-0ubuntu14 GNU C Library: Development Libraries and Header Files
ii libc6-i386 2.5-0ubuntu14 GNU C Library: 32bit shared libraries for AMD64
—
I couldn’t find that package you listed:
—
[email protected]:/home/oracle# apt-get install libg++2.8.1.3-glibc2.2
Reading package lists… Done
Building dependency tree
Reading state information… Done
E: Couldn’t find package libg++2.8.1.3-glibc2.2
—
@Ryan,
You shall be safe ignoring the prerequisite check on glibc (since you already checked and have a suitable version). Just mark the checkbox on that step of the installation (that’s what I did). Regarding libg++2.8.1.3-glibc2.2, make sure you have the ‘universe’ repository enabled (after uncommenting the repository, make sure you run
sudo apt-get update
).Good luck!
Here are my sources:
deb https://us.archive.ubuntu.com/ubuntu/ feisty main restricted
deb-src https://us.archive.ubuntu.com/ubuntu/ feisty main restricted
deb https://us.archive.ubuntu.com/ubuntu/ feisty-updates main restricted
deb-src https://us.archive.ubuntu.com/ubuntu/ feisty-updates main restricted
deb https://us.archive.ubuntu.com/ubuntu/ feisty universe
deb-src https://us.archive.ubuntu.com/ubuntu/ feisty universe
deb https://us.archive.ubuntu.com/ubuntu/ feisty multiverse
deb-src https://us.archive.ubuntu.com/ubuntu/ feisty multiverse
deb https://us.archive.ubuntu.com/ubuntu/ feisty-backports main restricted universe multiverse
deb-src https://us.archive.ubuntu.com/ubuntu/ feisty-backports main restricted universe multiverse
deb https://security.ubuntu.com/ubuntu feisty-security main restricted
deb-src https://security.ubuntu.com/ubuntu feisty-security main restricted
deb https://security.ubuntu.com/ubuntu feisty-security universe
deb-src https://security.ubuntu.com/ubuntu feisty-security universe
deb https://security.ubuntu.com/ubuntu feisty-security multiverse
deb-src https://security.ubuntu.com/ubuntu feisty-security multiverse
deb https://packages.medibuntu.org/ feisty free non-free
deb-src https://medibuntu.sos-sts.com/repo/ feisty free non-free
deb https://archive.canonical.com/ubuntu feisty-commercial mai
Mr. Bott,
great work! Especially the depencies, you must have spent some time figuring that out I guess.
I just followed your guidelines to install it on a laptop with only 750 MB of ram, running an ubuntu 7.10 and apart from some minor details (which I hardly dare to mention below) it worked great.
Comments:
Step 11:
– /etc/group (not : /etc/groups)
-When not choosen to create a db during install, it must be dbca (not netca, which is for the listener setup) to create a new instance
My experience:
listener did not start after setup with netca, it complained that the port was already in use, which wasn’t the case.
Manually edited the $ORACLE_HOME/network/admin/listener.ora which had the hostname missing (wild guess is that netca might have had a problem with figuring out the hostname or ip, not sure), any how with a listener.ora like this, it works (of course the db is only accesable from localhost, which for a production db would not make much sense):
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST=localhost)(PORT = 1521))
)
)
@Ryan,
That’s curious. You seem to have the proper sources configured. Anyway, I’m working on a new version of this howto for Gutsy (7.10). It should be published soon.
@gdq,
Thanks for your feedback! Comments like yours give us the strength to move on, trying to improve our own work. As mentioned on the other comment, I’m working on a new version of this document and your input is more than welcome. Thanks again!
I failed to mention that I am running the 64 bit version of Ubuntu. Huge mistake and I’ve had nothing but problems with it.
sudo apt-get install libaio1
Fabulous doc! I got it running on Ubuntu 7.10 Desktop without any problems (save for a minor glitch – apt-get install libaio1 (not libaio), as others mentioned.
Also, my init script demands that I run dbstart and dbshut with $ORACLE_HOME as parameter (maybe because I created the database during installation?):
– su $ORA_OWNR -c $ORACLE_HOME/bin/dbstart
+ su $ORA_OWNR -c “$ORACLE_HOME/bin/dbstart $ORACLE_HOME”
– su $ORA_OWNR -c $ORACLE_HOME/bin/dbshut
+ su $ORA_OWNR -c “$ORACLE_HOME/bin/dbshut $ORACLE_HOME”
Many thanks,
Val
What’s scary is that that seems easier than trying to install Oracle 11g on Oracle’s own distro of Linux! Especially considering that the Oracle distro is missing a required RPM in order to use ASM.
If only in my case the database and distro were made by the same company… Oh hang on… they are!
Hi
I’ve followed all the instructions you kindly put in this tutorial but there are still problems after the installation has “successfully” finished. I’m installing on a 6.06 LTS ubuntu linux system. After a system reboot oracle was unable to open the database created during installation.
The first error I’gve found is this: I was not able to found the initORCL.ora file in the $ORACLE_HOME/dbs/ folder . After some googling I’ve found a post in a mailing list suggesting to solve the problem simply doing a
cp init.ora initORCL.ora
after this I’m able to connect to sqlplus but ti cannot mount the database:
SQL> alter database mount;
alter database mount
*
ERROR at line 1:
ORA-00205: error in identifying control file, check alert log for more info
I’ve tried to found the alert.log file but without luck …. I’ve also found a similar problem (also after some googling) in a mailing list but it seems to be originated by an spfile modification (which is not the case because all the files are expected to be created by the installer ……). Any help would be greatly appreciated … Im new to Oracle and I’m a little bit confused.
Matteo
Matteo,
I have the same problem. I was able to connect to the web interface https://localhost:1158/em… (for exact url, see the output of the oracle startup script; it appears to generate port numbers randomly)
and from there I manually started the instance. Also, make sure your /bin/sh is linked to /bin/bash (not something else like /bin/dash, which doesn’t properly intepret some of the oracle scripts).
Regards,
Val
… quick update to my post above. Take a look at /etc/oratab which lists the available services. By default, my install didn’t set databases to auto-start which prompted manual intervention after each reboot. In short, the last letter should be Y for autostart:
master:/opt/oracleHome:Y
That took care of it. Take a look at https://www.oracleutilities.com/OSUtil/dbstart.html for more info.
fckn DISPLAY … just typed “xhost +” in terminal, and it worked…
Hola para los que tienen el problema:
Comprobando el monitor: debe estar configurado para mostrar al menos 256 colores
>>> No se ha podido ejecutar la comprobación automática de colores de visualización con el comando /usr/X11R6/bin/xdpyinfo. Compruebe si está definida la variable DISPLAY. Fallo <<<<
Fallo de algunas comprobaciones de requisitos. Debe cumplir estos requisitos antes de
continuar con la instalación,en cuyo momento se volverán a comprobar.
¿Desea continuar? (y/n) [n] n
lo pueden solucionar asi:
desde root colocan
xhost +local:oracle
y ya puede continuar con la instalacion
Great page, Augusto. It was extremely useful. My firsrt Oracle install on an unsupported Linux platform (our loved ubuntu) and it was “cut&paste”.
I mention 1 tip. Almost at the end, the Enterprise Configuration Assicant (emca.script) complaint on not getting what he exptets on /etc/oraIst.loc. This would have made emca happy before calling oraInst:
touch /etc/oraInst.loc
chown oracle /etc/oraInst.loc
chgrp dba /etc/oraInst.loc
Great page.
I’ve prepared my spirit for a 2 day fight and my db is up and running on 2 hours.
Thanks again,
Alberto.
I installed oracle 11g and creeate a sample database. every work perfectely. But I cannot connect with the SYS user. In can not stop or start my database. There are some thing wrong on $HOME_ORACLE/lib like lib*
Thanks for this great tutorial. I had tried installing 11g on Fedora 9 64 bit, and I agree with others, 64 bit 11g for Linux is a nightmare. I would suggest making sure that you have all the required 32 bit and 64 bit libraries installed. In many cases I linked the 32 bit path to the 64 bit one, and it seemed to work.
Thanks for the great tutorial. I ran into many troubles with 8.04. If you get around to it, I’d love to see a good comprehensive tutorial on that.
BTW, for the user who asked earlier, my WPA on my iMac works flawlessly!
Thanks again for a great tutorial.
[…] instead of 11.1.0.To apply the 10.2.0.4 patch you just need to repeat the process.Further ReferencesAugusto’s earlier article on installing on Ubuntu Feisty Fawn (which has some additional explanation of the parameter tweaking) Oracle Release for 10gR2 on Linux […]
FWIW I followed this installation guide on a fresh [and apt-get update’d] install of Hardy Heron.
Here’s the issues I had as I went along:
The initial apt-get command: libaio has been renamed to libaio1.
The DISPLAY environment variable. had to switch to my normal user and type “xhost +” (after install is over type “xhost +localhost”), then back as the oracle user: “export DISPLAY=:0.0”
I also had an error appear:
“Error in invoking target ntcontab.o of makefile[…]”
For which I found this website:
https://traxel.com/oracle_linux.html
that suggested the following fix:
apt-get install gcc make manpages-dev autoconf automake libtool flex bison gdb binutils
Which did in fact solve the problem.
I then recieved an error on the “Configuration Assistants” dialog: “OUI-25031:Some of the configuration assistants failed/cancelled.” Where, in the Details panel I traced it to “UnsatisfiedLinkError exception loading native library: njni11”
sudo apt-get install libaio1
solved the problem.
“If you see these messages (and I sincerely hope you do) you’re all set!”
Not strictly true…if you created a sample database from the installer.
First, be aware that if you follow the steps exactly as laid out, you will have put this in your /etc/profile:
export ORACLE_SID=ORCL
Notice the installed gave your instance sid “orcl”. This will cause a huge problem, in that you can’t connect to the instance. Change it either when installing or in your profile. And check oratab in /etc/init.d/ to make sure the SID is correct.
If you get a shared pool memory error, open the initSID.ora file and adjust the pool until oracle is satisfied.
It’s also worth mentioning…try to start sqlplus as sysdba to make sure everything is cool:
sqlplus / as sysdba;
(As sysdba you can also check out the instances running in the view v$instance view.)
I also ran across a problem where oracle complained about the control files…
so issuing show parameter control_files from sqlplus as sysdba will give you what the initSID.ora file is looking for. I found out the files simply didn’t exist. So making sure to be user oracle, I just touched the two files:
# touch control_file1
# touch control_file2
then, shutdown the instance:
SQL>shutdown
then, restarted the instance:
SQL>startup
And finally, after 4 hours of installing, messing with DISPLAY, permissions, exceptions, etc, the oracle process was running, the instance was started and the database was mounted!
what is the password oracle , i can’t connect i have the message “password for oracle” but i dont have it .
thank’s
[…] 7.04 – Feisty Fawn […]
apt-get install ia32-libs
hi.
i am new to ubuntu and oracle 11g.i treied to install the oracle but on the very first step…to install packages….i got the following msg:
[email protected]:/home/bilal# apt-get install gcc make binutils lesstif2 libc6 libc6-dev rpm libmotif3 libaio libstdc++5 gawk alien libg++2.8.1.3-glibc2.2 ksh gcc-3.3 g++-3.3 libstdc++5
Reading package lists… Done
Building dependency tree
Reading state information… Done
gcc is already the newest version.
make is already the newest version.
binutils is already the newest version.
libc6 is already the newest version.
libc6-dev is already the newest version.
Package libaio is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
However the following packages replace it:
libaio1
E: Package libaio has no installation candidate
in which Package libaio is said not available so i do not know…can i able to install oracle without this package……..plz help me out…..i am waiting for the replay..
thanks
hi.
on step 7 i did not find these lines which u mentioned in the step….so if we have to add them by ourselves.
fs.file-max = 65535
kernel.shmall = 2097152
kernel.shmmax = 2147483648
kernel.shmmni = 4096
kernel.sem = 250 32000 100 128
net.ipv4.ip_local_port_range = 1024 65000
net.core.rmem_default = 1048576
net.core.rmem_max = 1048576
net.core.wmem_default = 262144
net.core.wmem_max = 262144
..the data which i found in this file is as follows.
# /etc/sysctl.conf – Configuration file for setting system variables
# See /etc/sysctl.d/ for additional system variables.
# See sysctl.conf (5) for information.
#
#kernel.domainname = example.com
# Uncomment the following to stop low-level messages on console
#kernel.printk = 4 4 1 7
##############################################################3
# Functions previously found in netbase
#
# Uncomment the next two lines to enable Spoof protection (reverse-path filter)
# Turn on Source Address Verification in all interfaces to
# prevent some spoofing attacks
#net.ipv4.conf.default.rp_filter=1
#net.ipv4.conf.all.rp_filter=1
# Uncomment the next line to enable TCP/IP SYN cookies
# This disables TCP Window Scaling (https://lkml.org/lkml/2008/2/5/167),
# and is not recommended.
#net.ipv4.tcp_syncookies=1
# Uncomment the next line to enable packet forwarding for IPv4
#net.ipv4.ip_forward=1
# Uncomment the next line to enable packet forwarding for IPv6
#net.ipv6.conf.all.forwarding=1
###################################################################
# Additional settings – these settings can improve the network
# security of the host and prevent against some network attacks
# including spoofing attacks and man in the middle attacks through
# redirection. Some network environments, however, require that these
# settings are disabled so review and enable them as needed.
#
# Ignore ICMP broadcasts
#net.ipv4.icmp_echo_ignore_broadcasts = 1
#
# Ignore bogus ICMP errors
#net.ipv4.icmp_ignore_bogus_error_responses = 1
#
# Do not accept ICMP redirects (prevent MITM attacks)
#net.ipv4.conf.all.accept_redirects = 0
#net.ipv6.conf.all.accept_redirects = 0
# _or_
# Accept ICMP redirects only for gateways listed in our default
# gateway list (enabled by default)
# net.ipv4.conf.all.secure_redirects = 1
#
# Do not send ICMP redirects (we are not a router)
#net.ipv4.conf.all.send_redirects = 0
#
# Do not accept IP source route packets (we are not a router)
#net.ipv4.conf.all.accept_source_route = 0
#net.ipv6.conf.all.accept_source_route = 0
#
# Log Martian Packets
#net.ipv4.conf.all.log_martians = 1
#
# The contents of /proc//maps and smaps files are only visible to
# readers that are allowed to ptrace() the process
# kernel.maps_protect = 1
plz help me out..waiting for replay…i am new to ubuntu and linux.
@bilal,
You probably want to install package libaio1 – without that one, dbca won’t run. On step 7 you need to add the lines mentioned to each file (as those lines are usually not present on a standard Linux distribution). May I suggest you take a look at newer versions of this tutorial? Just check out https://www.pythian.com/news/
Cheers!
Hi all,
A great introduction – when do you get the time to write things up :)
I am a firebirder about to play with oracle. Can I install oracle on my home server – ubuntu 8.04 – and get to it from win boxes elsewhere on the network?
There is no gui on the server – it just serves very well
Mick
Thank you, thank you.
This page helped me alot, since Im in the middle of installing oracle at school.
Although Im running 10g and Karmic.
Your other tuts are not as wellwritten as this one, imho. Thats why i chosed this one over those…
And my teacher said it couldn’t be done. Ha, this page shut him up…
Thank you very very very much…
Guys I’d like to know whether is there anyway in which I could install iSQL*PLus on top of Oracle 10g. I desperately need to use iSQL*Plus.
[…] […]
Starting Oracle Universal Installer…
Checking Temp space: must be greater than 120 MB. Actual 1748 MB Passed
Checking swap space: must be greater than 150 MB. Actual 3145 MB Passed
Checking monitor: must be configured to display at least 256 colors
>>> Could not execute auto check for display colors using command /usr/X11R6/bin/xdpyinfo. Check if the DISPLAY variable is set. Failed <<<<
Some requirement checks failed. You must fulfill these requirements before
continuing with the installation,at which time they will be rechecked.
Continue? (y/n) [n] y
Rechecking installer requirements….
Preparing to launch Oracle Universal Installer from /tmp/OraInstall2010-01-03_04-01-47PM. Please wait …sh: /home/database/install/unzip: No such file or directory
[email protected]:/home/database/install$ ls -l
total 224
-rwxr-xr-x 1 oracle oinstall 28 2008-10-06 04:35 addLangs.sh
-rwxr-xr-x 1 oracle oinstall 76 2008-10-06 04:35 addNode.sh
-rwxr-xr-x 1 oracle oinstall 276 2008-10-06 04:35 attachHome.sh
-rwxr-xr-x 1 oracle oinstall 182 2008-10-06 04:35 detachHome.sh
drwxr-xr-x 2 oracle oinstall 4096 2008-10-06 04:35 images
-rwxr-xr-x 1 oracle oinstall 47926 2008-10-06 04:35 lsnodes
-rwxr-xr-x 1 oracle oinstall 2818 2008-10-06 04:35 oneclick.properties
-rwxr-xr-x 1 oracle oinstall 1798 2008-10-06 04:35 oraparam.ini
-rwxr-xr-x 1 oracle oinstall 6437 2008-10-06 04:35 oraparamsilent.ini
drwxr-xr-x 2 oracle oinstall 4096 2008-10-06 04:35 resource
drwxr-xr-x 2 oracle oinstall 4096 2008-10-06 04:35 response
-rwxr-xr-x 1 oracle oinstall 21642 2008-10-06 04:35 runSSHSetup.sh
-rwxr-xr-x 1 oracle oinstall 102612 2008-10-06 04:35 unzip
WHAT I HAVE TO DO NOW
On Ubuntu 9.10 (Karmic), libstdc++.so.5, required by Oracle is replaced by .6. To fix:
1) add the following repository: https://archive.ubuntu.com/ubuntu jaunty universe
2) install libstdc++5 and run the install of Oracle
3) reinstall libstdc++6 (otherwise such apps as ooffice get broken)
thanx a lot
Thanks so much for the detail information. I am going to refer back to this so many times. I really appreciate it. Now i know how to get into details when doing something similar that i’ve done here at https://www.franklinfaces.com/Forum102-1.aspx
Thank you again.
Andy.
Thank you for listing the steps. This was very helpful …
uname -a
Linux ub01 2.6.35-25-generic-pae #44-Ubuntu SMP Fri Jan 21 19:01:46 UTC 2011 i686 GNU/Linux
hi
Im trying to install oracle 11gR1 32bit on ubuntu linux 11.04 32bit and it looks like i need glib version ATLEAST=2.3.4-2.19. so I downloaded version libstdc++5_3.3.6-21ubuntu1_i386.deb since it said Atleast. But the system doesn’t seem to be verifying that requirement. Can anybody please help me.
What i don’t realize is actually how you are now not
actually a lot more neatly-liked than you might be right now.
You are very intelligent. You already know therefore
significantly on the subject of this topic, produced me in my opinion believe it from a
lot of various angles. Its like women and men are not interested except it’s one thing to
accomplish with Lady gaga! Your own stuffs nice. At all times deal with it up!
Verry descriptive blog, I loved that a lot. Will there be a part 2?
I’m trying to install it with ubuntu 16.04 , but facing some serious issues . . . can you please help