ASP.NET CPU Spike related to high "% Time in GC" - what is a good baseline for ASP.NET?
<p>I have a situation where an ASP.NET application causes w3wp service cpu usage to spike to 100% while at the same time the "%time in GC" performance counters shows very high numbers 20-70%. This happens from time to time. </p>

<p>This all started happening after I upgraded to .NET 4.0 from 2.0, BTW.</p>

<p>I am looked at the performance counters, trying to get more clues, but I lack a good base line... what is "normal"?</p>

<ul>
<li>#Gen 0 Collections 10,000</li>
<li>#Gen 1 Collections  4,700 (seems high) </li>
<li>#Gen 2 collections  1,200 (again seems high) </li>
<li>Finalization Survivors 5000  (is this high??)</li>
</ul>

<p>To give you an idea of how busy the app is :</p>

<ul>
<li>ASP.NET Reuqests / Sec: 170</li>
<li>ASP.NET Sessions Active: 900</li>
</ul>

<p>On each page request, in my dev environment, Finalization Survivors is about 50. Seems high, but all the profiling tools I looked at, dont show anything out of ordinary... </p>

<p>I am looking for some baseline on what are the typical values for these params for a basic asp.net app. For example, how many "Finalization Survivors" are simply due to ASP.NET?</p>

<p>Many thanks!</p>

<p><strong>UPDATE - rolled back to .net 2.0 "fixed" the problem</strong> </p>

<p>I have been struggling with this issue since morning, ever since I upgraded to .NET 4.0
I rolled back my chnages - set the website to use asp.net 2.0, rolled back some binaries that were compiled with .net 4.0 and all is beautiful now - no spikes, no long GC time, but still a heck of a lot of finalization survivors.. </p>

<p>**UPDATE 2 - just switching to .NET 4.0 in IIS causes this slow down</p>

<p>I am updating this in case this is helpful to someone else one day who has the same problem. 
I found that the problems start just after switching IIS to use ASP.NET 4.0 on the website, without changing any of the .net 2.0 website code. I assumed, perhaps incorrectly, that it is backward compatible therefore a .net 2.0 website and resources it references should work fine under asp.net 4.0 but there appears to be some issue. If I get time to investigate further, I will update this with my findings</p>
