简体   繁体   English

服务器无法使用 Team Foundation 服务 - 无法解析远程名称

[英]Team Foundation services are not available from server - The remote name could not be resolved

We are working with Visual Studio 2010 and Team Foundation Server 2010. We did not have any problems for about half a year, but:我们正在使用 Visual Studio 2010 和 Team Foundation Server 2010。大约半年我们没有出现任何问题,但是:

Since a couple of days we get the following error: Team Foundation services are not available from server (...) The remote name could not be resolved;几天后,我们收到以下错误:服务器无法使用 Team Foundation 服务 (...) 无法解析远程名称; (...) (……)

Team Foundation Server 2010 不可用

The problem occurs randomly (we are unable - yet - to pinpoint the conditions on which it occurs) and persists until we restart Visual Studio.该问题是随机发生的(我们还无法确定其发生的条件)并且一直存在,直到我们重新启动 Visual Studio。 The problem occurs about 8 times per day per developer.每个开发人员每天大约会出现 8 次该问题。

Because we seem not to get past this problem and we cannot find anybody writing about this specific combination (the error and the 'remote name' part), I thought it wise to ask you guys about it ;) .因为我们似乎没有解决这个问题,而且我们找不到任何人写过这个特定的组合(错误和“远程名称”部分),我认为向你们询问它是明智的;)。 Could anyone please help?有人可以帮忙吗?

This is a client, server or infrastructure related problem on network level.这是网络级别的客户端、服务器或基础架构相关问题。 The DNS entry for your TFS server cannot be resolved correctly at times for host dfz-vm223.有时无法正确解析主机 dfz-vm223 的 TFS 服务器的 DNS 条目。

Suggestions for troubleshooting:故障排除建议:

  1. On some developer systems, replace the hostname dfz-vm223 by the ip-address of the TFS server.在某些开发人员系统上,将主机名 dfz-vm223 替换为 TFS 服务器的 ip 地址。 If the problem stop occuring there the DNS system is instable.如果问题不再出现,则说明 DNS 系统不稳定。
  2. Setup a continuous ping stream (ping -t dfz-vmm223 from command window) and see if the host system is pingable in case you have TFS server problems.设置连续的 ping 流(从命令窗口 ping -t dfz-vmm223)并查看主机系统是否可以 ping 以防万一您遇到 TFS 服务器问题。

Just found out what the problem was: the problem is proxy related.刚刚发现问题出在哪里:问题与代理有关。 When we disable our proxy, the problem is gone.当我们禁用我们的代理时,问题就消失了。 It appears our proxy and TFS are troublesome together.看来我们的代理和TFS在一起很麻烦。 If anyone experiences the same problem and you are working with a proxy server, I would suggest you try disabling the proxy too.如果有人遇到同样的问题并且您正在使用代理服务器,我建议您也尝试禁用代理。

I had the same problem, although I'm using VS2012 and a WAN connection to TFS.我遇到了同样的问题,尽管我使用的是 VS2012 和到 TFS 的 WAN 连接。

I solved the problem by flushing the DNS cache.我通过刷新 DNS 缓存解决了这个问题。

To flush the DNS cache, start a command prompt with admin rights: ipconfig /flushdns要刷新 DNS 缓存,请使用管理员权限启动命令提示符: ipconfig /flushdns

You need to do this in all the computers where the problem occurs.您需要在出现问题的所有计算机上执行此操作。

I know this is old, but I had this problem sometimes when I ran Fiddler.我知道这很旧,但是当我运行 Fiddler 时,有时会遇到这个问题。

Sometimes Fiddler would crash or not clean up properly and the whole machine would get into some weird state where not even reboots were helping.有时 Fiddler 会崩溃或无法正确清理,整个机器会进入某种奇怪的状态,甚至重新启动也无济于事。 The solution to it usually is to start Fiddler again, turn off any interceptors/collecting traffic and shut it down again.解决方法通常是再次启动 Fiddler,关闭任何拦截器/收集流量并再次关闭它。

Hade the same issue.有同样的问题。 For whatever reason the windows DNS Client service on my PC wasn't running.无论出于何种原因,我的 PC 上的 Windows DNS 客户端服务都没有运行。 Changing it from Disabled to Automatic solved this problem for me.将其从禁用更改为自动为我解决了这个问题。

