Reputation: 1
We currently have upgraded our Team Foundation Server 2015 to Team foundation server 15, RC1. But i cannot get our existing or new build agents running. The error we got is always the same. No agent pool found with identifier 1 (or 2, ....).
I have checked the database and there is an agent pool with that ID.
Any idea anyone?
thanks.
Upvotes: 0
Views: 5186
Reputation: 6744
I had the exact same thing: an existing build server, which was working until somebody upgraded it. Error message in the .\BuildAgent_Diag\ folder kept saying
Failed to create session. Sleeping for 10 seconds before next retry
----------------------------------------
Microsoft.TeamFoundation.DistributedTask.WebApi.TaskAgentPoolNotFoundException: No agent pool found with identifier 7.
I already had the service running as a domain account with "build admin" permissions.
The solution was to run 'ConfigureAgent' again: Open a command prompt as administrator. Change directory to your 'BuildAgent' folder (or where ever your 'ConfigureAgent.cmd' file is located) and run 'ConfigureAgent.cmd'. It will ask a few questions. I stayed with the current settings. I had to enter the password for the service account. Eventually the wizard completed and everything worked again.
Upvotes: 0
Reputation: 1
Thanks for your time, however the issue is solved with Microsoft support. It turned out that my default access level was stakeholder, while build permissions are in the basic. So i had to change the default access level to Basic. That's obvious a bug in the new RC1, but like you said, it was some kind of a permission issue.
thanks again.
Upvotes: 0
Reputation: 51073
If the build agent pool definitely exists, but the error is can't find the agent pool. Then the issue is very likely related to permissions.
When configuring the build agent(new created or existed), you need to make sure the account which running the configure command or script have enough permission.
The user account needs to be part of the Agent Pool Administrator Accounts.
Update
Try below ways to narrow down the issue:
https://YOURCOMPANYNAME:8080/tfs/_admin/_AgentQueue
, andUpdate 2
Browse the Control Panel - Team Project Collection - Team Project- Agent queues- click agent pool - Roles- click Add... - Add your user ID and select Administrator in Role
After this try again.
Upvotes: 1