Windows *: mscorsvw.exe high CPU usage

Another .NET update later, an hour spent looking this up. Why is mscorsvw.exe using 25% CPU for >30 minutes?

Here’s a short outliner on how to speed it up:

The scripts we’ve provided are a convenience for people who don’t want to deal with a command prompt. If you prefer to use the command prompt, you can use the commands below instead. These commands depend on the version of the .NET Framework you have installed and the version of Windows that you have and whether it’s 32-bit or 64-bit.

  • .NET 4, 4.5, or 4.5.1 Preview on Windows 7 or earlier:c:\Windows\Microsoft.NET\Framework\v4.0.30319\ngen.exe executeQueuedItems

    On a 64-bit operating system, add:

    c:\Windows\Microsoft.NET\Framework64\v4.0.30319\ngen.exe executeQueuedItems

  • .NET 4, 4.5, or 4.5.1 Preview on Windows 8 or 8.1 Preview:c:\Windows\Microsoft.NET\Framework\v4.0.30319\ngen.exe executeQueuedItems
    schTasks /run /Tn “\Microsoft\Windows\.NET Framework\.NET Framework NGEN v4.0.30319”

    On a 64-bit operating system, add:

    c:\Windows\Microsoft.NET\Framework64\v4.0.30319\ngen.exe executeQueuedItems
    schTasks /run /Tn “\Microsoft\Windows\.NET Framework\.NET Framework NGEN v4.0.30319 64”

  • If you don’t have .NET 4 or later installed, but you do have .NET 2.0 or 3.5, use this command instead:c:\Windows\Microsoft.NET\Framework\v2.0.50727\ngen.exe executeQueuedItems

    On a 64-bit operating system, add:

    c:\Windows\Microsoft.NET\Framework64\v2.0.50727\ngen.exe executeQueuedItems

These commands assume that Windows is installed on the C drive. If that’s not the case, you can change the drive letter, or use the %windir% environment variable (ex: %windir%\Microsoft.NET\Framework\v4.0.30319\ngen.exe executeQueuedItems)

Leave a Reply

Your email address will not be published. Required fields are marked *

I accept that my given data and my IP address is sent to a server in the USA only for the purpose of spam prevention through the Akismet program.More information on Akismet and GDPR.

This site uses Akismet to reduce spam. Learn how your comment data is processed.