Hi I want to update processModel of my Server's machine.config file. Currently its value is as below:
<system.web>
<processModel autoConfig="true"/>
</system.web>
I want to update it with below new changes:
<system.web>
<processModel autoConfig="true"
maxWorkerThreads = "100"
maxIoThreads = "100"
minWorkerThreads = "50"
minIoThreads = "50"
/>
</system.web>
I want to use other values of processModel (see default values at: msdn.microsoft.com/en-us/library/7w2sway1(v=vs.100).aspx) as Default with the values i have Explicitly defined above. I have a Question here: what will be the value of autoConfig="?" as some post over the internet suggest that autoConfig value must be "True" (please see https://tiredblogger.wordpress.com/2008/09/17/tweaking-net-machineconfig-for-production-deployments/), as autoConfig=True sets everything to the defaults except what I explicitly define.
Where as other post suggests that it is necessary to set autoConfig = false in order for these custom values to take effect. (see: http://geekswithblogs.net/StuartBrierley/archive/2009/09/30/tuning-iis---machine.config-settings.aspx )
In MSDN ( msdn.microsoft.com/en-us/library/7w2sway1(v=vs.100).aspx ), the Definition of autoConfig="true/false" is
autoConfig=True: Indicates that ASP.NET automatically configures the attributes in the preceding list to achieve optimal performance based on the machine configuration. autoConfig=False: Indicates that ASP.NET should use the explicitly defined values for the attributes in the preceding list.
Another Question here is: As per MSDN, if i set autoConfig=False and Explicitly define my above 4 key values of processModel, what will be the values of other keys of processModel like webGarden, memoryLimit, cpuMask etc.? do i need to set other key/values of processModel as well? I am using these settings in machine.config of asp.net 4.0 application, hosted on iis8 Win Server 2012.
Thanks in advance for your help.
When reading about processModel autoConfig=true/false here (MSDN https://msdn.microsoft.com/en-us/library/7w2sway1(v=vs.100).aspx), it says that when this value is true, the five configuration attributes listed here (maxWorkerThreads, maxIoThreads, minFreeThreads, minLocalRequestFreeThreads, and maxConnection) “are set according to the KB article at http://support.microsoft.com/?id=821268”.
Moreover, it is not possible to set minWorkerThreads higher than maxWorkerThreads… The runtime detects the inconsistency and simply set the “min” value to its default. autoConfig does not directly influence minWorkerThreads and minIoThreads, but they are instead affected by their counterparts such as maxWorkerThreads and maxIoThreads.
I have done few test with different values of worker threads with autoConfig=true/false, below are their results.
<processModel autoConfig="true"
/>
Result: maxWorkerThreads 400 maxIoThreads 400 minWorkerThreads 4 minIoThreads 4
<processModel autoConfig="false"
/>
Result: maxWorkerThreads 400 maxIoThreads 400 minWorkerThreads 4 minIoThreads 4
<processModel autoConfig="true"
maxWorkerThreads = "70"
maxIoThreads = "70"
minWorkerThreads = "35"
minIoThreads = "35"
/>
Result: maxWorkerThreads= 400 maxIoThreads= 400 minWorkerThreads= 140 minIoThreads= 140
<processModel autoConfig="false"
maxWorkerThreads = "70"
maxIoThreads = "70"
minWorkerThreads = "35"
minIoThreads = "35"
/>
Result: maxWorkerThreads= 280 maxIoThreads =280 minWorkerThreads= 140 minIoThreads =140
<processModel autoConfig="false"
maxWorkerThreads = "150"
maxIoThreads = "150"
minWorkerThreads = "70"
minIoThreads = "70"
/>
Result:
maxWorkerThreads= 600
maxIoThreads =600
minWorkerThreads =280
minIoThreads =280
<processModel autoConfig="true"
maxWorkerThreads = "150"
maxIoThreads = "150"
minWorkerThreads = "70"
minIoThreads = "70"
/>
Result:
maxWorkerThreads= 400
maxIoThreads =400
minWorkerThreads =280
minIoThreads =280
来源:https://stackoverflow.com/questions/37248257/machine-config-processmodel-autoconfig-true-or-false-for-explicit-values-in-n