Replacing JRun with Tomcat is a fundamental change in ColdFusion 10 and with that comes the new connectors for IIS and Apache. That also makes it very important to know the different configuration options available for the connectors as an incorrectly configured connector can easily lead to “Service Not available” or “Server is too busy” errors for your site.

During IIS connector configuration, user can choose to configure connector for individual sites or for “ALL” sites.

When connector is configured with individual sites, separate connector for each site will be placed under {CF-Home}/config/wsconfig/{some no}/ , Similarly for “ALL” configuration the connector is configured at global level, which means the same connector binary will be used across multiple sites.

In most of the cases server administrators wish to go for configuring connector for “ALL” sites as it is very convenient.

In this blog post we will talk what are the parameters needs to be tuned appropriately to make CF connector works flawlessly.

I will be covering three most important parameters which decide the scalability of the connector.

  • Reuse Connections
  • Connection pool size
  • Connection pool timeout

There are other parameters which CF connector inherits from Tomcat AJP connector. Please find the details of those settings from AJP documentation (http://tomcat.apache.org/connectors-doc/reference/workers.html )

Connection pool size: - This setting determines the maximum number of connections that can be created in the connection pool. When multiple requests arrive to the connector from IIS, connector creates  new connections in the connection pool only if there are no free connections available in the pool.  The connector will not create a new connection if connections reach the connection pool size limit.

Re-use connections: - This setting determines the count of connections that can be re-used.  . When Tomcat connector makes a connection with Tomcat server, it does not close the connection even after it finished serving the request. Instead it keeps the connection alive, so that for the next request, the same connection can be re-used. This increases the performance by minimizing the overhead of creating new connection with tomcat server for every request.

Note: - The default re-use connection count is same as connection pool size which is 200.

Connection pool timeout: - This setting determines the timeout value (in seconds) for idle connections in connection pool.  This value must be in sync with the connectionTimeout attribute of your AJP connector in Tomcat's server.xml.

Let us discuss more about how these 3 parameters can be tuned properly to make your server with varying load on your server.

1.       Connection pool size: - When connector is configured with “ALL” sites, the same connection pool will be used to serve the request for all sites.  So the default value of the connection pool size, works well with the single site configuration, but fails to work well with “ALL” site configuration in some scenarios. Hence this value should be increased carefully based on the need and number of sites that are present in IIS. 

2.       Max Re-use connections: - This settings needs to be used for connector configured with multiple sites.  The max value for the re-use connection is determined based on the number of sites configured with same CF server and the load on each site.

Let us consider use case where site 1 configured with CF server, now site 2 is also configured with the same CF server. By default each connector will have 200 re-use connections.

Now consider site 1 is running under heavy load make all 200 re-usable connections with CF server. Now CF server is not left with any new connection in its connection pool, hence any request for new connection from site 2 will be ignored by CF server.

 Hence it is required to make site 1 re-use connection count  to optimal value, so that site 2 does not starve for new connection. This can be achieved by configuring optimal value of max re-use connection count.

For the above use case, if site 1 is allowed to use 100 re-usable connections, there will be 100 more connections available for site 2 at the tomcat server connection pool.

3.       Connection pool timeout: - This timeout value helps in recycling connections that are being re-used when they are not used for a long time.  This is proved very useful when sites runs under varying load and makes overall improvement in the server performance. By default timeout for connection is indefinite.

Below we will discuss steps to follow to configure the above parameters

  • Go to worker.properties file (inside connector installer folder) add below line as new entry worker.cfusion.connection_pool_size = 500 (This is connection pool size inside connector which are available to handle request)
  • Add another entry in new line worker.cfusion.connection_pool_timeout = 60 (This value is idle connection timeout, when sites are not under load connections will be recycled back to IIS)
  • Tune the entry for max_reuse_connections to appropriate value based on number of site. Optimal value is connection_pool_size / {no of site}
  • Now open the server.xml from {cf-home/cfusion/runtime/conf}, add/update the maxThreads=500 and connectionTimeout="60000" to connection node containing the AJP entry. Now the AJP entry in server.xml should look like  <Connector port="8012" protocol="AJP/1.3" redirectPort="8445" tomcatAuthentication="false" maxThreads="500"  connectionTimeout ="60000">  </Connector>
  • Restart the IIS and ColdFusion server to reflect the above changes.

55 Comments to “Tuning ColdFusion 10 IIS Connector configuration”

  1. Ron Stewart
    @Kiran: Can you clarify two points? First, are the settings with which you conclude your blog post recommended settings for the situation where the connector has been configured for all sites or for the situation where the connector has been configured for an individual site on a multi-site host? Second, given your reference to the 503 "Service Not Available" errors some/many users have reported with CF10, can you clarify whether Adobe believes these errors are wholely or in part attributable to misconfigured or poorly configured IIS/Apache connectors?

    And please get rid of the capcha... I'm now on my fourth attempt to submit a comment.
  2. Subodh
    Hi Kiran,

    i have encountered with the problem that if there are frequent XML post to the site the IIS stops working can say that it hungs and after restarting IIS only it starts working.
    i have applied the latest coldfusion update [10.4].
    Can you please help me that what tuning i should use for my site .
    the IIS hangs around 200 XML post within a minute.

    Thanks
    Subodh
  3. Mike Collins
    Good info here. @Subodh - I don't think it has anything to do with xml. Grab some snapshots in the Server Monitor and send them to me using mike and the above domain.
  4. Kiran
    Hi Ron

    For First Question, This blogs covers for both All and individual sites. There are three settings discussed above,
    Connection pool size and timeout will be useful more in All site configuration, where as re-use connection and timeout is useful when connectors are configured for individual sites.
    For second Question, most of the 503 issues customers reported are addressed with simply tuning these parameters, also our support team is working with all those customer who are facing the 503 issue to narrow down the actual problem.
    Also re-configuring connector is must when ColdFusion Update 4 is applied.
    Please let us know,if anybody encountered 503 issue after tuning the connector, we take the issue with high priority and provide fix ASAP.
  5. Kiran
    Hi Subodh
    Make sure your re-configured the connector after applying hotfix. Also make the tuning appropriately, you should not see the problem.
  6. charlie arehart
    Kiran, when in your last point, you say to open server.xml and "update the maxThreads=500 and connectionTimeout="60000" to connection node containing the AJP entry."

    First, to be clear, you mean the one that's got a protocol value set to an AJP value, like this one I find in mine, right?

    Connector port="8012" protocol="AJP/1.3" redirectPort="8445" tomcatAuthentication="false"

    And then since you say "update", but there are neither the maxThreads nor connectionTimeout value there, do you really mean "add" them to that line?

    Second, it would seem that a restart of CF would be required after making these changes, right? The entry makes no mention of that. (Might they also indicate a need to restart the web server, also whether IIS or Apache?)

    Besides any reply you may add here, could you please consider updating that text in the entry if you would agree, as some people don't read blog comments before following the steps in a blog entry.

    Hope that's helpful to someone.
  7. Kiran Sakhare
    Hi Charlie

    Thanks for the feedback. I incorporated your feedback in the blog.

    Thanks
    Kiran Sakhare
  8. Subodh
    Hi kiran ,

    i have applied the coldfusion update 5 on my Development server [windows 7] and i have reconfigured the connector also.
    i want to check the previous 503 error fixed or not .

    Can you please assist me in testing.

    Thanks for the cooperation
    Subodh
  9. Mike Collins
    I think it needs to be pointed out the tuning being mentioned here is of you are using the ALL option.

    Setting up a different connector for each site should be looked at as an option as well.

    Kiran - as we make changes to worker.properties files will these be wiped out when we rerun the wsconfig.exe?

    Another option available is to create more then one worker.
    worker.list=cfusion
    worker.cfusion.type=ajp13
    worker.cfusion.host=127.0.0.1
    worker.cfusion.port=8012
    worker.cfusion.max_reuse_connections=250

    worker.list=cfusion2
    worker.cfusion2.type=ajp13
    worker.cfusion2.host=127.0.0.1
    worker.cfusion2.port=8012
    worker.cfusion2.max_reuse_connections=250


    Then in the uriworkermap.properties file you can assign workers to different mappings.

    For instance here is one mapping:
    site2.com/*.cfm = cfusion2

    Then have the catch all mappings as your last mappings.
    /*.cfm = cfusion

    However before I did the above, I think I would just create a separate connector for each site.

    I use mappings like the above to do request routing based on url, where I have one IIS site that goes to many CF servers.
    http://www.supportobjective.com/blog/index.cfm/2012/9/4/ColdFusion-10-with-Tomcat-brings-back-Context-Root-Routing

    @Kiran - if we are now editing worker.properties files can we get manual instructions for updating the DLL along with any tips at knowing by looking what version DLL we are using? Can you add something to the DLL metadata.

    One last thing, I think CF should look at binding the AJP connector to 127.0.0.1 with an attribute of address="127.0.0.1". I believe it defaults to all IPs. Remote setups would need to change it anyway.
  10. Kiran
    Hi Mike

    Kiran - as we make changes to worker.properties files will these be wiped out when we rerun the wsconfig.exe?

    Yes. Re-configure will wipe out and recreate the configuration file and copies connector extracted from wscofig.jar

    To retain the configuration file, use upgrade option with wsconfig.exe.

    Currently timestamp is only way to know the connector version released. Please log ER with CF, we will try to address it by adding the version to every release of connector.
  11. Aaron Neff
    +1 to adding version to isapi_redirect.dll's metadata.

    @Kiran, Just to clarify, so we can use -upgrade option after installing updates? Why then does Adobe recommend uninstalling/reinstalling the connector? IMO users will always want their configuration preserved.

    Thanks,
    -Aaron
  12. Aaron Neff
    @Kiran,

    First, thanks for this helpful post. Second, this post reveals the problem of the "All" option and the benefits of configuring individually. So, I'd prefer what Mike recommends.

    Thus, IMO, a simpler fix would be if wsconfig.exe had a new "All - Individually" option. This new option would create a separate connector for every site.

    I agree the "All" option is very convenient. It's awesome - thank you for that. Can Adobe please offer this same awesome convenience for configuring all sites individually, by adding a new "All - Individually" option in CF11?

    Thanks,
    -Aaron
  13. Kiran
    Hi Aaron

    Thanks. Please log a ER for All-Individual configuration of connector. We will evaluate this approach.
    We recommended re-configuring the connector configuration as there are small configuration changes done for connector configuration file in updater release. To reflect those changes, re-configuration is required.
  14. charlie arehart
    So @Kiran, you're saying we should not just run the -upgrade option (if we use the command-line wsconfig) but instead should literally remove and re-add each site? And that that would lead to a different result? And is this true for both IIS and Apache?

    If so, then this REALLY needs to be communicated more clearly, here and in every bloc mentioning a CF10 updater, in the CF10 updater itself as shown in the updater within the CF Admin interface), and in the technote for each updater.

    Really, this whole need to re-run the connector (at all) is easily missed by many, and I can't help but wonder if frequently the problems people report that "the updater didn't fix anything" might be because either they a) did not try to update their connector at all or b) they did only do the -upgrade option and not a complete remove/re-add.

    Similarly, it seems (from my experience) that there is an important requirement on Windows 2008 and Windows 7 to be sure to "run as administrator", whether using the GUI or command line wsconfig (and even if one technically "is" a Windows Administrator). If you would confirm that's so, then again, those resources above also need to make that clear (and show people how to do it, since many never have needed to worry about it previously with other apps.)

    Lack of clarity on these things must surely contribute to a lot of the uneven experience among folks applying these updates.
  15. Jim
    I have a problem with the connectors with CF 10 on IIS 7.5 Windows 2008 64 bit. After installing update 4 I tried to reinstall the connectors. Afterwards Coldfusion did not work (service unavailable). I tried wsconfig several times and it would not show the available IIS sites. I reinstalled Coldfusion from scratch and it seems to work just fine, but the IIS sites still will not show in wsconfig. At this point I will not install and more updates until I have a resolution to this problem. Where does wsconfig get it's information for the IIS sites? I am logged in as administrator when I run wsconfig. Any help appreciated.
  16. charlie arehart
    Jim, can you please try running the wsconfig "as administrator"? I realize you may feel "I am already an administrator", but I've seen it make a difference. What I'm saying is right-click on the tool as you launch it (or the command prompt if you work that way) and choose "run as administrator".

    In your case, let's see if that at least lets you see the sites in the tool. (For others, with different problems, I've seen this solve things even though there was no apparent difference in the interface, just that things "did not work" after using the interface.)

    Finally, as for the "service unavailable" error, that could be something entirely different: was that happening before you did the updater? hoping perhaps that it would address the problem? If so, it may be that the IIS application pool had stopped. That was one of the results from the bugs fixed by Updater 4.

    So the thing is, the application pool(s) for your site(s) may still be stopped, even after running the updater. So do be sure to confirm it's running (go to the "application pools" section of the IIS interface, and start any that are stopped. (You can also use that to see what pools go with what sites, if you want to be more granular in which you start/stop.)

    Let is know if any of that helps.
  17. Jim
    Thanks for the reply.

    I tried "Run As" administrator by right clicking to no avail. There is no option to configure any IIS sites. The wsconfig window only has "None" as an option for IIS sites. I did move the default IIS web sites to a different partition, but everything else is working fine and wsconfig worked fine until I installed an update that forced me to run wsconfig (update 4). It just can't seem to see the IIS sites.

    For now, Coldfusion is working fine, the service unavaiable went away after I reinstalled Coldfusion but the wsconfig problem needs to be fixed so I can install updates. Thanks.
  18. Kiran
    Hi Jim

    Can you please try running the below command and tell us the sites are listed

    %systemroot%\system32\inetsrv\APPCMD list sites

    Seems to be permission issue.

    Thanks
    Kiran Sakhare
  19. Jim
    It could be a permission issue, there are always new patches being deployed that change the permissions. I'm not going to post the entire results from the command as that is against company policy but I do see the "Default web site" that is bound to https which seems correct. That is the only web site we have currently.
  20. Mike Collins
    @Jim,

    I had an issue after moving from http tp https. I had to bind the connector in the [instancename]/runtime/conf/server.xml file. Try adding an attribure of address="127.0.0.1" to the connector line where it specifies your AJP port ie 8011-19.
  21. Jim
    Thanks, I did try it but that doesn't appear to be the issue. Like I mentioned the connector appears to be working fine, it's just that wsconfig can't see anything.
  22. Kiran
    Hi Jim

    Please try the command line way to configure the connector. For example to configure sitex use the following command
    wsconfig.exe -ws iis -site sitex

    Make sure you launch the command line using Runas administrator.

    Similarly to remove
    wsconfig.exe -ws iis -site sitex -r

    Thanks
    Kiran Sakhare
  23. Tom
    Our IIS7 server has around 100 sites and we're using the ALL setting for the connector. So it sounds like I should go to 500 for connection_pool_size but you are saying I should then go down to 5 for max_reuse_connections ?? That would be connection_pool_size / #_of_sites. The current setting in workers.properties is 250 for max_reuse_connections. Seems like a drastic change to go from 250 down to 5. Am I understanding it right? I mean I understand the idea is to make sure that one site doesn't "reserve" all the available connections and thereby starve out all the other sites -- but I feel like by setting this value to just 5 I might be starving them all anyway. It's not like all 100 sites are all busy all the time. Maybe on a server with 100 sites I should do connection_pool_size even higher than 500? And something less drastic for max_reuse_connections, like 50 maybe?

    Thanks,
    Tom
  24. Tom
    Hi A related question if anyone can answer regarding wscongig. I want to make sure we get the newest connector DLLs after installing HF5, but I do not want wsconfig to go through my IIS7 settings and change the path of the /CFIDE virtual folder for every site which we have pointed to a copy location. I would have to go and re-do that for every site. Will running wsconfig with the -update switch preserve my IIS settings (i.e. applicationhost.config) but still extract the new connector DLLs. That's what I am hoping.

    Thanks,
    Tom
  25. Tom
    Answering my own question: wsconfig -upgrade -v does replace the connector with the newest version but doesn't mess with your IIS7 config (applicationhost.config) at all which is exactly what I wanted so I like that a lot.

    Tom
  26. Kiran
    Hi Tom

    wsconfig -upgrade option we do not recommend when you apply CF updates, as there are few changes in connector configuration file between updates. This changes will be missed if you just run the wsconfig -upgrade command.

    Also do not use -v option as it is only meant for generating verbose logs and highly not recommended in production server.

    Thanks
    Kiran Sakhare
  27. Aaron Neff
    Hi Kiran,

    You're welcome and done! Filed as #3429152 and added a link back to this entry.

    URL: https://bugbase.adobe.com/index.cfm?event=bug&id=3429152

    Thanks!,
    -Aaron
  28. Kiran
    Hi Tom

    In your case where you have 100+ sites, i suggest you go with fewer re_use connection count along with time out option. Re-use connection can be recycled to connection pool after they timed out in idle state.



    Thanks
    Kiran Sakhare
  29. Jim
    So I finally got back around to trying this due to other work responsibilities.

    I tried a "Run As Administrator" for the command prompt and tried the install for the wsconfig and I get the following error:

    C:\Users\JIMWAR~1.AO\AppData\Local\Temp\6\ExecuteAppCmd\ExecuteAppCmd.exe (Access is denied)

    When I go to the folder mentioned it is empty. I tried changing the permissions on the folder to allow all users up to modify permissions, to no avail, I still get the same error. Any ideas? Thanks.
  30. Kiran
    Hi Jim

    Looks like ur user is not in admin group. We recommend to be logged in as Administrator to configure connector. To configure connector which modifies the IIS configuration files. To perform this you need to be Admin or part of Admin group with permission.

    Try giving execute permission to this folder
    C:\Users\JIMWAR~1.AO\AppData\Local\Temp\6\ExecuteAppCmd\
    and see if it works. But make sure you have enough permission for current user to modify the IIS configuration.

    Thanks
    Kiran Sakhare
  31. Kiran
    Hi Jim

    Looks like ur user is not in admin group. We recommend to be logged in as Administrator to configure connector. To configure connector which modifies the IIS configuration files. To perform this you need to be Admin or part of Admin group with permission.

    Try giving execute permission to this folder
    C:\Users\JIMWAR~1.AO\AppData\Local\Temp\6\ExecuteAppCmd\
    and see if it works. But make sure you have enough permission for current user to modify the IIS configuration.

    Thanks
    Kiran Sakhare
  32. Jim
    Well,

    The problem is that it is an aministrator account and I use the "Run As" administrator to run wsconfig or the command prompt. I also gave read, write, and execute permissions on that folder and I confirmed that I (as the administrator) can create an executable in that folder, and I can (as that same administrator) make configuration changes to IIS. So I don't know what the problem is. I also tried a local admin user, with no dice.
  33. Henry Ho
    "user can choose to configure connector for individual sites" Is this true for CF10 Standard as well?

    Thanks!
  34. Kiran
    Hi Henry

    Yes, You can choose individual sites to configure in CF 10 also. Use wsconfig and sites dropdown will list all the unconfigured sites.
  35. Rick
    Wow, what a headache. Just installed CF10 on 2008 Sp2 x64. Could not get any of the CF websites to connect. Read miles of Adobe docs and this blog (among many) and did all the handler mappings, editing the XML and adding mappings of the issai*.dll according to: <a href:"http://helpx.adobe.com/coldfusion/kb/coldfusion10-iis-manual-connector-configuration.html">http://helpx.adobe.com/coldfusion/kb/coldfusion10-iis-manual-connector-configuration.html"; and I am LOST LOST. Now I cannot access the CF administrator from the browser. I can get into the CF admin but only the buttons on the left frame show up but will not connect to any sources on the right (ex: http://127.0.0.1/CFIDE/administrator/datasources/index.cfm";. I have rebooted the server...natha! I am seriously thinking about reverting back to CF 9 or even 8. Those worked flawlessly for me. Whatever possessed me to use CF 10!In all the blogs I read it seems that EVERYONE is having problems with CF10. Why doesn't Adobe just create a product that when you install the program it knows which mappings to include based on the server software identification (duh...such as IIS 7). Geeze! Why make things so difficult? In any event, can someone PLEASE help me. I have been supporting CF since Jeremy Allaire owned it (yeah- long time ago).
  36. Rick
    Guess you cannot edit your post in this blog. In addition to my earlier post: I have done all the due-diligence by making sure the IIS 7 features and web services are installed and running. When I first set up CF10 it was on a clean install of 2008 x64. The only thing running on the server is CF10. At that time I was able to access the administrator source pages from the buttons in the left pane. However, I could not access any website using cfml. I assumed it was a mapping issue. I searched for answers and came up with the Adobe link mentioned above. After all the jakarta, etc. mappings I now cannot access anything. Oh, and yes, I made sure to get all the OS updates before installing CF10. HELP! Now what?
  37. Rick
    Here is what I now receive when I attempt to access the default server page in a broswer:
    Server Error in Application "DEFAULT WEB SITE"

    "Internet Information Services 7.0
    Error Summary
    HTTP Error 500.0 - Internal Server Error
    The page cannot be displayed because an internal server error has occurred.
    Detailed Error Information
    Module   IsapiFilterModule
    Notification   AuthenticateRequest
    Handler   StaticFile
    Error Code   0x80070001
    Requested URL   http://127.0.0.1:80/
    Physical Path   C:\inetpub\wwwroot
    Logon Method   Anonymous
    Logon User   Anonymous
    Most likely causes:

    IIS received the request; however, an internal error occurred during the processing of the request. The root cause of this error depends on which module handles the request and what was happening in the worker process when this error occurred.

    IIS was not able to access the web.config file for the Web site or application.

    This can occur if the NTFS permissions are set incorrectly.

    IIS was not able to process configuration for the Web site or application.
    The authenticated user does not have permission to use this DLL.
    The request is mapped to a managed handler but the .NET Extensibility Feature is not installed.

    This is the exact message I also receive when attempting to open the CF Administrator.
  38. Kiran Sakhare
    Hi Rick

    Seems some stale entry for handlers causing the issue. Please remove the connector. Check in the IIS manager for handlers, cgi restriction for connector dll entry (isapi_redirect.dll) and remove them manually if exist.

    While configuring the connector enable the verbose logging from advanced option. If issue still persist post the isapi
    _redirect.log which will give us more insight why CF connector is not working in your environment.

    Note :- Make sure you launch wsconfig with Run as Administrator while remove/adding connector.

    Thanks
    Kiran Sakhare
  39. Jim
    My problem was that McAfee intruision detection was preventing Java from creating a .exe file as part of the connector installation. We had to turn off McAfee temporarily to allow the installation then everything was good.

    It seems most of the problems have to do with permissions, you have to run the configuration as an Admin (Using RunAs) and make sure your intrusion detection is not blocking it.
  40. Rick
    Thanks so much for the reply Kiran. After spending nearly a week trying to figure this out the IT Director here ordered us to go back to CF 9. We did and it works flawlessly. Guess Adobe needs to still work on some things with CF10. Prob is the IT Dept. spent the money on the upgrade and the product doesn't work. This is a large corporate environment and time is, I am sure you know, a very big deal. So back to 9 it is. Thanks again for your reply.
  41. Richard Herbert
    Whilst the title of this posting says IIS you mention Apache in your opening paragraph.

    Given that wsconfig doesn't offer an "All Sites" option when Apache is selected, does this advice also apply to multi-site/instances of ColdFusion that use the Apache web server?
  42. jerry Farrell
    I am upgrading a server from version 8 to version 9 cf. The IIS Connector does not seem to connect to IIS 7. I have ran uninstall and Install several times. I can turn CF 8 back on and and reconnect 8 and 8 works fine. But due to a government requirement I need to upgrade my app software which requires CF 10 to even run. All the configurations I find in different blogs seem to show up fine. If someone can point me to a specific item to look at i would appreciate the help. I do have the software vendor calling me at 3:30 pm est to see if they can fix the configuration for version 10. The vendor is Terra Dotta. If I get this resolved through them I will post the solution to my problem.

    Jerry
  43. Jerry Farrell
    Sorry I was thinking 9 from another post i read. We are actually going to CF 10 bypassing CF 9
  44. charlie arehart
    Jerry, what do you really mean by "the IIS Connector does not seem to connect to IIS 7".

    Do you mean that when you run the CF10 web server connector tool, it opens but you can't see it connecting to IIS? Or you see it and submit it, but it fails? Or you submit it and it works but then you test a page and it fails?

    What is the specific failure in any of these cases? You could have any of many problems, so more detail will help us help you.

    Also, it would help to say what version of Windows and IIS you're using. Since you say you get it working with CF8 (and I assume you mean these are all on the same machine) then it would seem you must mean Windows 2003 and IIS 6, since CF 8 does not support IIS 7 (without kludges). But please do specify so that those here may help more.

    (And really, it should be notes that the Adobe CF forum for Administration may be the better place to have a discussion about such challenges. It doesn't seem that your challenge really fits into this blog entry's discussion of "tuning the CF10 IIS connector". But I'm not the list or blog police, and this is not my blog anyway. :-) I'm just sharing that observation, as much for others in the future. Also, blog comments aren't as well suited to "discussion" as a forum thread. But let's see if we can sort yours out since you've raised it.)
  45. Jerry Farrell
    We are on Windows 2008 server using IIS 7.

    I am getting the 500 error most people seem to post about.

    My vendor had me uninstall CF 10 and reinstall with no success. Seems like the configuration tool is missing something. I plan to work with the vendor of my software again today. I expect they will tell me to contact Adobe in the end. Seems like it should be their issue to resolve.
  46. charlie arehart
    @Jerry, the connector for CF10 works. There have been bugs that have been addressed. If you would say you have "done all the updates", did you also rebuild the web server connector AFTER doing the updates? That's necessary on a fresh install (install, do updates, rebuild connector). It's discussed in the technotes of the most recent updates, but many don't notice the update page (in the updates section of the admin) telling them to see the "read more" link for more on that.

    There are some other potential gotchas, especially on Server 2008, such as if you don't think to run that web serer config tool with "run as administrator".

    Also, I have seen people get in trouble because they have tweaked things by hand in deparation, (not knowing to just rebuild the connector, or not doing it right. They may tweak IIS or the Tomcat settings, only making things worse.

    I'll say this: if your vendor (or Adobe) can't help you sort it out, I'm confident I can. I offer server troubleshooting, and I offer a satisfaction guarantee, so you won't pay for time you don't think valuable. More at the consulting page at carehart.org. Sorry to turn this into a sales pitch.

    It's the first time I've said that in all my comments on this thread, as I do always just try to help. But some challenges are just too hard to resolve in back and forth in blog entry comments, or even a forum thread. Just letting you know you have another option. The problem should be able to be resolved, as I've done it with many folks.
  47. BeekerMD03
    We are getting two connection errors randomly throughout the day. I am not getting much traction on figuring out what is happening.

    Error 1: “Error Executing Database Query. [Macromedia][SQLServer JDBC Driver]Object has been closed. ” Stack Trace: java.sql.SQLException: [Macromedia][SQLServer JDBC Driver]Object has been closed.

    Error 2: “Error Executing Database Query. [Macromedia][SQLServer JDBC Driver]A problem occurred when attempting to contact the server (Server returned: Connection reset). Please ensure that the server parameters passed to the driver are correct and that the server is running. Also ensure that the maximum number of connections have not been exceeded for this server.” Stack Trace: java.sql.SQLNonTransientConnectionException:

    Any thoughts? Could this be related to tuning? The datasource has been set to limit the number of connections based on the (SELECT @@MAX_CONNECTIONS) query results.
  48. Dave Cordes
    I have a question that I hope someone has had some experience with. I'm running ColdFusion 10 Standard on Windows server with about 50 websites running with the connector on all sites. Right now I have my connection pool size at 500 with reuse connections at 10 and timeout at 60 seconds.

    The problem is whenever one of my clients gets a large increase in traffic due to an email promotion coldfusion.exe spikes to 90%+ and all the websites get really slow. I assume this is because ColdFusion is running out of connections but I am not sure 100% sure. Right now I am looking to install Fusion Reactor to get a more clear picture.

    So here's my question. If only 20 or so of the websites get any sizable traffic (more than 1,000 visits per day), would it be a good idea to adjust the connection pool size to 1,000 and the reuse connections to 50? I'm just not sure how ColdFusion assigns Tomcat connections to each website. Will I be shooting myself in the foot here?

    I can also adjust the amount of memory assigned to ColdFusion as well. Right now I have 4,096 MB RAM as the minimum and maximum heap sizes.

    Thanks for any recommendations.
  49. Charlie Arehart
    Dave, is that "90% spike" about CPU or heap? Since you don't have CF Enterprise or FusionReactor to easily see the latter, I'll assume it's the former.

    And I would think that a problem of high CPU in CF would NOT be because of connector problems--problems of the connector not letting in requests would in fact be PREVENTING requests getting into CF, not causing high CPU in it.

    So rather I'd suppose that your high cpu problem is due to any of many reasons that I find common but not so-often considered. Check out a blog entry I did on the topic:

    http://www.carehart.org/blog/client/index.cfm/2014/6/24/common_causes_of_high_CPU_in_ColdFusion

    Let us know if either of the ideas listed there help, as a start, to understand your high CPU problems. Or if you do learn that it's something else, let us know.
  50. Charlie Arehart
    For readers of this blog entry, note that Adobe came out with a much more recent entry on this topic of connector tuning, about a month ago, with even more details:

    http://blogs.coldfusion.com/post.cfm/coldfusion-11-iis-connector-tuning
  51. Dave Cordes
    Charlie,

    Thanks for your reply. The 90% spike was CPU because I didn't have any insight into the heap. I have since installed Fusion Reactor so I now have a better idea of what's happening.

    Your blog post is pretty interesting especially the first point about memory. My max heap is set at 4,096 so maybe I ran into the upper limit when that influx of traffic occurred. If that happens in the future I'll know about it and will increase it.

    I have no idea why I didn't install Fusion Reactor a long time ago, this software is awesome. I would recommend it for anyone running ColdFusion.
  52. Dave G
    We're having stability issues (503 errors), and I noticed today that the server.xml file in cfusion/runtime/conf/ has different values for maxThreads in the Executor and Connector nodes. Should these values be the same?

    <Executor name="tomcatThreadPool" minSpareThreads="4" maxThreads="65" namePrefix="catalina-exec-">
    </Executor>
    <Connector port="8012" protocol="AJP/1.3" redirectPort="8445" maxThreads="500" connectionTimeout="60000" tomcatAuthentication="false">
    </Connector>

    Thanks in advance.
  53. Jeff
    After installing CF11 and having the server crash once or twice a day with the Warning message, I see we need to do some tuning. However, having read through dozens of CF/Tomcat/IIS blog and forum posts I'm still left confused.

    We're running Windows 2012 with CF11 and have about 50 sites running in IIS. We have individual connectors for each site which is where I'm running into trouble, I think. Should I just go back and choose 'All'?

    I initially thought doing each individually would give me better performance customization per site thinking we could give more resources to our more-trafficed sites, but this seems like a huge headache to have to go through each workers.properties file. Also, I'm not sure what I should be using for values with so many sites defined. Should I, going by Use Case #3, eg:

    maxThreads=750 in server.xml
    leaving only:
    max_reuse_connections=1 (connection_pool_size / number of sites)
    connection_pool_size=15 (15+15+15+....+15 at 50 sites = 750)
    connetion_pool_timeout=60

    I realize that Definitely isn't the correct answer, but I'm not finding any good responses when hosting a large number of sites using multiple connectors. Is this just a bad idea?

    And if so, can I just run wsconfig.exe and select All to convert them to one big connection? Then if so, as Tom asked above, what would reasonable values be? I realize there won't be a specific number here, but ballpark and an explanation would be very helpful.

    Thanks for any help and direction!
  54. Dave Cordes
    Hi Jeff,

    I have about 50 sites running right now on my server so I thought I would chime in here. My workers.properties file looks like this:

    worker.list=cfusion
    worker.cfusion.type=ajp13
    worker.cfusion.host=localhost
    worker.cfusion.port=8012
    worker.cfusion.max_reuse_connections=50
    worker.cfusion.connection_pool_size=1000
    worker.cfusion.connection_pool_timeout=60

    I selected those numbers because I have about sites running but only a handful get any real traffic so I set the max reuse connections a bit higher than the recommendation. It seems to be a solid setup for me but your mileage may vary if all your sites get heavy traffic.
  55. Naga
    I have one problem with apche virtual hosting + CF11.

    I am using apache with CF11 and virtual hosting document root on NFS mounted folder. when I access my cf test page from that document root folder I am getting "Define the page request properties. " message on browser. No data coming.. any idea what could be the problem.

    Also If I use local folder instead of NFS mounted folder for apache virtual host document root I am getting results fine.

    I have verified the folder permissions on my Centos6 machine and everything looking good.

    One more thing is this is working fine in Apache + CF8

Leave a Comment

Leave this field empty: