简体   繁体   中英

Oracle 12C RAC on Solaris 11 - Random Connection Timeout

We are having issue whereby there is random connection timeout from our java application connecting to Oracle 12c R1 RAC. Both are on Solaris 11.

Caused by: java.sql.SQLRecoverableException: IO Error: The Network Adapter could not establish the connection
at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:743)
...
...
Caused by: java.net.SocketTimeoutException: connect timed out at java.net.PlainSocketImpl.socketConnection(NativeMethod)

And this happens only randomly , maybe once every three runs?

Any assistance is appreciated!!!! Thanks!

Which version of JDBC driver are you using ? If you are using the one which comes with 12.2.0.1 replace it by a newer one. We had the same issue here; connects are randomly failing. But its not a timout at all. The message "java.io.InterruptedIOException: Socket read timed out" is simply wrong.

The real issue is that the connect syscall is interrupted, as you can see from the dtrace probes

 23708/2:  connect(0x8, 0xFFFFFFFF7F2EDD54, 0x20)                = -1 Err#4
 23708/2:  lwp_sigmask(0x3, 0x4, 0x40)           = 0xFFFFFFFF 0
 23708/2:  setcontext(0x1, 0xFFFFFFFF7F2ED2D0, 0x0)              = 0 0
 23708/2:  connect(0x8, 0xFFFFFFFF7F2EDD54, 0x20)                = -1 Err#149

Please try the ojdbc.jar from Oracle Client 18.3 or 19.3

There is also a Patch for 12.2.0.1 Unpublished Bug 25977056 : AC: UNITS FOR TRANSPORT_CONNECT_TIMEOUT CHANGED WITH NO QUALIFIER.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM