-1

I just created a new Build server and added it to an existing Queue, I turned off the other agents in the queue so that this new build server would get the job. I sent a very simple .NET build but the build window says "Waiting for an available agent" enter image description here

So I get it, I must have missed installing something on the build server. So when the job is submitted it's looking for an agent that can satisfy the "capabilities" How can I see that what capabilities the job needs so I can see why it's stuck?

Pat Delaney
  • 117
  • 10
  • 1
    What **version** of TFS? Did you look at the agent logs? – Daniel Mann Jun 19 '20 at 17:28
  • TFS 2018, and I forgot about the Agent logs, I can check them. – Pat Delaney Jun 22 '20 at 11:21
  • @PatDelaney Is there any update for this issue? You could check the service and the account for running the agent. – Kevin Lu-MSFT Jun 24 '20 at 00:56
  • So I am still trying to troubleshoot the issue. It would make it easier if I understood what happens with Queues.Currently I have a "test" queue that has 6 agents configured. Two if them are online. But the current Job says Waiting for Enabled Agent, All possible agents are disabled. So I am going to guess that when an agent starts, it registers it's capabilities with the Queue. When a job comes in the Queue sends it to the first available agent that meets the capabilities. Right now it appears that none of them do. So what I want to see is what capabilities does the queued job need? – Pat Delaney Jun 29 '20 at 17:33
  • You could check the required capabilities for the build job in `Build Definition -> Options -> Demands`. But in TFS2018, there is no demand requirement by default. – Kevin Lu-MSFT Jul 01 '20 at 08:38

1 Answers1

1

As far as I know, if the agent capabilities couldn't meet the build demands, it will show the warning message at the build result or queue time.

For example:

Warning

You could try the following points to troubleshooting:

  1. Navigate to Local machine->Service and check if the Visual Studio Team Foundation Background Job Agent is running on the TFS application tier server.

Service

You could start or restart this service.

  1. Make sure the account that the agent is run under is in the Agent Pool Service Account role or Project Collection Build Service Accounts and the account is a domain account.

TFS2015 -> Agent Pool Service Account

TFS2017 TFS2018 ->Project Collection Build Service Accounts

Change another available account for agent service, restart the service.

3.Restart the whole TFS server and check if this do the trick. Need some time to wait.

Here is another ticket with the similar issue, you could refer to it.

Hope this helps.

Kevin Lu-MSFT
  • 20,786
  • 3
  • 19
  • 28