Teamcity not freeing up licenses on agent shutdown

Hi,

We have all of our agents in AWS that get spun down each night to save on cost and then new ones are spun up every morning. We currently have 2 Unauthorized agents that are unable to be authorized. In our Manage licenses tab the maximum number of agents is 14 which we were running earlier this week but now seem to be limited at 12. There are no agents listed in the Disconnected tab so Im not sure where to go from here. Is there a way we can manually flush these cached licenses/authTokens or any way to find out which tokens are saved so that I can modify the buildAgent.properties file?

Thanks,
Luke

7 comments
Comment actions Permalink

Hi, agents on Unauthorized tab do not consume licenses. Only connected and disconnected ones are taken into account.

From your message I didn't understand what is the # of agent licenses you have - 12 or 14?

0
Comment actions Permalink

Manage License lists 14 which is how many agents we had on Monday (see picture 1).

We can now only authorize 12. (see picture 2). As you can see Teamcity shows 0 disconnected agents and 12 connected.
The note on cloud-build06 is that the authorization token does not match the stored one but I have no way to clear this cached token.




picture_1.png



Attachment(s):
picture_2.png
0
Comment actions Permalink

You can simply click the agent link and choose Authorize. The agent will be registered right away. Since you have 2 free licenses, you can do this easily.

0
Comment actions Permalink

Except I cant because Teamcity doesnt think I have any avaiable licenses... When the agents are able to be authorized the text is blue and clickable which will launch the pool selection window. I dont have that option. I agree with you that I should have two free licenses but if you noticed in picture_2 Teamcity thinks they are all used.

0
Comment actions Permalink

So I got this working this weekend. I ended up spinning down all of our agents and removing them from Teamcity (disconnected and unauthorized tabs). Once all agents were removed Teamcity now allowed me access to our full 14 agents.

0
Comment actions Permalink

Similar problem was fixed in 9.0.3: https://youtrack.jetbrains.com/issue/TW-39887
I'd recommend upgrading your server.

0

Please sign in to leave a comment.