Skip to Content
author's profile photo Former Member
Former Member

IIS Timeout Due To Max Pool Size Being Reached

Every once in a while, IIS stops serving my Web Tools 2007.0.625 website, and, after 30 seconds of nothing, instead delivers a very unfriendly ASP.NET message:

Timeout expired. The timeout period elapsed prior to obtaining a connection from the pool. This may have occurred because all pooled connections were in use and max pool size was reached.

I run a scheduled task that resets IIS every 24 hours just in case this happens, but it seems that it's taking about six hours to happen, and I imagine that this will increase as traffic to my site increases too. I don't want to have to reset the website every hour just because of a leak - doing so would wreak havoc on customer satisfaction.

From the limited understanding I have of SQL connectivity persistence, this happens when connections are not explicitly closed in Web Tools code (If this is the case, it seems that an upgrade to SP1 is in order - can someone confirm or deny this?). My best guess is that the server has some stray connections that aren't being closed, and so they get hung onto for the open connection timeout period (20 minutes?) until they're released automatically by a type of SQL connection garbage collector. In the meantime, there are only a limited number of connections available for pooling like this, and they get eaten up and hogged by a first-come-first-served process.

I don't want to set the max pool size to something high, as it might bog the machine down too much. Of course, not pooling connections is suicide. Has anybody else seen this? What should I do?

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

3 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Feb 23, 2009 at 07:21 PM

    Hi Michael,

    This was a known issue that is solved in Patch 11 of SP0. Basically connections are not closed to the Db from Web tools, and after a period of time, which can be anywhere from 1 hour to several days depending on the amount of traffic the site gets, this timeout will occur as the connection pool has reached it's limit.

    If you cannot upgrade, you'll have to set up some kind of script that will reset the Web site every hour, so the connections are released. You don't have to restart IIS(I believe), but you can restart the individual Web tools website.

    If you do decide to upgrade I would upgrade to SP1 Patch 2(soon to be released), as there are other performance enhancements in SP1

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Bryce, forgive my ignorance, but these event logs - where would they be stored? I thought they were in the %windir%\System32\LogFiles folder, but I'm not sure whether they're in the HTTPERR subfolder or the W3SRV1 subfolder. If either one is the case, how can I interpret the error logs? They're being captured in standard log file format, but I've briefly reviewed each (and they're both pretty big) and neither one of them show anything that seems to jump out at me.

      Am I looking in the wrong spot, or do I just not know what to look for?

  • author's profile photo Former Member
    Former Member
    Posted on Feb 23, 2009 at 08:23 PM

    Thanks Bryce.

    The quest to persuade my company to upgrade continues...

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Feb 27, 2009 at 12:22 PM

    Hi Michael,

    This sounds like the same problem that I was experiencing. Within this thread I detailed my workaround:

    WebTools: New Theme can't be created

    Martin.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.