Solved

org.apache.commons.dbcp.DbcpException: java.sql.SQLException: Io exception: The Network Adapter could not establish the connection

Posted on 2010-11-18
3
1,757 Views
Last Modified: 2012-05-10


I'm having this error msg while starting the app server

DBCP borrowObject failed: java.sql.SQLException: Io exception: The Network Adapter could not establish the connection
org.apache.commons.dbcp.DbcpException: java.sql.SQLException: Io exception: The Network Adapter could not establish the connection
      at org.apache.commons.dbcp.DriverConnectionFactory.createConnection(DriverConnectionFactory.java:85)
      at org.apache.commons.dbcp.PoolableConnectionFactory.makeObject(PoolableConnectionFactory.java:184)
      at org.apache.commons.pool.impl.GenericObjectPool.borrowObject(GenericObjectPool.java:816)
      at org.apache.commons.dbcp.AbandonedObjectPool.borrowObject(AbandonedObjectPool.java:117)
      at org.apache.commons.dbcp.PoolingDataSource.getConnection(PoolingDataSource.java:110)
      at org.apache.commons.dbcp.BasicDataSource.getConnection(BasicDataSource.java:312)
      at com.newbreed.enbrace.fx.dao.Dao.getDbConnection(Dao.java:136)
      at com.newbreed.enbrace.fx.dao.session.SessionDAOImpl.sweep(SessionDAOImpl.java:169)
      at com.newbreed.enbrace.fx.security.SessionSweeperServlet.timerAction(SessionSweeperServlet.java:72)
      at com.newbreed.enbrace.fx.util.CronTimer.timerAction(CronTimer.java:142)
      at com.newbreed.enbrace.fx.util.TimerThread.run(Timer.java:36)
Caused by: java.sql.SQLException: Io exception: The Network Adapter could not establish the connection
      at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:114)
      at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:156)
      at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:269)
      at oracle.jdbc.driver.OracleConnection.<init>(OracleConnection.java:210)
      at oracle.jdbc.driver.OracleDriver.getConnectionInstance(OracleDriver.java:251)
      at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:224)
      at org.apache.commons.dbcp.DriverConnectionFactory.createConnection(DriverConnectionFactory.java:83)

I can log in to the server but it gives

HTTP Status 500 -

--------------------------------------------------------------------------------

type Exception report

message

description The server encountered an internal error () that prevented it from fulfilling this request.

exception

org.apache.commons.dbcp.DbcpException: java.sql.SQLException: Io exception: The Network Adapter could not establish the connection
      org.apache.commons.dbcp.DriverConnectionFactory.createConnection(DriverConnectionFactory.java:85)
      org.apache.commons.dbcp.PoolableConnectionFactory.makeObject(PoolableConnectionFactory.java:184)
      org.apache.commons.pool.impl.GenericObjectPool.borrowObject(GenericObjectPool.java:816)
      org.apache.commons.dbcp.AbandonedObjectPool.borrowObject(AbandonedObjectPool.java:117)
      org.apache.commons.dbcp.PoolingDataSource.getConnection(PoolingDataSource.java:110)
      org.apache.commons.dbcp.BasicDataSource.getConnection(BasicDataSource.java:312)
      com.newbreed.enbrace.fx.dao.Dao.getExternalDbConnection(Dao.java:86)
      com.newbreed.enbrace.fx.security.login.LoginAction.perform(LoginAction.java:86)
      org.apache.struts.action.ActionServlet.processActionPerform(ActionServlet.java:1787)
      org.apache.struts.action.ActionServlet.process(ActionServlet.java:1586)
      org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:510)
      javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
      javax.servlet.http.HttpServlet.service(HttpServlet.java:810)


note The full stack trace of the root cause is available in the Apache Tomcat/5.0.25 logs.


--------------------------------------------------------------------------------

Apache Tomcat/5.0.25

Please give the solution, its very urgent.

thanks in advance
0
Comment
Question by:nbuser
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 2

Accepted Solution

by:
ckiral earned 500 total points
ID: 34167528
It looks like a connection pool problem.
Apparently you are using oracle as backend db.
Please check if you have nework connectivity to db server from application server.
You may also check if oracle listener is accepting connections from your app server.

0
 

Author Comment

by:nbuser
ID: 34168408
Thank you very much.  I resolved the problem.  

Thanks
0
 
LVL 2

Expert Comment

by:ckiral
ID: 34168482
Happy hear that. Was it a connectivity issue?
0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When it comes to showing a 404 error page to your visitors, you do not want that generic page to show, and you especially do not want your hosting provider’s ad error page to show either. In this article, I will show you how to enable the custom 40…
Meet the world's only “Transparent Cloud™” from Superb Internet Corporation. Now, you can experience firsthand a cloud platform that consistently outperforms Amazon Web Services (AWS), IBM’s Softlayer, and Microsoft’s Azure when it comes to CPU and …
After creating this article (http://www.experts-exchange.com/articles/23699/Setup-Mikrotik-routers-with-OSPF.html), I decided to make a video (no audio) to show you how to configure the routers and run some trace routes and pings between the 7 sites…
After creating this article (http://www.experts-exchange.com/articles/23699/Setup-Mikrotik-routers-with-OSPF.html), I decided to make a video (no audio) to show you how to configure the routers and run some trace routes and pings between the 7 sites…

696 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question