Exchange 2019 CU readiness check fails with MSCORSVW.exe has open files

Blogs > Exchange Servers > Exchange 2019 CU readiness check fails with MSCORSVW.exe has open files

While installing the Exchange Server 2019 Cumulative Update (CU9), I was getting the below message during the Readiness Checks.

Checking the task manager, I can see this process was running and consuming significant CPU resources. This process is a DotNet process and is otherwise known as the .NET Framework Optimization Service which optimises the computer to launch apps faster.

Why do I need mscorsvw and the .NET Framework?

Software developers around the world write apps using the .NET Framework. The .NET Framework includes a technology called Native Image Generator (NGEN) that makes apps launch much faster and that periodically does work to optimise the machine.

How often and when does mscorsvw run?

The .NET Framework optimization service runs at two main times:

How to Fix this Problem?

Solution 1: Just wait for 5 to 10 minutes for this .net compilation job to complete then rerun the setup and the Readiness Checks should complete successfully. And proceed with the CU installation.

Solution 2: By default, the NGEN only uses one CPU core for this operation. There is an option to speed up the work by using a command to make it use 6 cores when desired.

Open CMD in an elevated mode and run this command from this path

cd \

cd Windows\Microsoft.NET\Framework\v4.0.30319\

ngen.exe executeQueuedItems

This will force the queued compilation jobs to execute with extra CPU cores and will complete a lot quicker.

There will be an NGEN log generated in the location where this command is executed which you can check. 

If the above steps do not resolve the issue, you may need to manually stop the MSCORSVW.exe process using the Task Manager, but please note that doing so may cause performance issues with other applications that depend on .NET assemblies. If you are unsure about stopping the process, it's best to seek guidance from a qualified IT professional.