How to force sln2005 use all CPU cores

When I use sln2005 builder on an agent with 4 cores, only one cl.exe process runs and thus only one core is utilized. However when I start Visual Studio on the agant directly, it starts four cl.exe and compiles approx. 4 times quicker.

It seems to be well-know concern, but I have not managed to find it

Could you help me out please?

P.S. TeamCity Enterprise Version 4.5.4 (build 9071)

1 comment
Comment actions Permalink

MSBuild from .NET 3.5 added support for multicore execution.
To run builds for .NET 2.0 you will have to use MSBuild 3.5 with target platform set to 2.0.
For more details, please have a look at

There is no any explicit support for parallel MSBuild execution in TeamCity.
To enable it,

Use /maxcpucount:number in the Command line parameters in the MsBuild
runner settings: .


Please sign in to leave a comment.