Search code examples
javasql-serverjdbcwindows-server-2008apache-commons-dbcp

Is this error related to the OS or the database?


I have a java programs that gives me an error after working fine for a few hours ... these programs used to work fine on our earlier server which had windows server 2003 now we have upgraded to windows server 2008 with a higher configuration and newly installed SQL Server .Is there any db setting that i'm missing or is there any OS setting that i've missed out ??

the EXCEPTION i receive is :

Error::

org.apache.commons.dbcp.SQLNestedException:Cannot create PoolableConnectionFactory, cause: Network error

IOException: No buffer space available (maximum connections reached?): connect


Solution

  • I have experienced a similar issue on Windows and had to make a registry change. It was related to the fact that sockets were being opened and closed at a high rate, faster than they were cleanup by the OS.

    I can't remember the specific registry setting but it increase the number or socket connections available to user applications.

    If I remember correctly the OS defaults to 5000 connections.