Projects | Downloads | Tickets | KnowledgeBase | Forums | About | Search
Load:0.00 0.00 0.00
Sessions: 13
Login
User:
Pass:
Remember login:
New User | Lost Password

Case[1122]: Oracle XE on Fedora 7, 8, 9

Printable View
Case
Title:Oracle XE on Fedora 7, 8, 9
Number:1122
Created:11/13/2007 10:27
Created By:bemowski
Page Views:4768
Status: ACTIVE
Approver:unassigned
Keywords:fedora core oracle xe linux
Related Tickets:
Detail

Impressions:
I have previously run the full blown Oracle 10g on Fedora (core) 5, 6, and 7 - however it can get fairly complex to install - and the system is cumbersome and memory hungry. The memory consumed is the real problem - especially when trying to run several JVMs and VMWare in parallel with a heavy running Oracle 10g system.

So - after running the full 10g for a few years, I decided to try Oracle 10 eXpress Edition (XE).

Installation

The installation was straightforward. No alterations necessary to the kernel params (as with the full 10g install).

I started with:
yum install libaio


Then - I obtained the install RPM, and I installed it as root:

# rpm -ivh oracle-xe-10.2.0.1-1.0.i386.rpm


The RPM installer creates the oracle user and dba group within your system. Then - run the configure (again as root):
# /etc/init.d/oracle-xe configure


root@flask:/mnt/data/archive/oracle !!>/etc/init.d/oracle-xe configure

Oracle Database 10g Express Edition Configuration
-------------------------------------------------
This will configure on-boot properties of Oracle Database 10g Express 
Edition.  The following questions will determine whether the database should 
be starting upon system boot, the ports it will use, and the passwords that 
will be used for database accounts.  Press <Enter> to accept the defaults. 
Ctrl-C will abort.

Specify the HTTP port that will be used for Oracle Application Express [8080]:18080

Specify a port that will be used for the database listener [1521]:

Specify a password to be used for database accounts.  Note that the same
password will be used for SYS and SYSTEM.  Oracle recommends the use of 
different passwords for each database account.  This can be done after 
initial configuration:
Confirm the password:

Do you want Oracle Database 10g Express Edition to be started on boot (y/n) [y]:n

Starting Oracle Net Listener...Done
Configuring Database...grep: /usr/lib/oracle/xe/app/oracle/product/10.2.0/server/config/log/*.log: No such file or directory
Done
Starting Oracle Database 10g Express Edition Instance...Done
Installation Completed Successfully.
To access the Database Home Page go to "http://127.0.0.1:18080/apex"


Follow the prompts. I personally do not start the DB with system startup - there are scripts to do this linked in the menu structure created in Gnome. I run the scripts startdb.sh and stopdb.sh from the command line as oracle.

Though not noted, the SID for XE is appropriately enough XE. The RPM/configure script does not seem to setup the environment for the oracle user. I've set these up myself:
export ORACLE_HOME=/usr/lib/oracle/xe/app/oracle/product/10.2.0/server
export ORACLE_SID=XE

export PATH=$PATH:$ORACLE_HOME/bin


This allows me to run sqlplus as oracle.

Tweaks

The XE system seemed to be behaving quiet well initially, however after getting several larger JVMs and connection pools connected, I started to get these errors:

[13 11 2007 15:00:17] [main] ERROR: Caused by: java.sql.SQLException: Listener refused the connection with the following error:
[13 11 2007 15:00:17] [main] ERROR: ORA-12519, TNS:no appropriate service handler found
[13 11 2007 15:00:17] [main] ERROR: The Connection descriptor used by the client was:
[13 11 2007 15:00:17] [main] ERROR: localhost:1521:XE
[13 11 2007 15:00:17] [main] ERROR: 
[13 11 2007 15:00:17] [main] ERROR:     at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:145)
[13 11 2007 15:00:17] [main] ERROR:     at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:380)
[13 11 2007 15:00:17] [main] ERROR:     at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:401)
[13 11 2007 15:00:17] [main] ERROR:     at oracle.jdbc.driver.PhysicalConnection.(PhysicalConnection.java:441)


As it turns out, this is related to process/connection limits. I would like to note that the error itself is very poorly written "No appropriate service handler found"??

To see what sessions are active, try this as a privilidged users (system or sysdba or something):
select s.sid, s.serial#, s.username, s.schemaname, s.machine, s.osuser, s.program from v$session s


Looks like at the outset - XE is limited to 40 user sessions (processes) and 49 total sessions (sessions). You can see this by looking for the values in v$system...

Anyway - here is what I've upped the values to:
alter system set processes=200 scope=spfile;
alter system set sessions=225 scope=spfile; 

Add Comment


Show System Notes
User Date Comment
anonymous 05/18/2009
11:57
Hi I got the following error after the installation was ok and configure had started the instance and the listener -

Summary:

SELinux is preventing su (initrc_su_t) "execute" to ./xauth (xauth_exec_t).

Detailed Description:

SELinux denied access requested by su. It is not expected that this access is
required by su and this access may signal an intrusion attempt. It is also
possible that the specific version or configuration of the application is
causing it to require additional access.

Allowing Access:

Sometimes labeling problems can cause SELinux denials. You could try to restore
the default system file context for ./xauth,

restorecon -v './xauth'

If this does not work, there is currently no automatic way to allow this access.
Instead, you can generate a local policy module to allow this access - see FAQ
(http://fedora.redhat.com/docs/selinux-faq-fc5/#id2961385) Or you can disable
SELinux protection altogether. Disabling SELinux protection is not recommended.
Please file a bug report (http://bugzilla.redhat.com/bugzilla/enter_bug.cgi)
against this package.

Additional Information:

Source Context unconfined_u:system_r:initrc_su_t:s0
Target Context system_u:object_r:xauth_exec_t:s0
Target Objects ./xauth [ file ]
Source su
Source Path /bin/su
Port <Unknown>
Host localhost.localdomain
Source RPM Packages coreutils-6.10-18.fc9
Target RPM Packages
Policy RPM selinux-policy-3.3.1-42.fc9
Selinux Enabled True
Policy Type targeted
MLS Enabled True
Enforcing Mode Enforcing
Plugin Name catchall_file
Host Name localhost.localdomain
Platform Linux localhost.localdomain 2.6.25-14.fc9.i686 #1
SMP Thu May 1 06:28:41 EDT 2008 i686 i686
Alert Count 22
First Seen Fri 15 May 2009 01:35:24 PM IST
Last Seen Sun 17 May 2009 02:57:18 AM IST
Local ID 864d3731-0033-4e47-ac0b-04fa5df13a84
Line Numbers

Raw Audit Messages

host=localhost.localdomain type=AVC msg=audit(1242509238.450:31): avc: denied { execute } for pid=3911 comm="su" name="xauth" dev=sda10 ino=43921 scontext=unconfined_u:system_r:initrc_su_t:s0 tcontext=system_u:object_r:xauth_exec_t:s0 tclass=file

host=localhost.localdomain type=SYSCALL msg=audit(1242509238.450:31): arch=40000003 syscall=33 success=no exit=-13 a0=160642 a1=1 a2=161b80 a3=160642 items=0 ppid=3858 pid=3911 auid=0 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=pts1 ses=1 comm="su" exe="/bin/su" subj=unconfined_u:system_r:initrc_su_t:s0 key=(null)


Any advice?
Copyright 2003-2007, JMatrix International