In the previous post (Understanding Build Controller and Build Agent), I explained that we can’t install multiple Build Controllers on the same machine. However, there is a workaround or hack that we can use, although it is not supported by Microsoft and not recommended for a production environment. It should only be used for demo machines. Below is a step-by-step video for the post:
Open the command line as Administrator and create a Windows service and associate it with TFSBuildServiceHost.exe. Make sure to leave a space before “=” and you should see success:
1
sc create Radwan-Service binPath= "C:\Program Files\Microsoft Team Foundation Server 11.0\Tools\TfsBuildServiceHost.exe /NamedInstance:Radwan-Service" DisplayName= "Radwan-DisplayName"
Open the services to review the created service.
Set the Environment Variable for TFS Build Service.
Launch TfsMgmt.exe to configure the created build service and click on Register, noticed that it shows that build not configured and this for the created service but if we open the TFS Administration Console and navigate to Build Configuration we will find the old service configured.
Change the port to be different from the running service now, let it be 9195.
Create a new Build Controller for that service.
Create a new Build Agent for the created Build Controller.
Review the new service with it's Build Controller and Build Agent.
Review the old service with it's Build Controller and Build Agent.
Links: