Hi All,
I would need help here to identify the root cause for this issue.I have a Java application located in Solaris server. This application is accessing to database and all these while had been working fine until recently when we had our regular server maintenance activity which involve update the patch and reboot the server. There is a watchdog which will startup this application after the reboot and the application is working fine after the reboot. However a few hours later, the application hit IO Error: The Network Adapter could not establish the connection. After restarting the application manually, it is working as normal again. Auto restart application by watchdog is not working for this scenario as this application is working in multi thread mode. When this issue happen, only 1 thread is affected while other threads are still working normally. Hence, watchdog assumes that this application is up and running fine, therefor application restart is not required.
I had checked with my DBA if there is any issue in database or if database is having a network issue but we found nothing out of ordinary in the database during the start of the incident. Below is the error message produce during the incident:
IO Error: The Network Adapter could not establish the connection
java.sql.SQLRecoverableException: IO Error: The Network Adapter could not establish the connection
at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:489)
at oracle.jdbc.driver.PhysicalConnection.<init>(PhysicalConnection.java:553)
at oracle.jdbc.driver.T4CConnection.<init>(T4CConnection.java:254)
at oracle.jdbc.driver.T4CDriverExtension.getConnection(T4CDriverExtension.java:32)
at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:528)
at java.sql.DriverManager.getConnection(DriverManager.java:664)
at java.sql.DriverManager.getConnection(DriverManager.java:247)
at com.infineon.logicload.thread.DataRemoveThread.connect(DataRemoveThread.java:68)
at com.infineon.logicload.thread.DataRemoveThread.run(DataRemoveThread.java:93)
Caused by: oracle.net.ns.NetException: The Network Adapter could not establish the connection
at oracle.net.nt.ConnStrategy.execute(ConnStrategy.java:439)
at oracle.net.resolver.AddrResolution.resolveAndExecute(AddrResolution.java:454)
at oracle.net.ns.NSProtocol.establishConnection(NSProtocol.java:693)
at oracle.net.ns.NSProtocol.connect(NSProtocol.java:251)
at oracle.jdbc.driver.T4CConnection.connect(T4CConnection.java:1140)
at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:340)
... 8 more
Caused by: java.net.ConnectException: Connection refused (Connection refused)
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:350)
at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206)
at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
at java.net.Socket.connect(Socket.java:589)
at oracle.net.nt.TcpNTAdapter.connect(TcpNTAdapter.java:149)
at oracle.net.nt.ConnOption.connect(ConnOption.java:133)
at oracle.net.nt.ConnStrategy.execute(ConnStrategy.java:405)
Could this be due to application not stable after server maintenance? This application had been in used for more than 10 years and this is the first time it happen.