Home » RDBMS Server » Networking and Gateways » SHARED SERVER MODE: connection refused (10.2.0.3 RDBMS, Windows 2000 - 32-bit)
SHARED SERVER MODE: connection refused [message #399464] Wed, 22 April 2009 06:19 Go to next message
jmoran
Messages: 6
Registered: April 2009
Junior Member
Hello,

I have configured 15 shared servers and 3 dispatchers (two for TCP and one for TCPS). We have a servlet configured with Apache Jserv; In dedicated server mode the servlet connects to the database without error, when I switch to shared server mode the servlet does not connect and the Jserv.log shows:

22/04/2009 11:21:53:222 BST] OutputBrowser/com.sx3.servlet.OutputBrowser: Attempting to send message to client: A database error occurred: java.sql.SQLException: Io exception: Connection refused(DESCRIPTION=(ERR=12504)) user = FSC
[22/04/2009 11:21:53:222 BST] javax.servlet.ServletException
at com.sx3.servlet.OutputBrowser.doGet(OutputBrowser.java, Compiled Code)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:499)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:588)
at org.apache.jserv.JServConnection.processRequest(JServConnection.java, Compiled Code)
at org.apache.jserv.JServConnection.run(JServConnection.java, Compiled Code)
at java.lang.Thread.run(Thread.java, Compiled Code)

I've have verified that the jar file containing servlet code is signed.
Does anyone have suggestions on how to resolve this?

Kind regards

John
Re: SHARED SERVER MODE: connection refused [message #399472 is a reply to message #399464] Wed, 22 April 2009 06:48 Go to previous messageGo to next message
Michel Cadot
Messages: 59793
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
ORA-12504: TNS:listener was not given the SID in CONNECT_DATA
 *Cause:  The SID was missing from the CONNECT_DATA.
 *Action: Check that the connect descriptor corresponding to the service
 name in TNSNAMES.ORA has an SID component in the CONNECT_DATA.

Regards
Michel
Re: SHARED SERVER MODE: connection refused [message #399476 is a reply to message #399472] Wed, 22 April 2009 06:59 Go to previous messageGo to next message
jmoran
Messages: 6
Registered: April 2009
Junior Member
Thanks Michel,
the JDBC connect string isuued in the servlet is the standard format, so the problem appears to be with the way this is being handled by the tns listener in shared server mode.
Does anyone know if there are additional tns config changes required for JDBC connections with shared server?

Kind regards
John
Re: SHARED SERVER MODE: connection refused [message #399496 is a reply to message #399464] Wed, 22 April 2009 08:41 Go to previous messageGo to next message
BlackSwan
Messages: 23058
Registered: January 2009
Senior Member
The Oracle listener is too dumb to know or care about the flavor of client making the request.
In other words it treats JDBC requests the same as OCI.

>so the problem appears to be with the way this is being handled by the tns listener in shared server mode.
The above statement has no basis in reality.
Re: SHARED SERVER MODE: connection refused [message #399497 is a reply to message #399496] Wed, 22 April 2009 08:48 Go to previous messageGo to next message
jmoran
Messages: 6
Registered: April 2009
Junior Member
Thanks,
I know the connect string submitted is the same and if the tns listener is handling the request the same as in dedicated mode, where is the error originating?

Regard
John
Re: SHARED SERVER MODE: connection refused [message #399498 is a reply to message #399497] Wed, 22 April 2009 08:52 Go to previous messageGo to next message
BlackSwan
Messages: 23058
Registered: January 2009
Senior Member
jmoran wrote on Wed, 22 April 2009 06:48
Thanks,
I know the connect string submitted is the same and if the tns listener is handling the request the same as in dedicated mode, where is the error originating?

Regard
John

Then submit a bug to Oracle via Service Request.
I switched to DEDICATED server mode more than a decade ago due to bad performance in SHARED mode, & have never looked back.
Re: SHARED SERVER MODE: connection refused [message #399520 is a reply to message #399464] Wed, 22 April 2009 13:29 Go to previous messageGo to next message
BlackSwan
Messages: 23058
Registered: January 2009
Senior Member
It has been 2+ years since I had a challenge between a Java app. & Oracle RDBMS.
This was an inhouse written application which was (ab)using Oracle V10.
IIRC, the error code was slightly different, but kind of the same; Connection Refused.
The Java App. was not using Connection Pooling & essentially created a newer connection/session for every SQL statement being executed.
With V10 Listener, it was made "smarter".
It was aware on the PROCESS limit for the DB & counted as new session were made "in real time".
A problem was that the Listener was not informed in real time as sessions got terminated.
When the Listener thought the PROCESS limit would be exceeded,
it would inform the App. the connection request failed.
Periodically the RDBMS informs the Listener about Current Session count & then for a while new session would be made.


Good Luck!
Re: SHARED SERVER MODE: connection refused [message #399799 is a reply to message #399520] Fri, 24 April 2009 02:53 Go to previous message
jmoran
Messages: 6
Registered: April 2009
Junior Member
Thanks for your help,
I've a suitable workaround which forces just the servlet component to use a dedicated connection.

Kind regards
John
Previous Topic: ora-12541 :tns :no listener
Next Topic: Connection Information
Goto Forum:
  


Current Time: Wed Nov 26 14:48:25 CST 2014

Total time taken to generate the page: 0.07046 seconds