2
votes

We've had a stable TeamCity install (version 9.0.3 (build 32334)) for some months. It has a single build agent, MSBuild, which is on the same box as TC. Now, without changing any of the configuration the build agent is showing as Disconnected with the Inactivity Reason: "Agent has unregistered".

I've restarted TC and the box a couple of times but it won't connect. I've left it way longer than ten minutes.

The launcher.log file doesn't show anything different to when it connected successfully:

[2016-04-25 15:18:59,318]  DEBUG - .buildServer.agent.JavaChooser - Current Java runtime version is 1.7 
[2016-04-25 15:18:59,333]  DEBUG - dServer.agent.lock.LockManager - Lock file: C:\TeamCity\buildAgent\logs\buildAgent.properties.lock 
[2016-04-25 15:18:59,333]  DEBUG - dServer.agent.lock.LockManager - Using no lock 
[2016-04-25 15:19:02,344]  DEBUG - buildServer.agent.LauncherUtil - Deleting C:\TeamCity\buildAgent\update 
[2016-04-25 15:19:02,344]  DEBUG - buildServer.agent.LauncherUtil - Deleting C:\TeamCity\buildAgent\update 
[2016-04-25 15:19:02,344]  DEBUG - ldServer.agent.run.AgentRunner - Update folder deleted 
[2016-04-25 15:19:02,344]  DEBUG - buildServer.agent.LauncherUtil - Deleting C:\TeamCity\buildAgent\backup 
[2016-04-25 15:19:02,516]   INFO - dServer.agent.run.AgentProcess - Mon Apr 25 15:19:02 BST 2016 ==> Start launch 
[2016-04-25 15:19:02,516]  DEBUG - .buildServer.agent.JavaChooser - Current Java runtime version is 1.7 
[2016-04-25 15:19:02,516]   INFO - dServer.agent.run.AgentProcess - Launching agent with command:  c:\TeamCity\jre\bin\java -ea -Xmx512m -XX:+HeapDumpOnOutOfMemoryError -Xrs -Dlog4j.configuration=file:../conf/teamcity-agent-log4j.xml -Dteamcity_logs=../logs/ -classpath  {etc}

Is there something obvious I am missing?

Thanks

1

1 Answers

1
votes

I don't why it became Disconnected in the first place, but disabling it and then re-enabling it (and waiting) re-connected the build agent.