Does anyone have any experience configuring Tomcat to connect to an Oracle
RAC cluster?

I have an application that currently works in a test environment, where it
connects to a single Oracle server.  Now I'm moving it to a QA
environment, where there is a 3-node Oracle cluster using RAC.  I'm
getting an Oracle 12505 error (SID not found) trying to talk to the
cluster.  Problem is, I'm not sure how the configuration differs in
Tomcat, if it does, in this situation.

I have a TNS entry in tnsnames, and I can connect to the cluster using
Toad or Oracle Enterprise Manager, so the basic setup appears correct.

Here's my server.xml context entry:

<Context path="/app" docBase="app" swallowOutput="false" override="true">
  <Resource name="jdbc/appdb" auth="Container" type="javax.sql.DataSource" />
    <ResourceParams name="jdbc/appdb">
    
<parameter><name>driverClassName</name><value>oracle.jdbc.driver.OracleDriver</value></parameter>
<!--
    <parameter><name>username</name><value>app</value></parameter>
    <parameter><name>password</name><value>apptest</value></parameter>
    
<parameter><name>url</name><value>jdbc:oracle:thin:@server.company.net:1700:testsid</value></parameter>
-->
    <parameter><name>username</name><value>appweb</value></parameter>
    <parameter><name>password</name><value>appqa</value></parameter>
    
<parameter><name>url</name><value>jdbc:oracle:thin:@node1.company.net:1700:qasid</value></parameter>
    <parameter><name>maxActive</name><value>100</value></parameter>
    <parameter><name>maxIdle</name><value>75</value></parameter>
    <parameter><name>minIdle</name><value>50</value></parameter>
    <parameter><name>testOnBorrow></name><value>false</value></parameter>
    <parameter><name>logAbandoned</name><value>true</value></parameter>
    <parameter><name>removeAbandoned</name><value>true</value></parameter>
    <parameter><name>whenExhaustedAction</name><value>1</value></parameter>
  </ResourceParams>
</Context>

Passwords and such have been changed to protect the innocent :)  I also
left the commented section for the test environment that *does* work, just
for comparison.

Now, the first thing that struck me as wrong is that the server I'm
connecting to is only one node in the cluster.  Should RAC provide a
single server name that the cluster is accesible through?

Otherwise, everything looks correct to me.  Anyone have any ideas?  TIA!

Frank

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to