Some of my co-workers and I had this problem as well.我和我的一些同事也遇到了这个问题。 Out of about 25 developers, most never got this error.在大约 25 名开发人员中,大多数人从未遇到过此错误。 But three of us got it pretty consistently.但是我们三个人都得到了相当一致的结果。 The symptoms are identical, but we are using Visual Studio 2013 almost exclusively.症状是相同的,但我们几乎只使用 Visual Studio 2013。 In this version of Visual Studio, the error is preceded by the code: TF400324.在此版本的 Visual Studio 中,错误前面带有代码:TF400324。

We found eventually that the three of us had all installed Productivity Power Tools 2013. And the developers that were not affected by this error had not installed it.我们最终发现我们三个人都安装了 Productivity Power Tools 2013。而不受此错误影响的开发人员没有安装它。 Most had not heard of it.大多数人没有听说过。 This used to be a very popular extension, so I have always installed it as I set up my system since about 2007. But apparently, in its modern incarnation in Visual Studio 2013, perhaps in combination with some quirk in our network or something, it can cause this problem.这曾经是一个非常受欢迎的扩展,所以我从 2007 年左右开始设置系统时一直安装它。但显然,在 Visual Studio 2013 的现代化身中,也许结合我们网络中的一些怪癖或其他东西,它会导致这个问题。 We have each uninstalled it, and have not gotten this error since.我们每个人都卸载了它,从那时起就没有出现这个错误。 (It's been several months now.) (现在已经几个月了。)

If you have this extension installed, you probably already know about it, because you probably installed it yourself.如果你安装了这个扩展,你可能已经知道它,因为你可能自己安装了它。 You probably started using it years ago, and it became a habit to add to each new installation.您可能在几年前就开始使用它,并且将添加到每个新安装中已经成为一种习惯。 You will find that today, the default installation of Visual Studio actually includes most of its features already.您会发现,今天,Visual Studio 的默认安装实际上已经包含了它的大部分功能。 To uninstall, go to Tools --> Extensions and Updates... Then click on Productivity Power Tools 2013, and click Uninstall.要卸载,请转至工具 --> 扩展和更新...然后单击 Productivity Power Tools 2013,然后单击卸载。

I have also experienced this problem and it doesn't always have to do with name resolution.我也遇到过这个问题,它并不总是与名称解析有关。

If you add an entry to your %systemroot%/system32/drivers/etc/hosts file for your TFS server, it removes any dependance on your name resolution servers.如果您将条目添加到您的 TFS 服务器的 %systemroot%/system32/drivers/etc/hosts 文件,它会删除对您的名称解析服务器的任何依赖。

If you are still experiencing the problem, then it has to do with either visual studio or one of the VS Extensions that you are running.如果您仍然遇到问题,那么它与 Visual Studio 或您正在运行的 VS 扩展之一有关。 There may be a memory leak somewhere.某处可能存在内存泄漏。 Disable all your Extensions using the extension manager, restart VS, and see if you still experience the problem.使用扩展管理器禁用所有扩展,重新启动 VS,看看是否仍然遇到问题。

Too long for comments:评论太长:

First off, as @kroonwijk stated, this is an infrastructure issue.首先,正如@kroonwijk 所说,这是一个基础设施问题。 Your DNS queries are either timing out or the DNS server is not responding at certain times.您的 DNS 查询超时或 DNS 服务器在某些时候没有响应。

In a comment you mentioned a change over from regular machines to laptops for your entire dev team.在评论中,您提到整个开发团队从普通机器改为笔记本电脑。 If I had to make a bet I'd say that the DNS configuration on the laptops is not the same as what you had on the other machines.如果我不得不打赌,我会说笔记本电脑上的 DNS 配置与您在其他机器上的配置不同。

You need to take this up with your infrastructure people.您需要与您的基础设施人员一起解决这个问题。 If you still have access to the older machines boot one of them up and compare the IP configuration.如果您仍然可以访问较旧的机器,请启动其中一台并比较 IP 配置。 If not, get them to fix the problem.如果没有,请让他们解决问题。 The DNS resolution problem could be any one of a number of factors. DNS 解析问题可能是多种因素中的任何一种。 For example, the new machines could be pointing to an incorrect DNS server that has network issues or their might be some incompatibility between how Win7 makes DNS requests and your DNS server.例如,新机器可能指向存在网络问题的错误 DNS 服务器,或者它们可能是 Win7 发出 DNS 请求的方式与您的 DNS 服务器之间的某些不兼容。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM