You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by LERBSCHER Jean-Pierre <je...@cofiroute.fr> on 2005/01/05 10:14:24 UTC

RE : Oracle 9i client connection to 8i database

If you get this log 
27-DEC-2004 16:58:11 *
(CONNECT_DATA=(SID=test)(CID=(PROGRAM=)(HOST=__jdbc__)(USER=oracle))) *
(ADDRESS=(PROTOCOL=tcp)(HOST=10.0.0.4)(PORT=33244)) * establish *
Perhaps you have to try jdbc:oracle:thin:@10.0.0.4:33244:test with thin
driver and jdbc:oracle:oci:@<service_name> with oci driver.

-----Message d'origine-----
De : Phillip Qin [mailto:Phillip.Qin@shareowner.com] 
Envoyé : mardi 4 janvier 2005 22:39
À : 'Tomcat Users List'
Objet : RE: Oracle 9i client connection to 8i database

There is nothing to do with Oracle client. All you need is the jdbc driver.

-----Original Message-----
From: Brad Rhoads [mailto:brad@zethcon.com] 
Sent: December 27, 2004 5:11 PM
To: 'Tomcat Users List'
Subject: RE: Oracle 9i client connection to 8i database


I always assumed the Oracle client was required. . .

I uninstalled the client and get the same results. With the sid syntax I at
least get an entry in the listener.log:

27-DEC-2004 16:58:11 *
(CONNECT_DATA=(SID=test)(CID=(PROGRAM=)(HOST=__jdbc__)(USER=oracle))) *
(ADDRESS=(PROTOCOL=tcp)(HOST=10.0.0.4)(PORT=33244)) * establish *

But the app doesn't get a connection. And with the service_name syntax I
only get a connection error:

DatabaseMessageresources: Loading all the messages for the messageMap
NVFactory: _readNVPair expected )
DatabaseMessageresources: SQL EXCEPTION FETCHING MESSAGE
java.sql.SQLException: Io exception: NL Exception was generated
        at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:187)

I've run into a similar problem where the db server was behind the firewall
and the firewall didn't allow high-ports, but in this case both machines are
behind the firewall.

Any other ideas why I might not be able to get a connection?

> -----Original Message-----
> From: Michael Echerer [mailto:mech@tngtech.com]
> Sent: Saturday, December 25, 2004 4:08 AM
> To: Tomcat Users List
> Subject: Re: Oracle 9i client connection to 8i database
> 
> How come that you need an Oracle client installation at all
> when you just want to use the Oracle thin JDBC driver? IHMO 
> the client installation is only required for OCI thick drivers...
> 
> Brad Rhoads wrote:
> > We have an (struts) app that talks to an Oracle 8i database. Our
> > latest installation wants to run the app on Fedora Core 2. 
> I couldn't
> > get the Oracle 8i client install, so I installed the 9i
> client. With
> > the 9i client, you have to use a service_name instead of a
> sid in the connection.
> > 
> > Normally my connection string (in my web.xml) looks like:
> > 
> > 	<param-value>jdbc:oracle:thin:@10.0.0.7:1521:test</param-value>
> > 
> > But it seems to get a service_name instead of a sid I have to use
> > something
> > like:
> > 
> >  
> > 
> <param-value>jdbc:oracle:thin:@jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS
> > =(PROT
> > 
> OCOL=TCP)(HOST=10.0.0.7)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=test))
> > )</par
> > am-value>
> > 
> > My problem is I'm getting this error:
> > 
> > 	NVFactory: _readNVPair expected
> > 
> > It doesn't seem to make any difference if I use the 8i or
> the 9i drivers.
> > 
> > I've also tried
> > 	
> > 	
> <param-value>jdbc:oracle:thin:@//10.0.0.7:1521/test</param-value>
> > 
> > But that just gave me a format error.
> > 
> > I can connect fine using sqlplus.
> > 
> > What am I doing wrong?
> > 
> > Thanks for the help. Merry Christmas!
> > 
> > 
> > 
> > 
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> > 
> > 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> 



---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


!DSPAM:41d08896130622933416230!

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: Need Consultant $$ [RE: Oracle 9i client connection to 8i database]

Posted by Tim Funk <fu...@joedog.org>.
It sounds like your using a type2 driver. Switch to the type 4 driver and you 
don't need and Oracle binaries (except the jar file) and things might work a 
little better.

-Tim

Brad Rhoads wrote:
>  
> Our web app needs to talk to oracle. All is well if the app runs on the db
> server. But at a client site and on our now on own network, if the app is on
> a different box, it can't get an oracle connection. It works fine on 2 boxes
> at other client sites.
> 
> A related item seems to be that since the change in our network (we just
> added a fire wall, the app itself has not changed), we have to change the
> Net8 configuration to use a service name instead of a sid.
> 
> The web app makes a connection using a sid. (I've been looking for way to
> change our connection to use a service name with no luck so far.)
> 
> We've had a similar problem when the app was outside the firewall, the db
> was behind it, and the firewall didn't allow high-ports through. But in the
> case of our client and our own case, both machines are behind the firewall.
> 
> I currently have the webapp running on the db server, but the client is very
> unhappy with this and my boss wants me to seek what ever help is necessary
> to resolve this problem. 
> 
> If you think you can help, please reply privately with your rate,
> availability. I think everything can be done remotely, but it might mean a
> trip to the client on Monday if we can't work it out by then.
> 
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


