Something that might help someone avoid one or two minor struggles:
1. Install openSUSE OraRun RPM v1.9-52 (http://ftp.novell.com/partners/oracle/sles-10/orarun.rpm)
orarun.rpm
NOTE – Because orarun is intended for OracleEnterprise not OracleXE, it must be re-configured (a.k.a cleaned-up after installation. See step 3. OraRun Cleanup.
2. Install Oracle-XE RPM
oracle-xe-10.2.0.1-1.0.i386.rpm
(It might be a good idea to reboot now)
3. OraRun Cleanup (as root)
(a) Create an XE-named copy of OraRun’s profile script “oracle.sh” – you will edit this file in step 4. Edit Profile
cp /etc/profile.d/oracle.sh /etc/profile.d/oracle-xe.sh
(b) Relocate “unwanted” OraTab config/setup files (keeping them, just in case)
mkdir /tmp/OraRun_BKUP
mv /etc/init.d/oracle /tmp/OraRun_BKUP/etc-init.d-oracle
mv /etc/profile.d/oracle.sh /tmp/OraRun_BKUP/etc-profile.d-oracle.sh
mv /etc/profile.d/oracle.csh /tmp/OraRun_BKUP/etc-profile.d-oracle.csh
mv etc/sysconfig/oracle /tmp/OraRun_BKUP/etc-sysconfig-oracle
4. Edit Profile file (/etc/profile.d/oracle-xe.sh)
(a) Change ORACLE_BASE from /opt/oracle to /usr/lib/oracle/xe/app/oracle
(b) Change ORACLE_HOME from $ORACLE_BASE/product/10.2/db_1 to $ORACLE_BASE/product/10.2.0/server
(c) Change ORACLE_SID from orcl to XE
(d) Comment out For RAC exports
For RAC
#export ORA_CRS_HOME=$ORACLE_BASE/product/10gR2/crs
#export ORA_ASM_HOME=$ORACLE_BASE/product/10gR2/asm
(e) Comment out AGENT_HOME
Grid Control Agent Home
#AGENT_HOME=$ORACLE_BASE/product/10.2/agent
5. Configure Oracle
As root, run → sh /etc/init.d/oracle-xe configure
HTTP port → 8080
database listener → 1521
password for database accounts → syspass <–or your preferred PW for SYSTEM/DBA user
start on boot → y
**6. Open Firewall to Oracle **(as necessary)
Yast Control Center > Security & Users > Firewall > Allowed Services (on left-nav)
Choose “External Zone” from ‘Allowed Services for Selected Zone’ dropdown
Click Advanced button
Add 1521 and 8080 to both TCP & UDP Ports
Navigate to Start-Up (on left-nav)
Click “Save Settings & Restart Firewall Now” button
Click “Next” button
Click “Finish” button
**7. Configure Users/Groups **(using Yast Control Center > Security & Users > User & Group Management)
NOTE.1 – OraRun installs using a user/group of oracle:oinstall while Oracle uses oracle:dba, so there may be a mix of both oinstall and dba groups in your installation. I prefer to make everything consistent with Oracle’s dba group [see next step, 8. Clarify/Unify], and then also add the group dba to my own personal user account.
NOTE.2 – If you don’t see the user oracle or group dba in YaST User & Group Management after the install, you may need to change to a custom filter whereby you can see both system & local users/groups
(a) Add/change group dba password (I use “dbapass” for the time being)
(b) Add group dba to your personal user account
(c) Add/change user oracle
Change password as necessary (I use “orapass” for now)
IF DisableUserLogin = <blank>, change LoginShell to /bin/bash
8. Clarify/Unify ownership/permission of Oracle files & folders
NOTE.1 – I’ve had the problem where the listener wouldn’t start no matter what I tried, until I discovered that the listener could not access /var/tmp/.oracle. As appropriate, execute the following:
chown -R oracle:dba /usr/lib/oracle
chmod -R 755 /usr/lib/oracle
chown -R oracle:dba /var/tmp/.oracle
chmod -R 755 /var/tmp/.oracle
chown -R oracle:dba /tmp/.oracle
chmod -R 755 /tmp/.oracle
chown oracle:dba /var/opt/oracle
chmod 755 /var/opt/oracle
9. Reboot (at the very least, completely shut down Oracle & re-start, which will also restart the listener)
After this if you do something in Oracle, login as user oracle (see step 10. Some Testing)
10. Some Testing
SQL*Plus
(a) Connect
su oracle
sqlplus sys/syspass as sysdba
<or> sqlplus system/syspass
<or> sqlplus “connect / as sysdba” ← pasword is blank
<or> sqlplus /nolog
SQL> connect / as sysdba
<or> etc.
(b) Create your Oracle account, perhaps called <your Linux usernam>+o, e.g. tmso
create user tmso identified by tmspass;
grant dba to tmso;
grant sysdba to tmso;
(c) Query the DB for something that strikes your fancy
select count(TABLE_NAME) as Qty_Views from DICTIONARY where substr(TABLE_NAME,1,2)=‘V$’;
select * from V$VERSION;
select dbms_xdb.gethttpport() from dual;
(e) Disconnect
exit
Listener Status (from bash as user oracle)
Run /usr/lib/oracle/xe/app/oracle/product/10.2.0/server/bin/lsnrctl status
Successful results look like:
LSNRCTL for Linux: Version 10.2.0.1.0 - Production on 15-MAY-2009 18:14:18
Copyright (c) 1991, 2005, Oracle. All rights reserved.
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC_FOR_XE)))
STATUS of the LISTENER
Alias LISTENER
Version TNSLSNR for Linux: Version 10.2.0.1.0 - Production
Start Date 15-MAY-2009 17:06:22
Uptime 0 days 1 hr. 7 min. 55 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Default Service XE
Listener Parameter File /usr/lib/oracle/xe/app/oracle/product/10.2.0/server/network/admin/listener.ora
Listener Log File /usr/lib/oracle/xe/app/oracle/product/10.2.0/server/network/log/listener.log
Listening Endpoints Summary…
(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC_FOR_XE)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=lin-tms)(PORT=1521)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=lin-tms)(PORT=8080))(Presentation=HTTP)(Session=RAW))
Services Summary…
Service “PLSExtProc” has 1 instance(s).
Instance “PLSExtProc”, status UNKNOWN, has 1 handler(s) for this service…
Service “XE” has 1 instance(s).
Instance “XE”, status READY, has 1 handler(s) for this service…
Service “XEXDB” has 1 instance(s).
Instance “XE”, status READY, has 1 handler(s) for this service…
Service “XE_XPT” has 1 instance(s).
Instance “XE”, status READY, has 1 handler(s) for this service…
The command completed successfully
Connect to DB Home Page using browser
So far I have been only partly successful connecting to the DB Home Page on http://127.0.0.1:8080/apex. With Firefox I still can’t connect, period. However, using openSUSE’s Konqueror web browser I can connect (Konqueror’s connection URL changes from http://127.0.0.1:8080/apex to http://127.0.0.1:8080/apex/f?p=4550:11:3631164448473123::NO::: at the connection).
11. You are now ready to be dangerous with Oracle XE … ;->
BTW, for a SQL client I use SQuirreLSQL, since I also use SQLite and SQuirreLSQL can connect to SQLite as well as Oracle
Driver
Oracle Thin Driver
Alias
Name: OracleXEsys
URL: jdbc:oracle:thin:@localhost:1521:XE
UserName: system
Password: syspass
**12. PS **-- Here is some miscellaneous info that may or may not be useful to you:
SOME ORACLE DB COMMANDS (should be run as user oracle, except for the force-reload which requires root):
/etc/init.d/oracle-xe force-reload ← Shuts down & restarts Oracle and Listener (requires root privileges)
/usr/lib/oracle/xe/app/oracle/product/10.2.0/server/bin/lsnrctl stop ← stop Listener
/usr/lib/oracle/xe/app/oracle/product/10.2.0/server/bin/lsnrctl start ← start Listener
/usr/lib/oracle/xe/app/oracle/product/10.2.0/server/bin/lsnrctl status <–Status Listener
tail -50 /usr/lib/oracle/xe/app/oracle/product/10.2.0/server/network/log/listener.log ← view last 50 lines of listener.log
USE SQL*PLUS to change a user’s PW and/or access
alter user username identified by password account unlock
VARIOUS LINUX CMDS I used in the course of trying to figure out the listener (in no particular order)
nmap 127.0.0.1
netstat -anp | grep ‘^tcp.*LISTEN’
lsof -i4 -P | grep -i oracle
ps -ef | grep LISTENER
ip addr
hostname -vf
cat /etc/HOSTNAME
cat /etc/hosts
cat /usr/lib/oracle/xe/app/oracle/product/10.2.0/server/network/admin/listener.ora
cat /usr/lib/oracle/xe/app/oracle/product/10.2.0/server/network/admin/tnsnames.ora
Important parameters in /etc/init.d/oracle-xe configuration script:
ORACLE_HOME=/usr/lib/oracle/xe/app/oracle/product/10.2.0/server
ORACLE_OWNER=oracle
ORACLE_SID=XE
LSNR=$ORACLE_HOME/bin/lsnrctl
SQLPLUS=$ORACLE_HOME/bin/sqlplus
ORARUN-1.9-52 File List:
/etc/init.d/oracle
/etc/profile.d/oracle.csh
/etc/profile.d/oracle.sh
/sbin/fuser
/usr/bin/fuser
/usr/lib/libInternalSymbols.a
/usr/lib/libInternalSymbols.so
/usr/lib/libInternalSymbols.so.1
/usr/sbin/rcoracle
/usr/share/doc/packages/orarun
/usr/share/doc/packages/orarun/README
/var/adm/fillup-templates/sysconfig.oracle