Per DISA we're required to set the recycling option for requests. I can't seem to track down what the max value for this should be or when the counter gets restarted? If app pools are configured to recycle at midnight, shouldn't the requests counter reset to 0? We set what we thought was a high limit at 99,999 but this seems to get hit everyday around noon on all 3 of our balanced servers. Sometimes shortly after the private bytes limit gets hit (also has to be set per STIGs but is roughly 70% of total OS memory) issuing another recycle request, where I believe either too many queued requests are in process or garbage collection is struggling (hence cpu/mem spikes) to issue full garbage collection during peak workload. I've seen that IIS 6.5 had 35,000 request but can't seem to find good guidance on what the max value could be for IIS 8.5 and IIS 10 (for when we migrate). We didn't notice we were hitting the requests limit due to that logging not being enabled by default in IIS 8.5, but is in IIS 10. We also noticed the parent defaultapppool bound to the default site where the ssl cert is bound to does trigger a full garbage collection event against the child app pool (probably because of shared config settings for security). If anyone needs a handy script to set all your pools to recycle at midnight/enable logging for iis 8.5, that's below.
Import-Module WebAdministration
Get-ChildItem –Path IIS:\AppPools | ForEach-Object{
$appPoolName = $_.name
$appPool = Get-Item "IIS:\AppPools\$appPoolName"
$appPool.recycling.logEventOnRecycle = "Time, Requests, Schedule, Memory, IsapiUnhealthy, OnDemand, ConfigChange, PrivateMemory"
$appPool.Recycling.periodicRestart.time = "0"
clear-ItemProperty "IIS:\AppPools\$appPoolName" -Name Recycling.periodicRestart.schedule #clear values
set-ItemProperty "IIS:\AppPools\$appPoolName" -Name Recycling.periodicRestart.schedule -Value @{value="00:00:00"}
$appPool | Set-Item
}
If we limit the discussion scope to a specific setting (aka
requests
in IIS application pool configuration), then that setting has no upper bound (at least concluded from the IIS XML schema).You can set any value as long as it is a valid
uint
.