Problem with Multiple Build Agents (when there only should be one). Follow
Starting this morning I started getting this error on our TC build server:
Registering on server http://localhost:8080, AgentDetails{Name='WAVMIMG-DEV012', AgentId=null, BuildId=null, AgentOwnAddress='null', AlternativeAddresses=[10.109.225.160], Port=9092, Version='30168', PluginsVersion='30168-md5-ad48e15648cb3578cf16713dad3927e4', AvailableRunners=[Ant, dotnet-tools-dupfinder, dotnet-tools-inspectcode, Duplicator, FxCop, gradle-runner, Inspection, Ipr, jb.nuget.instal
ler, jb.nuget.pack, jb.nuget.publish, jetbrains.dotNetGenericRunner, jetbrains.mspec, jetbrains_powershell, JPS, Maven2, MSBuild, MSTest, NAnt, NUnit, rake-runner, simpleRunner, sln2003, VS.Solution], AvailableVcs=[perforce, mercurial, jetbrains.git, tfs, svn, cvs], AuthorizationToken='7483fb5068da8f8ae4edc3c444bdb7a9', PingCode='toxH2bqSGVvSTEqhaxJ5ZaPRfeBFmNn3'}
[2014-10-21 13:36:19,486] ERROR - buildServer.AGENT.registration - Agent id=null. Another agent with name "WAVMIMG-DEV012"(id=1) is registered on the server. Please check you do not have two agents with the same name.
[2014-10-21 13:36:19,486] WARN - buildServer.AGENT.registration - Connection to TeamCity server is probably lost. Will be trying to restore it. Take a look at logs/teamcity-agent.log for details (unless you're using custom logging).
[2014-10-21 13:36:22,486] WARN - buildServer.AGENT.registration - Connection to TeamCity server has been restored
Registering on server http://localhost:8080, AgentDetails{Name='WAVMIMG-DEV012', AgentId=null, BuildId=null, AgentOwnAddress='null', AlternativeAddresses=[10.109.225.160], Port=9092, Version='30168', PluginsVersion='30168-md5-ad48e15648cb3578cf16713dad3927e4', AvailableRunners=[Ant, dotnet-tools-dupfinder, dotnet-tools-inspectcode, Duplicator, FxCop, gradle-runner, Inspection, Ipr, jb.nuget.instal
ler, jb.nuget.pack, jb.nuget.publish, jetbrains.dotNetGenericRunner, jetbrains.mspec, jetbrains_powershell, JPS, Maven2, MSBuild, MSTest, NAnt, NUnit, rake-runner, simpleRunner, sln2003, VS.Solution], AvailableVcs=[perforce, mercurial, jetbrains.git, tfs, svn, cvs], AuthorizationToken='7483fb5068da8f8ae4edc3c444bdb7a9', PingCode='toxH2bqSGVvSTEqhaxJ5ZaPRfeBFmNn3'}
[2014-10-21 13:39:19,641] ERROR - buildServer.AGENT.registration - Agent id=null. Another agent with name "WAVMIMG-DEV012"(id=1) is registered on the server. Please check you do not have two agents with the same name.
[2014-10-21 13:39:19,641] WARN - buildServer.AGENT.registration - Connection to TeamCity server is probably lost. Will be trying to restore it. Take a look at logs/teamcity-agent.log for details (unless you're using custom logging).
[2014-10-21 13:39:22,641] WARN - buildServer.AGENT.registration - Connection to TeamCity server has been restored
Registering on server http://localhost:8080, AgentDetails{Name='WAVMIMG-DEV012', AgentId=null, BuildId=null, AgentOwnAddress='null', AlternativeAddresses=[10.109.225.160], Port=9092, Version='30168', PluginsVersion='30168-md5-ad48e15648cb3578cf16713dad3927e4', AvailableRunners=[Ant, dotnet-tools-dupfinder, dotnet-tools-inspectcode, Duplicator, FxCop, gradle-runner, Inspection, Ipr, jb.nuget.instal
ler, jb.nuget.pack, jb.nuget.publish, jetbrains.dotNetGenericRunner, jetbrains.mspec, jetbrains_powershell, JPS, Maven2, MSBuild, MSTest, NAnt, NUnit, rake-runner, simpleRunner, sln2003, VS.Solution], AvailableVcs=[perforce, mercurial, jetbrains.git, tfs, svn, cvs], AuthorizationToken='7483fb5068da8f8ae4edc3c444bdb7a9', PingCode='toxH2bqSGVvSTEqhaxJ5ZaPRfeBFmNn3'}
[2014-10-21 13:42:19,720] ERROR - buildServer.AGENT.registration - Agent id=null. Another agent with name "WAVMIMG-DEV012"(id=1) is registered on the server. Please check you do not have two agents with the same name.
[2014-10-21 13:42:19,721] WARN - buildServer.AGENT.registration - Connection to TeamCity server is probably lost. Will be trying to restore it. Take a look at logs/teamcity-agent.log for details (unless you're using custom logging).
[2014-10-21 13:42:22,721] WARN - buildServer.AGENT.registration - Connection to TeamCity server has been restored
Registering on server http://localhost:8080, AgentDetails{Name='WAVMIMG-DEV012', AgentId=null, BuildId=null, AgentOwnAddress='null', AlternativeAddresses=[10.109.225.160], Port=9092, Version='30168', PluginsVersion='30168-md5-ad48e15648cb3578cf16713dad3927e4', AvailableRunners=[Ant, dotnet-tools-dupfinder, dotnet-tools-inspectcode, Duplicator, FxCop, gradle-runner, Inspection, Ipr, jb.nuget.instal
ler, jb.nuget.pack, jb.nuget.publish, jetbrains.dotNetGenericRunner, jetbrains.mspec, jetbrains_powershell, JPS, Maven2, MSBuild, MSTest, NAnt, NUnit, rake-runner, simpleRunner, sln2003, VS.Solution], AvailableVcs=[perforce, mercurial, jetbrains.git, tfs, svn, cvs], AuthorizationToken='7483fb5068da8f8ae4edc3c444bdb7a9', PingCode='toxH2bqSGVvSTEqhaxJ5ZaPRfeBFmNn3'}
[2014-10-21 13:45:19,839] ERROR - buildServer.AGENT.registration - Agent id=null. Another agent with name "WAVMIMG-DEV012"(id=1) is registered on the server. Please check you do not have two agents with the same name.
[2014-10-21 13:45:19,839] WARN - buildServer.AGENT.registration - Connection to TeamCity server is probably lost. Will be trying to restore it. Take a look at logs/teamcity-agent.log for details (unless you're using custom logging).
[2014-10-21 13:45:22,839] WARN - buildServer.AGENT.registration - Connection to TeamCity server has been restored
we had recently changed our process to run the agent as an application (C:\TeamCity\buildAgent\bin\agent.bat start) in lieu from originally using the Windows build agent service:
I've made sure that the TeamCity Build Agent service is disabled on this system so it shouldn't be colliding with this.
the build server itself appears to be performing "normally" but the agent process appears to be in a bad state. I don't see where we're knowingly using two build agents.
any hints on how to debug this?
thanks,
Karl
Please sign in to leave a comment.
And as a possible side effect, we're getting duplicate email notifications of every build result.
Never mind, this was a different problem.
Hi Karl,
Which TeamCity version do you use?
Could you please check the list of processes running on this machine using Win Process Explorer? Do you have orphaned agent java.exe processes?
TC version:

TeamCity Professional 8.1.4 (build 30168)
And the only java instance that I can find is what's being used with TeamCityService.exe.
Added snapshot of the java instance on build server.
found that a cloned system was running an instance of the teamcity agent under same configuration.