Reputation: 248
When compiling any C++ project with visual studio 2010 express I'm liable to get following behaviour - build started message appears in output window, CPU climbs to near 100%, multiple MSBuild.exe processes are spawned, long pause (several minutes) with nothing happening, build aborts with the following message
xxx.vcxproj : error MSB4014: The build stopped unexpectedly because of an internal failure.
xxx.vcxproj : error MSB4014: Microsoft.Build.Exceptions.BuildAbortedException: Build was canceled. MSBuild.exe could not be launched as a child node as it could not be found at the location "c:\WINDOWS\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe". If necessary, specify the correct location in the BuildParameters, or with the MSBUILD_EXE_PATH environment variable.
xxx.vcxproj : error MSB4014: at Microsoft.Build.BackEnd.NodeManager.AttemptCreateNode(INodeProvider nodeProvider, NodeConfiguration nodeConfiguration)
xxx.vcxproj : error MSB4014: at Microsoft.Build.BackEnd.NodeManager.CreateNode(NodeConfiguration configuration, NodeAffinity nodeAffinity)
xxx.vcxproj : error MSB4014: at Microsoft.Build.Execution.BuildManager.PerformSchedulingActions(IEnumerable`1 responses)
xxx.vcxproj : error MSB4014: at Microsoft.Build.Execution.BuildManager.HandleNewRequest(Int32 node, BuildRequestBlocker blocker)
xxx.vcxproj : error MSB4014: at Microsoft.Build.Execution.BuildManager.IssueRequestToScheduler(BuildSubmission submission, Boolean allowMainThreadBuild, BuildRequestBlocker blocker)
Microsoft have acknowledged a bug with this behaviour when your user name is 20 chars, but mine is much shorter. And needless to say I do have msbuild.exe in the right place.
The only work around I've found is to task switch to another app while the build is taking place. But I'm hoping someone has a better workaround.
MTIA John
Upvotes: 2
Views: 6160
Reputation: 937
In my case simply restarting VS2010 helped fix the error. Anyone encountering this error might want to try that first.
(I am using VS 2010 with SP1)
Upvotes: 0
Reputation: 11
I can confirm that this problem was also solved for me by turning off Avast's behavior shield. Something is definitely not right with that. Endless MSBuild.exe
(and conime.exe
) processes and devenv.exe
maxing out the CPU. Seems to be a real system killer there by Avast. :-(
Upvotes: 1
Reputation: 21
it's actually just the behavior shield in avast that is causing the problems with visual studio. if you turn that off when trying to build, it will build and run. now we just need either microsoft or avast to create an update which will eliminate this problem. just discovered this 10 mins ago. at 2:50 pm 12/3/2011 central standard time in wisconsin
Upvotes: 2
Reputation: 941218
You've already eliminated KB2298853. Do make sure to install SP1. It is not the only reason, some other users have this problem too, even after the workaround. The basic failure appears to be a problem creating a pipe that lets msbuild talk to the IDE. Which is why it doesn't fail when you run msbuild from the command line.
This is an environmental problem, as yet undiagnosed. You need to chase down the reason the execution environment is unusual on your machine. Do so by selectively disabling or killing processes. Start with your malware software. Also, start another instance of Visual Studio and use Tools + Attach to Process to attach an unmanaged debugger to the first instance and/or msbuild. Debug + Break All and use Debug + Windows + Modules to find out what DLL might be injected in the process that is not made by Microsoft. Pay attention to the Path column. Not sure if Attach to Process is available on the Express edition btw.
Upvotes: 4