Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Oracle 19.3 driver problem on Linux #2513

Closed
juliahayward opened this issue Sep 23, 2019 · 3 comments
Closed

Oracle 19.3 driver problem on Linux #2513

juliahayward opened this issue Sep 23, 2019 · 3 comments

Comments

@juliahayward
Copy link
Contributor

According to https://medium.com/@kuassimensah/oracle-jdbc-drivers-on-maven-central-64fcf724d8b the Oracle JDBC driver and associated jars are now available on Maven Central. We will check that they are now redistributable, and if so include them by default.

@juliahayward juliahayward changed the title Ship Oracle JDBC drivers by default, when allwoed to Ship Oracle JDBC drivers by default, when allowed to Sep 23, 2019
@juliahayward
Copy link
Contributor Author

I'm going to put this on hold for now as there's a problem with the 19.3 drivers we have yet to solve. Specifically against a 19.3 database, everything is fine on Windows but on our build server and on WSL with OpenJdk 11.0.3, we can't get a connection:

ERROR: Unexpected error
org.flywaydb.core.internal.exception.FlywaySqlException:
Unable to obtain connection from database (jdbc:oracle:thin:@//localhost:62064/ORCLPDB1) for user 'pdbadmin': IO Error: Invalid argument, Authentication lapse 0 ms.
--------------------------------------------------------------------------------------------------------------------------------------------------------------------
SQL State  : 08006
Error Code : 17002
Message    : IO Error: Invalid argument, Authentication lapse 0 ms.

        at org.flywaydb.core.internal.jdbc.JdbcUtils.openConnection(JdbcUtils.java:60)
        at org.flywaydb.core.internal.jdbc.JdbcConnectionFactory.<init>(JdbcConnectionFactory.java:80)
        at org.flywaydb.core.Flyway.execute(Flyway.java:431)
        at org.flywaydb.core.Flyway.info(Flyway.java:307)
        at org.flywaydb.commandline.Main.executeOperation(Main.java:170)
        at org.flywaydb.commandline.Main.main(Main.java:111)
Caused by: java.sql.SQLRecoverableException: IO Error: Invalid argument, Authentication lapse 0 ms.
        at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:874)
        at oracle.jdbc.driver.PhysicalConnection.connect(PhysicalConnection.java:793)
        at oracle.jdbc.driver.T4CDriverExtension.getConnection(T4CDriverExtension.java:57)
        at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:747)
        at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:562)
        at org.flywaydb.core.internal.jdbc.DriverDataSource.getConnectionFromDriver(DriverDataSource.java:447)
        at org.flywaydb.core.internal.jdbc.DriverDataSource.getConnection(DriverDataSource.java:413)
        at org.flywaydb.core.internal.jdbc.JdbcUtils.openConnection(JdbcUtils.java:56)
        ... 5 more
Caused by: java.io.IOException: Invalid argument, Authentication lapse 0 ms.
        at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:870)
        ... 12 more
Caused by: java.io.IOException: Invalid argument
        at java.base/sun.nio.ch.SocketChannelImpl.sendOutOfBandData(Native Method)
        at java.base/sun.nio.ch.SocketChannelImpl.sendOutOfBandData(SocketChannelImpl.java:521)
        at java.base/sun.nio.ch.SocketAdaptor.sendUrgentData(SocketAdaptor.java:323)
        at oracle.net.nt.TcpNTAdapter.sendUrgentByte(TcpNTAdapter.java:433)
        at oracle.net.ns.NSProtocolNIO.negotiateConnection(NSProtocolNIO.java:159)
        at oracle.net.ns.NSProtocol.connect(NSProtocol.java:340)
        at oracle.jdbc.driver.T4CConnection.connect(T4CConnection.java:1596)
        at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:588)
        ... 12 more

@juliahayward juliahayward changed the title Ship Oracle JDBC drivers by default, when allowed to Oracle 19.3 driver problem on Linux Dec 4, 2019
@alextercete alextercete added this to the Flyway 6.x milestone Dec 16, 2019
@MikielAgutu MikielAgutu modified the milestones: Flyway 6.x, Flyway 6.3 Feb 5, 2020
@juliahayward
Copy link
Contributor Author

juliahayward commented Feb 11, 2020

Not the best of answers, but ojdbc10.jar may be a solution for higher JDKs (clearly we need ojdbc8 for compatibility with older ones) https://stackoverflow.com/questions/58319173/cant-connect-to-oracle-19-3-with-19-3-jdbc-driver

@Lyeeedar Lyeeedar modified the milestones: Flyway 6.3, Flyway 6.x Feb 19, 2020
@juliahayward
Copy link
Contributor Author

Had another answer on SO and this time it is good. Disabling out-of-band-break is harmless with the 18.3 driver, and Flyway works as expected with the 19.6 driver. https://stackoverflow.com/questions/58319173/cant-connect-to-oracle-19-3-with-19-3-jdbc-driver/62078980#62078980

juliahayward added a commit that referenced this issue Jun 1, 2020
#2513 Fix issue with Oracle 19.x driver on Linux
@MikielAgutu MikielAgutu removed this from the Flyway 6.x milestone Sep 30, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants