Blog Post

VSTS - Offline Build Agent

Wednesday, October 26, 2016 5:13 AM

So you have started to look into the new build system for VSTS 2015 and have encountered some issues. In this post I’ll show you how I troubleshooted and fixed an offline build agent. If the following screenshot looks familiar then keep reading.

It comes down to permissions. Below are the steps that you can follow to confirm and correct the problem.

1) Log onto the build machine where the remote agent is installed and verify the account used by the service is correct. Normally I would suggest that a dedicated account for TFS build be used here. If the agent is offline then the service will not be running. No point in starting it until we fix the issue so let’s keep digging.

2) Now visit the installation directory where the Agent was unzipped and installed. Open the ‘_diag’ folder to access the logs. Open the most recent log and scan through it. You will more than likely find an error like: ‘[Service Account] needs Listen permissions for pool [Name] to perform the action’ repeated through the log.

3) Ok. Now we have identified the issue. We are missing a permission in the build configuration. Go back to the ‘Agent Pools’ page and expand your Pool to view the security groups. If you open the ‘Agent Pool Service Accounts’ you will more than likely see an empty group. Add your service account in there.