jdbc.SQLServerConnection is getting lost

1,279 views
Skip to first unread message

Simon Haidinger

unread,
Apr 17, 2015, 10:19:28 AM4/17/15
to ra...@googlegroups.com
Hello together,

we got a problem for one of our clients railo application. Mostly on the weekend the server is not available. It seems that we got a SQL issue but we weren't able to solve this issue yet.
The host of this server said that the SQL Server was still available at this time, so there must be an issue with railo he said.

Also playing around with differnt Datasource-Types (Railo-Admin) didn't help:
- MSSQL - Microsoft SQL Server (Vendor Microsoft)
- Vendor jTDS
- Other JDBC Driver

We have also tried to configure the connection limit ... without success.
Just if we restart the railo & apache service we are save for undefined time (sometimes 1 week without any problem)


After trying a simple query we got this message

Msg 701, Level 17, State 123, Line 1

There is insufficient system memory in resource pool 'internal' to run this query.


and in the tomcat logs we can always find


WARNING: ConnectionID:17341 ClientConnectionId: ... Prelogin error: host ... port 6205 Error reading prelogin response: Connection reset ClientConnectionId:...

Mar 27, 2015 7:55:27 PM com.microsoft.sqlserver.jdbc.SQLServerConnection Prelogin


Here some informations of our application

Railo Version: Railo 4.2.1.000 final
Linux: Linux (3.0.101-0.47.52-default) 64bit
Apache: Apache Tomcat/7.0.53
SQL: Microsoft SQL Server 2008 R2 (SP2)

Java Version: java version "1.7.0" (going to upgrade to JAVA 8)

Would be great if somebody could help us.

Kind regards

Simon





Simon Haidinger

unread,
Apr 27, 2015, 7:22:29 AM4/27/15
to ra...@googlegroups.com

Additionaly we got this message today ... just restarted railo service again and all works ...

I/O Error: Connection reset at net.sourceforge.jtds.jdbc.TdsCore.nextToken(TdsCore.java:2387):2387 at net.sourceforge.jtds.jdbc.TdsCore.login(TdsCore.java:614):614 at net.sourceforge.jtds.jdbc.ConnectionJDBC2.<init>(ConnectionJDBC2.java:356):356 at net.sourceforge.jtds.jdbc.ConnectionJDBC3.<init>(ConnectionJDBC3.java:50):50 at net.sourceforge.jtds.jdbc.Driver.connect(Driver.java:185):185 at java.sql.DriverManager.getConnection(DriverManager.java:664):664 at java.sql.DriverManager.getConnection(DriverManager.java:247):247 at railo.commons.db.DBUtil.getConnection(DBUtil.java:86):86 at railo.runtime.db.DatasourceConnectionPool.loadDatasourceConnection(DatasourceConnectionPool.java:74):74 at railo.runtime.db.DatasourceConnectionPool.getDatasourceConnection(DatasourceConnectionPool.java:66):66 at railo.runtime.db.DatasourceManagerImpl.getConnection(DatasourceManagerImpl.java:49):49 at railo.runtime.tag.Query.executeDatasoure(Query.java:687):687 at railo.runtime.tag.Query.doEndTag(Query.java:533):533

Kind regards

Simon Haidinger


Am Freitag, 17. April 2015 16:19:28 UTC+2 schrieb Simon Haidinger:
Hello together,

we got a problem for one of our clients railo application. Mostly on the weekend the server is not available. It seems that we got a SQL issue but we weren't able to solve this issue yet.
The host of this server said that the SQL Server was still available at this time, so there must be an issue with railo he said.

Also playing around with differnt Datasource-Types (Railo-Admin) didn't help:
- MSSQL - Microsoft SQL Server (Vendor Microsoft)
- Vendor jTDS
- Other JDBC Driver

We have also tried to configure the connection limit ... without success.
Just if we restart the railo & apache service we are save for undefined time (sometimes 1 week without any problem)


After trying a simple query we got this message

Msg 701, Level 17, State 123, Line 1

There is insufficient system memory in resource pool 'internal' to run this query.


and in the tomcat logs we can always find


WARNING: ConnectionID:17341 ClientConnectionId: ... Prelogin error: host ... port 6205 Error reading prelogin response: Connection reset ClientConnectionId:...

Mar 27, 2015 7:55:27 PM com.microsoft.sqlserver.jdbc.SQLServerConnection Prelogin


...

Cameron Childress

unread,
Apr 30, 2015, 10:41:40 AM4/30/15
to ra...@googlegroups.com
On Fri, Apr 17, 2015 at 5:13 AM, Simon Haidinger wrote:

Msg 701, Level 17, State 123, Line 1

There is insufficient system memory in resource pool 'internal' to run this query.


When I cut and paste this error into a Google search a whole lot of very on-topic posts come up describing exactly what this problem is and how to fix it. Hopefully I won't spoil the mystery of you doing this yourself by saying that link one and two suggested that 1) a SQL Server configuration change will resolve the problem and 2) MS has issued a patch to fix this problem.

The reason that restarting Railo seems to fix it is probably that it resets all the dead JDBC connections waiting to get a reply from a busted SQL Server that is never going to reply. ACF and Railo both seem to sometimes have issues when the database server doesn't respond for some reason. The threads get used up and it hangs.

-Cameron

--
Cameron Childress
--
p:   678.637.5072
im: cameroncf
Reply all
Reply to author
Forward
0 new messages