TFS Build Agent已停止

时间:2012-04-10 10:05:32

标签: tfs2010 build-server

我遇到了正在运行的构建计算机的问题,代理突然不想启动。它是远程控制器的一部分,如果启动本地控制器,则可以解决此问题。症状是,在代理初始化正确(表示'准备'),但有停止的图标,并在状态区域说'BuildController尚未在1分钟内启动。运行构建服务的AD帐户适用于另一台构建计算机(单独的控制器+构建代理程序)。我试过以下

  • 重新安装构建服务
  • 使用计算机名称,完全限定的域名和端点地址的IP地址
  • 运行
  • 取消注册并重新注册构建服务
  • 重新启动
  • 使用script
  • 清理了构建代理注册

如果我将运行构建服务的服务帐户更改为我自己的AD帐户,则可以正常运行。但是,在我们的专用构建用户下运行会在这台特定的机器上运行,而不是另一台机器。有什么建议吗?这是事件日志中的错误:

Service 'Default Agent - tfs2010build1' had an exception: 
Exception Message: There was no endpoint listening at http://tfs2010build1:9191/Build/v3.0/Services/Controller/31 that could accept the message. This is often caused by an incorrect address or SOAP action. See InnerException, if present, for more details. (type EndpointNotFoundException)

Exception Stack Trace: 
Server stack trace: 
   at System.ServiceModel.Channels.HttpOutput.WebRequestHttpOutput.GetOutputStream()
   at System.ServiceModel.Channels.HttpOutput.Send(TimeSpan timeout)
   at System.ServiceModel.Channels.HttpChannelFactory.HttpRequestChannel.HttpChannelRequest.SendRequest(Message message, TimeSpan timeout)
   at System.ServiceModel.Channels.RequestChannel.Request(Message message, TimeSpan timeout)
   at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan timeout)
   at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage methodCall, ProxyOperationRuntime operation)
   at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)

Exception rethrown at [0]: 
   at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)
   at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)
   at Microsoft.TeamFoundation.Build.Machine.IBuildControllerService.TestConnectionFromController(String agentUri)
   at Microsoft.TeamFoundation.Build.Machine.ServiceProxies.ServiceProxy`1.<>c__DisplayClass3.<Do>b__2(T channel)
   at Microsoft.TeamFoundation.Build.Machine.ServiceProxies.ServiceProxy`1.Do[TResult](Func`2 action)
   at Microsoft.TeamFoundation.Build.Machine.BuildAgentService.<>c__DisplayClass12.<TestConnection>b__11(Object )

Inner Exception Details:

Exception Message: Unable to connect to the remote server (type WebException)
Exception Stack Trace:    at System.Net.HttpWebRequest.GetRequestStream(TransportContext& context)
   at System.Net.HttpWebRequest.GetRequestStream()
   at System.ServiceModel.Channels.HttpOutput.WebRequestHttpOutput.GetOutputStream()

Inner Exception Details:

Exception Message: No connection could be made because the target machine actively refused it 127.0.0.1:38742 (type SocketException)

Exception Stack Trace:    at System.Net.Sockets.Socket.DoConnect(EndPoint endPointSnapshot, SocketAddress socketAddress)
   at System.Net.ServicePoint.ConnectSocketInternal(Boolean connectFailure, Socket s4, Socket s6, Socket& socket, IPAddress& address, ConnectSocketState state, IAsyncResult asyncResult, Int32 timeout, Exception& exception)

2 个答案:

答案 0 :(得分:1)

发现问题。在IE选项下启用了代理服务器。不确定为什么构建服务在我的AD用户帐户下工作而不是专用构建用户,但它解决了问题。

----&GT;&GT;&GT;&GT;&GT;更新!

所以我们有2台机器(B1和B2),每台机器有2个代理。 B1有初始问题,并通过禁用IE下的代理设置来解决。昨天B2突然开始在2个代理上显示相同的症状和错误消息。代理设置未启用。虽然它确实修复了B1,但它并不是解决这一特定问题的通用解决方案。 保持这些构建代理运行是很困难的:( - TeamCity小姐......

----&gt;&gt;&gt;&gt;再次更新! 所以昨天当我查看代理配置时,它没有设置。但是今天早上复选框已经过检查。禁用代理,代理上线。很奇怪的行为!不知道Windows Update是否更改了这些设置......

答案 1 :(得分:1)

当我被迫手动停止构建时,我经常遇到与代理相同的问题。我无法找到任何合适的解决方案。