Forum OpenACS Q&A: Installing Oracle OACS on top of Oracle Application Sever 10g

This is a quick guide to show the workarounds I had to find to get OpenACS working alongside an installation of Oracle Application Server (AS) 10g.

I'm running Suse 9.2 on my machine but this should be relevant to anyone who has AS 10g installed on some flavour of linux.

You can pretty much skip the whole step on installing Oracle as 10g AS includes db facilities in the 'infrastructure' install.

1.  Create the database

10g AS includes a utility called dbca which you should be able to call from the command line once you've switched to an oracle user.  You can use the OpenACS docs to guide you through the options of creating an Oracle DB.  One important thing to remember, one of the dialog boxes allows you to explicitly configure the parameters for your db.  You'll need to get in there and make sure the nls_date_format is checked and that it equals "YYYY-MM-DD".

2.  Download & install Oracle 10g Instant Client

You'll need the following installed because 10g AS is lacking 'oci' libraries.  I'm sorry I can't exactly remember why these are necessary.  I think it's because the aolserver oracle driver won't compile without them.
http://www.oracle.com/technology/software/tech/oci/instantclient/index.html
If the above link doesn't work you'll find the instant client at otn.oracle.com -> downloads -> database -> linux x86

3.  TCL installation (possibly just a suse 9.2 thing).

In the next step you're going to install tDom which won't compile unless your tcl is compiled for multithreading.  Suse 9.2 comes with tcl pre-installed.  I compiled tcl8.4 with threads but tDom kept picking up the pre-installed lib in /usr/lib/tcl8.4.so.  This took me ages to figure out.  I backed up the file and replaced it with a symbolic link to /usr/local/lib/tcl8.4.so.

4.  Installing Aolserver.
With your database installed you can go to the aolserver install outlined in the documentation.  I decided to go bleeding edge on every download and used aolserver 4.0.10 (http://sourceforge.net/project/showfiles.php?group_id=3152&package_id=3064&release_id=298093) and tDom 0.8.0 (http://www.tdom.org/files/tDOM-0.8.0.tar.gz).  I didn't have any joy with the latest oracle driver so I stuck to v2_7 as recommended in the install guide.

5.  OpenACS install - fix your loadjava first!
First time I installed OACS after following the above steps, everything went smoothly according to the logs.  Unfortunately, some core components of the OpenACS content repository didn't install.  They were stored in sqlj files.  I tried installing them manually using loadjava afterwards and discovered the problem.  Loadjava is just a script that creates sets up some environment variables for java at the beginning.  You'll need to change your $ORACLE_HOME's loadjava script where it creates JRECLASSPATH.  Mine was pointing at translator.zip (which doesn't exist) change this to translator.jar and all should be peachey.

First time I realised the loadjava was brokend was when I tried to run any module based on the open acs content repository (photo-album, file-storage etc).

Hope this may help someone out, if this install guide was a bit more user friendly (I'm assuming people reading this have installed openacs before) - noobs with Oracle Application Server could be encouraged to test out some competition!

The OCI libraries are indeed used by the AOLserver ns_oracle driver to talk to Oracle.

We need to get someone to fix the latest version of the AOLserver oracle driver. Some bright light "improved" it in ways that were not backwards compatible.