Hello,
I am trying to do a jdbc connection to sybase ssl enabled database.
I am able to connect to database via isql64 for both ssl and non-ssl db connection.
But jdbc connection for ssl isn't working.
Getting following errors/exceptions:
→jdbcurl=jdbc:sybase:Tds:phoenix524618.dev3sub1phx.databasede3phx.oraclevcn.com:5000/qa_db?ENABLE_SSL=true
Exception in thread "main" java.lang.Exception: java.sql.SQLException: JZ006: Caught IOException: java.net.ConnectException: Connection refused (Connection refused)
at testSybase.dbconn(testSybase.java:20)
at testSybase.main(testSybase.java:51)
Caused by: java.sql.SQLException: JZ006: Caught IOException: java.net.ConnectException: Connection refused (Connection refused)
at com.sybase.jdbc4.jdbc.ErrorMessage.raiseError(ErrorMessage.java:819)
at com.sybase.jdbc4.jdbc.ErrorMessage.raiseErrorCheckDead(ErrorMessage.java:1250)
at com.sybase.jdbc4.tds.Tds.handleIOE(Tds.java:5384)
at com.sybase.jdbc4.tds.Tds.handleIOE(Tds.java:5329)
at com.sybase.jdbc4.tds.Tds.login(Tds.java:571)
at com.sybase.jdbc4.jdbc.SybConnection.tryLogin(SybConnection.java:529)
at com.sybase.jdbc4.jdbc.SybConnection.handleHAFailover(SybConnection.java:3861)
at com.sybase.jdbc4.jdbc.SybConnection.<init>(SybConnection.java:382)
at com.sybase.jdbc4.jdbc.SybConnection.<init>(SybConnection.java:282)
at com.sybase.jdbc4.jdbc.SybDriver.connect(SybDriver.java:258)
at java.sql.DriverManager.getConnection(DriverManager.java:664)
at java.sql.DriverManager.getConnection(DriverManager.java:247)
at testSybase.dbconn(testSybase.java:14)
... 1 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:607)
at sun.security.ssl.SSLSocketImpl.connect(SSLSocketImpl.java:293)
at com.sybase.jdbc4.jdbc.SybSSLSocketFactory.createSocket(SybSSLSocketFactory.java:340)
at com.sybase.jdbc4.timedio.SocketDbio.doConnect(SocketDbio.java:98)
at com.sybase.jdbc4.timedio.InStreamMgr.<init>(InStreamMgr.java:109)
at com.sybase.jdbc4.tds.Tds.login(Tds.java:537)
... 9 more