Search:  
Gentoo Wiki

HOWTO_Install_Oracle_10g_Express_Edition

Contents

Automatically installing Using Installer Scripts

Came across a handy utility which installed Oracle perfectly on Gentoo. Instructions and utility available on: http://oracle.antisocial.co.za/oracle_xe.php (doesn't work for now)

This is a personal link because I had the scripts before they go down. http://tuxtor.shekalug.org/wp-content/uploads/2008/09/oracle10gxetar.gz

Manually: Downloading and installing

Download

Download oracle-xe-univ-10.2.0.1-1.0.i386.rpm from http://www.oracle.com/technology/software/products/database/xe/index.html

Install the Red Hat Package Management Utils

emerge app-arch/rpm
emerge app-arch/rpm2targz

Note: In some cases, an error "rpmdav.c:106: error: expected declaration specifiers or '...' before 'ne_conn_status' rpmdav" occurs during emerging app-arch/rpm. If so, please read this - http://bugs.gentoo.org/show_bug.cgi?id=214799 The clue is to apply sugested patches (in comment #5 & #6) and recreate Manifest file with "ebuild /path/to/rpm-4.4.6/ebuild_file digest"

Kernel Parameters for Oracle 10g

Change the kernel parameters, add the following lines to the /etc/sysctl.conf file:

File: /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

Effective immediately

sysctl -p

Install required packages

glibc-2.3.2, libaio-0.3.96 and sys-devel/bc was required

emerge -s glibc
emerge -s libaio
emerge -s bc
Warning: Don't downgrade glibc, that will mess up your system!

Create oracle group and user

groupadd oinstall
useradd -g oinstall oracle
passwd oracle

Install rpm packes with 'nodeps' option

rpm -ivh downloads/oracle-xe-univ-10.2.0.1-1.0.i386.rpm --nodeps
Warning: sometimes an error could break the installation:
rpmdb: Berkeley DB library configured to support only private environments
rpmdb: Berkeley DB library configured to support only private environments
error: db4 error(22) from dbenv->open: Invalid argument
error: cannot open Packages index using db3 - Invalid argument (22)
error: cannot open Packages database in /var/lib/rpm

Maybe the rpm was compiled without nptl-devel installed (see https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=82764).

In order to fix the problem described above:
1. create the /etc/rpm directory

mkdir -p /etc/rpm

2. insert the following line in /etc/rpm/macros:

echo "%__dbi_cdb  create cdb private mpool mp_mmapsize=16Mb mp_size=1Mb" >> /etc/rpm/macros

3. retry to install oracle:

rpm -ivh downloads/oracle-xe-univ-10.2.0.1-1.0.i386.rpm --nodeps

Configuration

oracle-xe

There is a Config file named oracle-xe under the /etc/init.d,Modify the config file

sed -i -e "s/\$SU -s \/bin\/bash \{1,2\}\$ORACLE_OWNER -c/\$SU \$ORACLE_OWNER -l -c/g" oracle-xe

User and group

Confirm the oracle user is in the dba group .otherwise you can not through the OS authentication.

groups oracle
wheel dba

Config and Install Database

/etc/init.d/oracle-xe configure

Enter the following configuration information:

Check the Process.

netstat -an |grep 1521
ps -ef |grep ora
ok

To enable remote access by HTTP

WHAT COMMAND GOES HERE????

# sqlplus /nolog
SQL> CONNECT SYS/AS SYSDBA 
Enter password: 
SQL> EXEC DBMS_XDB.SETLISTENERLOCALACCESS(FALSE);

Then you can access it from the following URL: http://host_ipaddress:port/apex/ PS: You can login with the username SYS and the password PS: Does not seems to work with Firefox, however works with Konqueror.

Start and stop

You can start/stop Database by follow command

/etc/init.d/oracle-xe start
/etc/init.d/oracle-xe stop

External links

Retrieved from "http://www.gentoo-wiki.info/HOWTO_Install_Oracle_10g_Express_Edition"

Last modified: Tue, 23 Sep 2008 07:37:00 +0000 Hits: 17,788