I am able to connect when using TCP port , but having issues connecting to TCPS port.
I have copied valid cacerts file to Java location. It fails with below expection:
SQLRecoverableException: IO Error: Got minus one from a read call
Hey @RajuK
I can't help per se, cos I haven't setup an Oracle connection using a cacerts file before, but I'd double check everything as follows:
confirm what version of Oracle RDBMS youre connecting to
download the relevant jdbc driver .jar file relative to the version of Oracle youre connecting to
download the relevant jdk (rather than jre) to support the jdbc connection .jar
read the following link to determine the correct approach (relative to the oracle version, java version, SSL vs TLS type) and go from there (e.g. oracle wallet?, JKS?, TLSv1.2?)
download the relevant additional .jars needed to connect using SSL
make sure you're copying the .jar files to the correct directory
identify whether youre connecting to SID or Service Name as this alters the jdbc connection string
confirm the jdbc connection string parameters are correct - depending on the attributes of the remote db you're connecting to alters the parameters required in the connection string (so you might have to alter the default oracle connection string defined in ReadyAPI!s JDBC settings (in the Preferences).
this link might help also
I've had issues trying to connect to remote database before with ReadyAPI!, so to strip out the additional complication of setting up a connection in ReadyAPI! I try setting up a connection in a DB interrogation tool like DBVisualiser or TOAD or whatever. If the connection settings are correct and work in DBVisualiser I then just copy the same details across in ReadyAPI! as these will work.
That's all I got I'm afraid - hope this helps!
ta,
rich
Thanks Richie.
Actually I found a work around.
We could use the below format for JDBC url to connect to Oracle DB on TCPS and use generated Java cacerts.
JDBCURL:
USER/PASS_VALUE@(DESCRIPTION=(ADDRESS=(PROTOCOL=TCPS)(HOST=hostname)(PORT=2484))(CONNECT_DATA=(SERVICE_NAME=servicename)))
ReadyApi did not provide a way to configure JDBC url with this format. So I have updated the project.xml file to reflect the above format and it works now.
Yes,
Except I could not do "edit within the ReadyAPI! JDBC Preferences", hence I updated the xml file using xml editor.
SmartBear provided a solution which I am going to try.
And like you said there is a way to update the JDBC .
I am going to try today. Thanks.
Solution from Smart Bear:
-Doracle.net.tns_admin={file location} in the {ReadyAPI install}\bin\ReadyAPI.vmoptions
After this, you can add a new connection string template or modify an existing one in Preferences > JDBC Drivers:
jdbc:oracle:thin:<USER>/<PASSWORD>@<TNSName>
In this case, you will need to use the manual JDBC Request test step configuration. Choose None for the Connection and click Configure. Fill in your credentials in the Database configuration dialog and specify the TNSName in the Connection string field.
Thank you for sharing this! Was this a success?
Subject | Author | Latest Post |
---|---|---|