ORACLE: Io exception: network adapter could not establish a connection

We get this error sporadically. With the same TNS, we can establish the correct database connections. But we see it in magazines when we make connections several times. The stack trace is shown below. This is a db connection to Oracle from a Linux machine and Java application. Any help is appreciated.

java.sql.SQLException: Io exception: the network adapter could not establish a connection at oracle.jdbc.driver.DatabaseError.throwSqlException (DatabaseError.java:112) at oracle.jdbc.driver.DatabaseError.throwSqlException (DatabaseError.java:146) at oracle.jdbc.driver.DatabaseError.throwSqlException (DatabaseError.java:255) in oracle.jdbc.driver.T4CConnection.logon (T4CConnection.javahaps87) at oracle.jdbc.driver.PhysicalConnection. (PhysicalConnection.java:439) at oracle.jdbc.driver.T4CConnection. (T4CConnection.java:165) at oracle.jdbc.driver.T4CDriverExtension.getConnection (T4CDriverExtension.java:35) in oracle.jdbc.driver.OracleDriver.connect (OracleDriver.java:801) in oracle.jdbc.pool.OracleData getPhysicalConnection (OracleDataSource.java:297) at oracle.jdbc.pool. Oracle .getPooledConnection (OracleConnectionPoolDataSource.java:94) at oracle.jdbc.pool.OracleImplicitConnectionCache.makeCacheConnection (OracleImplicitConnectionCache.java:1567) at oracle.jdbc.pool.OracleImplicitConnectionCache.getCachemponnec. OracleImplicitConnectionCache.getConnection (OracleImplicitConnectionCache.javahaps47) at oracle.jdbc.pool.OracleDataSource.getConnection (OracleDataSource.java: 404) in oracle.jdbc.pool.OracleDataSource.getConnection (OracleDataSource.java:189) in oracle.jdbc.pool.OracleDataSource.getConnection (OracleDataSource.java:165)

+8
linux oracle10g jdbc
source share
3 answers

try to execute

  • (obviously) IP address is incorrect - try PING
  • The port is not open or blocked by a firewall - try Telnet
  • The database listener is not working or is connected to another network interface - again TELNET should confirm this (also use the Oracle client tools to connect)
  • Local ports are not available for outgoing connections (unlikely) - only if you make thousands of connections or create hundreds of new connections every minute.
+10
source share

It looks like there are no connections in the connection pool ... When the DBMS request receive buffer is listening on many concurrent connection requests. This will not help some of them.

you can mix a bit (from half a second to a second) between consecutive connection requests. After that, do not close the connections until they break. Store them and reuse them.

+1
source share

Check https://forums.oracle.com/forums/thread.jspa?messageID=2540479 , maybe you should change the listener.ora host parameter to your host parameter. You can check which parameter is your hostname in Windows, cmd> hostname

0
source share

All Articles