Visual Studio 2015 StandardCollector.Service.exe r

2019-05-30 12:56发布

问题:

Visual Studio 2015 (14.0.25431.01 Update 3) is coming to a complete halt due to massive I/O caused by the StandardCollector.Service.exe. Debugging a project results in a sustained 200 mb / sec data written in the temp directory. All performance data (etl).

Memory allocation is normal.

This behaviour is new. I used Visual Studio 15 for years without (but for the usual) complaints.

I tracked it down to the Diagnostic Tools. Disabling Diagnostic Tools in Tool -> Debugging -> General -> Options -> Enable Diagnostic Tools while debugging solves the I/O problem. However this is not a permanent solution since I rely on this feature.

Q: What causes the massive I/O when Enable Diagnostic Tools while debugging is switched on?

回答1:

Disclaimer: I work on Visual Studio, specifically the Diagnostic Tools

You have the CPU Usage tool enabled which is a profiler that uses event tracing for windows (ETW). Basically it is collecting a CPU stack every millisecond and that information is getting written to an ETL file that we analyze and display performance information from. We persist whether or not you turned it on between debug sessions, specifically so that you can turn it on, restart debugging, and profile app startup. One of our biggest issues is that it is easy to turn on and forget.

To turn it off, switch to the CPU Usage tab in the Diagnostic Tools and press the "Enable CPU Collection" button (text is different based on VS version). The CPU graph above should switch from green to blue indicating that it has been turned off. Also, in the latest version of Visual Studio we have added resource limits which will disable the diagnostic tools if the disk or memory usage on the system gets too low, which was common when the CPU tool was enabled and forgotten about.