今天下午,测试环境清算的时候又出现了之前的一个异常,这次把错误信息全部打出来了,java.sql.SQLException: 无法从套接字读取更多的数据,是使用mycat连接oracle的,如下所示:

ORA-17410: No more data to read from socket

Your database connection has timed out, either due to network problems or due to Oracle reaching the IDLE_TIME profile limit.

Your application however tried to use the connection, but as the connection has closed, failed to do so. 
This error mostly happens when using connection pools. Normally, when a connection is timed out or gone, the application should automatically reconnect. 
Failure to do so results in this error.

经查,oracle后台以及alert.log没有任何异常,也不应该是oracle jdbc驱动的问题,trace文件也没有异常。

看了下mycat.log,13:00之后,心跳就没发了,如下:

重启mycat之后,应用没有重启,再次运行,就没有这个问题了。之前也是,mycat经常遇到各种奇葩问题,因为我们是两台虚拟机,不排除网络不稳定,但是都没有解决方案。看下用的是dataHost的连接数都很大,应该不是这个问题,只有三个心跳日志是因为配置了三个dataHost。

不过我们已经打算切换sharding-jdbc了。

参考:

https://blog.csdn.net/liduote/article/details/70227040

https://blog.csdn.net/sinat_33517300/article/details/78968181

http://www.iteye.com/problems/38600

https://blog.csdn.net/xiaopeng187/article/details/25797885

mycat->oracle报java.sql.SQLException: 无法从套接字读取更多的数据的更多相关文章

  1. sql查询报java.sql.SQLException: Column 'LC_ID' not found 的错误实际上是mysql在hibernate别名的问题

    报java.sql.SQLException: Column 'LC_ID' not found 的错误实际上是mysql在hibernate别名的问题 我的查询sql是 String sql2 =& ...

  2. java.sql.SQLException:连接是只读的。不允许导致数据修改的查询

    我的项目中 service的实现类少了写一个注解   : 只读事务(@Transactional(readOnly = true) 应用场合: 如果你一次执行单条查询语句,则没有必要启用事务支持,数据 ...

  3. java程序连接oracle12c报:java.sql.SQLException: ORA-28040: 没有匹配的验证协议。

    报错信息: 2017-09-22 15:17:37,204 WARN [org.hibernate.cfg.SettingsFactory] - Could not obtain connection ...

  4. spring+ibatis问题1—— 程序报错:java.sql.SQLException: Io 异常: Connection reset by peer, socket write error; ”或“java.sql.SQLException 关闭的连接”异常

    转自:http://blog.sina.com.cn/s/blog_1549fb0710102whz2.html spring+ibatis程序测试时报错:java.sql.SQLException: ...

  5. java.sql.SQLException: Io 异常: Connection reset

    当数据库连接池中的连接被创建而长时间不使用的情况下,该连接会自动回收并失效,但客户端并不知道,在进行数据库操作时仍然使用的是无效的数据库连接,这样,就导致客户端程序报“ java.sql.SQLExc ...

  6. 解决java.sql.SQLException: The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than one time zone

    使用spring boot整合MySQL时一直报 java.sql.SQLException: The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecog ...

  7. java.sql.SQLException: Incorrect string value: '\xE5\xB0‘

    mysql插入中文字符报java.sql.SQLException: Incorrect string value: '\xE5\xB0‘ #原因:由于默认情况下,mysql的字符集是latin1(I ...

  8. java之java.sql.SQLException: ResultSet is from UPDATE. No Data.

    问题解释:java调用存储过程的时候,查询结果不能通过ResultSet来查询,需要通过CallableStatement来查询, 比如: ResultSet rs = callableStateme ...

  9. java.sql.SQLException: Field 'id' doesn't have a default value解决方案

    转自:https://blog.csdn.net/xinghuo0007/article/details/51810867 自增长:java.sql.SQLException: Field 'id' ...

随机推荐

  1. JS--理解call、apply和bind

    call.apply和bind call,apply是Function原型中的方法,它们的作用一样,区别在于传入参数的方式不同. call(thisArg, arg1, arg2...) 传入的参数不 ...

  2. MySQL--5子查询与连接小结

    子查询:出现在其他sql语句中的 SELECT,必须出现在小括号内,子查询外层可以是常见的SELECT语句,INSERT语句 UPDATE语句 DELETE语句,在子查询中可以包含多个关键字和条件 ( ...

  3. css3径向渐变

    #grad2 { height: 440px; width: 440px; border-radius: %; background: -webkit-radial-gradient(closest- ...

  4. 数据加密之DES加密

    DES加密即使用DESCryptoServiceProvider加密.DESCryptoServiceProvider在命名空间下:System.Security.Cryptography; 对称加密 ...

  5. webpack使用四

    鼎鼎大名的Loaders登场了! Loaders是webpack提供的最激动人心的功能之一了.通过使用不同的loader,webpack有能力调用外部的脚本或工具,实现对不同格式的文件的处理,比如说分 ...

  6. Python全栈-day8-day9-函数1

    函数 day8 1.为什么需要函数 1)代码的组织结构不清晰,可读性差 2)需要重复使用某个功能时,需要重新编写成程序,重复率高 3)多处引用相同代码时,需要扩展功能的时候过于麻烦,工作量大 2.函数 ...

  7. LoadLibrary加载动态库失败

    [1]LoadLibrary加载动态库失败的可能原因以及解决方案: (1)dll动态库文件路径不对.此场景细分为以下几种情况: 1.1 文件路径的确错误.比如:本来欲加载的是A文件夹下的动态库a.dl ...

  8. NGINX的几个应用场景

    NGINX的几个应用场景 两个参考地址: NGINX的百度百科:https://baike.baidu.com/item/nginx/3817705?fr=aladdin NGINX的中文网站:htt ...

  9. tensorflow--variable_scope

    1.with tf.variable_scope(name , reuse = reuse) (1)创建variable scope with tf.variable_scope("foo& ...

  10. CXF框架入门(重点)

    l CXF是一个开源的webservice框架 l CXF支持的协议:SOAP.XML/HTTP等 l CXF可以很好的和spring集成 l CXF可以部署到tomcat.jboss.jetty等服 ...