標籤:com 分享圖片 兩台 image sha app 奇葩 方案 except
今天下午,測試環境清算的時候又出現了之前的一個異常,這次把錯誤資訊全部打出來了,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了。
參考:
70227040
78968181
http://www.iteye.com/problems/38600
25797885
mycat->oracle報java.sql.SQLException: 無法從通訊端讀取更多的資料