Issue

ColdFusion MX raises an error similar to the following when TCP connections threads become unavailable on Windows during a SQL Server query:

"SQLException while attempting to connect: java.sql.SQLException: [Macromedia][SQLServer JDBC Driver]Error establishing socket. No buffer space available (maximum connections reached?): JVM_Bind

[Macromedia][SQLServer JDBC Driver]Error establishing socket. No buffer space available (maximum connections reached?): JVM_Bind"

Reason

This error typically occurs when a database query is called and there are a large number of TCP connections in TIME_WAIT state -- the interval between when the connection is closed and when its release back into the pool for reuse. By default this interval is four (4) minutes. If there is a large number of connections on the server, then each connection can wait up to 4 minutes before their resources are released for reuse by other connections.

Solution

Decreasing the TIME_WAIT interval will allow TCP to release closed connections faster, thus increasing the number of available resources for open connections. The TIME_WAIT value is governed by the TCPTimedWaitDelay Windows Registry setting.

You should also install the latest database drivers; see "Updated DataDirect JDBC Drivers (version 3.5)" (TechNote 42dcb10a).

Additional Information

This work is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 3.0 Unported License  Twitter™ and Facebook posts are not covered under the terms of Creative Commons.

Legal Notices   |   Online Privacy Policy