I wrote an executable jar package to execute on Linux, connected to Oracle 11g database and obtained database data. It was always the card owner. When it timed out, it ran out with an error message. The server could be restarted several times, and it was stuck later.
Execute jar package statement
/root/jdk1.8.0_ 181/bin/java -jar GetJdbc-1.0-SNAPSHOT.jar
java.sql.SQLRecoverableException: IO Error: Connection reset
at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:421)
at oracle.jdbc.driver.PhysicalConnection.<init>(PhysicalConnection.java:531)
at oracle.jdbc.driver.T4CConnection.<init>(T4CConnection.java:221)
at oracle.jdbc.driver.T4CDriverExtension.getConnection(T4CDriverExtension.java:32)
at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:503)
at java.sql.DriverManager.getConnection(DriverManager.java:664)
at java.sql.DriverManager.getConnection(DriverManager.java:247)
at com.iwhalecloud.jdbc.utils.GetDataSource.getConnection(GetDataSource.java:27)
at com.iwhalecloud.jdbc.execute.DistinguishDataSource.oracleQuery(DistinguishDataSource.java:78)
at com.iwhalecloud.jdbc.execute.DistinguishDataSource.dataHandle(DistinguishDataSource.java:34)
at com.iwhalecloud.jdbc.main.MainProgram.main(MainProgram.java:26)
Caused by: java.net.SocketException: Connection reset
at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:115)
at java.net.SocketOutputStream.write(SocketOutputStream.java:155)
at oracle.net.ns.DataPacket.send(DataPacket.java:199)
at oracle.net.ns.NetOutputStream.flush(NetOutputStream.java:211)
at oracle.net.ns.NetInputStream.getNextPacket(NetInputStream.java:227)
at oracle.net.ns.NetInputStream.read(NetInputStream.java:175)
at oracle.net.ns.NetInputStream.read(NetInputStream.java:100)
at oracle.net.ns.NetInputStream.read(NetInputStream.java:85)
at oracle.jdbc.driver.T4CSocketInputStreamWrapper.readNextPacket(T4CSocketInputStreamWrapper.java:122)
at oracle.jdbc.driver.T4CSocketInputStreamWrapper.read(T4CSocketInputStreamWrapper.java:78)
at oracle.jdbc.driver.T4CMAREngine.unmarshalUB1(T4CMAREngine.java:1179)
at oracle.jdbc.driver.T4CMAREngine.unmarshalSB1(T4CMAREngine.java:1155)
at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:279)
at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:186)
at oracle.jdbc.driver.T4CTTIoauthenticate.doOAUTH(T4CTTIoauthenticate.java:366)
at oracle.jdbc.driver.T4CTTIoauthenticate.doOAUTH(T4CTTIoauthenticate.java:752)
at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:359)
... 10 more
close
Exception in thread "main" java.lang.NullPointerException
at com.iwhalecloud.jdbc.execute.DistinguishDataSource.oracleQuery(DistinguishDataSource.java:80)
at com.iwhalecloud.jdbc.execute.DistinguishDataSource.dataHandle(DistinguishDataSource.java:34)
at com.iwhalecloud.jdbc.main.MainProgram.main(MainProgram.java:26)
Find an effective solution on the Internet and add a parameter – DJava. Security. EGD = file:/dev /../dev/urandom
The execution statement is as follows
/root/jdk1.8.0_ 181/bin/java -jar -Djava.security.egd=file:/dev/../dev/urandom GetJdbc-1.0-SNAPSHOT.jar
Read More:
- Solve the problem caused by: java.sql.SQLRecoverableException : IO error: connection reset related problems
- Caused by: java.net.SocketException : connection reset or caused by: java.sql.SQLRecoverableException solve
- Java connection SQL error, network error IO Exception:Connection refused :connect
- java.sql.SQLException : IO exception: socket read timed out
- java.sql.SQLException: The Network Adapter could not establish the connection
- java.sql.SQLException : IO error: socket read timed out!
- Java 11.0.11 SQL Server connection error
- JDBC connection to Oracle: listener used the connection with the following error: ora-12505
- ConnectionResetError: [Errno 104] Connection reset by peer
- Failed to load resource: net::ERR_CONNECTION_RESET
- About connection reset by peer: socket write error
- Nginx: recv() failed (104: connection reset by peer) troubleshooting
- subsystem request failed on channel 0 Couldn’t read packet: Connection reset by peer
- SQL 2005 remote connection error (provider: SQL network interface, error: 28 – the server does not support the requested protocol
- Cause: java.sql.SQLSyntaxErrorException: You have an error in your SQL syntax; check the
- Process of checking the error of connection reset by peer reported by reactor netty
- Cause: java.sql.SQLException: Error setting driver on UnpooledDataSource. Cause: java.lang.ClassNot
- The browser console reports failed to load resource: net :: ERR_CONNECTION_RESET, which results in unable to log in
- SQL state [null]; error code [0]; Error; nested exception is java.sql.SQLException: Error] with root
- MySql 8.x java.sql.SQLNonTransientConnectionException: Public Key Retrieval is not allowed