RE: Need Consultant $$ [RE: Oracle 9i client connection to 8i database]

Posted by Mike Jackson <mj...@cdi-hq.com>.
Try the type 4 driver and make sure that you're not NAT'ing the addresses
anywhere.  Oracle doesn't like NATs, you'll need a sqlnet proxy in order for
something like that to work.  I've used Cisco PIX firewalls which have a
sqlnet proxy built in.

--mikej
-=-----
mike jackson
mjackson@cdi-hq.com


> -----Original Message-----
> From: Brad Rhoads [mailto:brad@zethcon.com] 
> Sent: Wednesday, January 05, 2005 4:09 PM
> To: 'Tomcat Users List'
> Subject: Need Consultant $$ [RE: Oracle 9i client connection 
> to 8i database]
> Importance: High
> 
> 
>  
> Our web app needs to talk to oracle. All is well if the app 
> runs on the db server. But at a client site and on our now on 
> own network, if the app is on a different box, it can't get 
> an oracle connection. It works fine on 2 boxes at other client sites.
> 
> A related item seems to be that since the change in our 
> network (we just added a fire wall, the app itself has not 
> changed), we have to change the Net8 configuration to use a 
> service name instead of a sid.
> 
> The web app makes a connection using a sid. (I've been 
> looking for way to change our connection to use a service 
> name with no luck so far.)
> 
> We've had a similar problem when the app was outside the 
> firewall, the db was behind it, and the firewall didn't allow 
> high-ports through. But in the case of our client and our own 
> case, both machines are behind the firewall.
> 
> I currently have the webapp running on the db server, but the 
> client is very unhappy with this and my boss wants me to seek 
> what ever help is necessary to resolve this problem. 
> 
> If you think you can help, please reply privately with your 
> rate, availability. I think everything can be done remotely, 
> but it might mean a trip to the client on Monday if we can't 
> work it out by then.
> 
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> 
> 



---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Need Consultant $$ [RE: Oracle 9i client connection to 8i database]

Posted by Brad Rhoads <br...@zethcon.com>.
 
Our web app needs to talk to oracle. All is well if the app runs on the db
server. But at a client site and on our now on own network, if the app is on
a different box, it can't get an oracle connection. It works fine on 2 boxes
at other client sites.

A related item seems to be that since the change in our network (we just
added a fire wall, the app itself has not changed), we have to change the
Net8 configuration to use a service name instead of a sid.

The web app makes a connection using a sid. (I've been looking for way to
change our connection to use a service name with no luck so far.)

We've had a similar problem when the app was outside the firewall, the db
was behind it, and the firewall didn't allow high-ports through. But in the
case of our client and our own case, both machines are behind the firewall.

I currently have the webapp running on the db server, but the client is very
unhappy with this and my boss wants me to seek what ever help is necessary
to resolve this problem. 

If you think you can help, please reply privately with your rate,
availability. I think everything can be done remotely, but it might mean a
trip to the client on Monday if we can't work it out by then.




---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


RE: Oracle 9i client connection to 8i database

Posted by Brad Rhoads <br...@zethcon.com>.
 

> -----Original Message-----
> From: LERBSCHER Jean-Pierre 
> [mailto:jean-pierre.lerbscher@cofiroute.fr] 
> Sent: Wednesday, January 05, 2005 3:14 AM
> To: 'Tomcat Users List'
> Subject: RE : Oracle 9i client connection to 8i database
> 
> If you get this log
> 27-DEC-2004 16:58:11 *
> (CONNECT_DATA=(SID=test)(CID=(PROGRAM=)(HOST=__jdbc__)(USER=or
> acle))) *
> (ADDRESS=(PROTOCOL=tcp)(HOST=10.0.0.4)(PORT=33244)) * 
> establish * Perhaps you have to try 
> jdbc:oracle:thin:@10.0.0.4:33244:test with thin driver and 

HOST is the db server, not the client. And PORT is a the high-port that
Oracle responds on (I think).




---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


OCI Driver Usage [RE: Oracle 9i client connection to 8i database]

Posted by Brad Rhoads <br...@zethcon.com>.
 

> -----Original Message-----
> From: LERBSCHER Jean-Pierre 
> [mailto:jean-pierre.lerbscher@cofiroute.fr] 
> Sent: Wednesday, January 05, 2005 3:14 AM
* Perhaps you have to try 
> jdbc:oracle:oci:@<service_name> with oci driver.
> 
> > -----Original Message-----
> > From: Michael Echerer [mailto:mech@tngtech.com]
> > Sent: Saturday, December 25, 2004 4:08 AM
> > To: Tomcat Users List
> > Subject: Re: Oracle 9i client connection to 8i database
> > 
> > How come that you need an Oracle client installation at all
> > when you just want to use the Oracle thin JDBC driver? IHMO 
> > the client installation is only required for OCI thick drivers...


What do I need to do to try out the OCI drivers?

Will my existing code work? 

Anyone have an example?



---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org