TFS 2010-VersionControl.config无效,无法加载 [英] TFS 2010 - VersionControl.config is not valid and cannot be loaded

查看:223
本文介绍了TFS 2010-VersionControl.config无效,无法加载的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

最近,我们在TFS 2010上遇到了一个奇怪的问题。我们花了几天时间才弄清楚。只是想分享我对可能对其他人有帮助的问题的知识。



它在过去大约两年没有出现问题。但是突然之间,构建开始失败,并出现以下错误:


一次在此解决方案中构建项目。要启用
并行构建,请添加 / m开关。 MSBUILD:错误MSB4017:
由于意外的记录器
故障,构建意外停止。 Microsoft.Build.Exceptions.InternalLoggerException:由于记录器意外失败,生成
意外停止。 --->
Microsoft.TeamFoundation.VersionControl.Client.VersionControlException:
缓存文件
C:\Windows\system32\config\systemprofile\AppData\Local\ \Microsoft\Team
Foundation\3.0\Cache\VersionControl.config无效,无法加载
。请更正或删除文件。 --->
System.NullReferenceException:对象引用未设置为对象的实例
。在
Microsoft.TeamFoundation.VersionControl.Client.InternalCacheLoader.LoadConfig(InternalCache
currentCache,Boolean dataDirectoryExists,
InternalWorkspaceConflictInfo []&冲突的工作空间)-
内部异常堆栈的末尾跟踪---
Microsoft.TeamFoundation.VersionControl.Client.InternalCacheLoader.LoadConfig(InternalCache
currentCache,Boolean dataDirectoryExists,
InternalWorkspaceConflictInfo []&冲突的工作空间)


删除错误消息中提到的Cache文件夹的内容无济于事。



有一个巧合当时的2件事:




  • 服务器用尽了驱动器C中的可用空间:


  • 我们的支持人员正在安装Windows更新,包括用于TFS的Service Pack 1。




我们的某些项目是32位的,例如Silverlight,必须是32位,从来没有64位。
但是,我们的TFS服务器是64位。
为了正确地编译项目,构建定义应指定自动(与TFS服务器一样运行64位编译)或 X86来强制进行32位编译。



那些是X86的计算机突然突然出现上述错误。



解决方案:



显然,还有Cache文件夹的另一个位置:
C:\Windows\SysWOW64\config\systemprofile\AppData\Local\Microsoft\Team Foundation\ \3.0\Cache



我们删除了该文件夹的内容,一切开始正常运行。



BTW :与/ m开关无关。我们也尝试过,但是没有帮助。

解决方案

在磁盘空间不足警告后,我遇到了同样的问题。 / p>

删除/重命名文件C:\Users\user.name\AppData\Local\Microsoft\Team Foundation\4.0\Cache\ VersionControl.config解决了我的问题。


Recently, we experienced a strange problem with TFS 2010. We spent a few days before we figured it out. Just want to share my knowledge on the problem that might help other people.

It was working before with no problem for about 2 years. But suddenly, the builds started failing with the following error:

Building the projects in this solution one at a time. To enable parallel build, please add the "/m" switch. MSBUILD : error MSB4017: The build stopped unexpectedly because of an unexpected logger failure. Microsoft.Build.Exceptions.InternalLoggerException: The build stopped unexpectedly because of an unexpected logger failure. ---> Microsoft.TeamFoundation.VersionControl.Client.VersionControlException: The cache file C:\Windows\system32\config\systemprofile\AppData\Local\Microsoft\Team Foundation\3.0\Cache\VersionControl.config is not valid and cannot be loaded. Please correct or delete the file. ---> System.NullReferenceException: Object reference not set to an instance of an object. at Microsoft.TeamFoundation.VersionControl.Client.InternalCacheLoader.LoadConfig(InternalCache currentCache, Boolean dataDirectoryExists, InternalWorkspaceConflictInfo[]& conflictingWorkspaces) --- End of inner exception stack trace --- at Microsoft.TeamFoundation.VersionControl.Client.InternalCacheLoader.LoadConfig(InternalCache currentCache, Boolean dataDirectoryExists, InternalWorkspaceConflictInfo[]& conflictingWorkspaces)

Deletion of the contents of Cache folder mentioned in the error message did not help.

There was a coincidence of 2 things around that time:

  • the server was running out of free space in drive C:

  • our support people were installing Windows updates, including Service Pack 1 for TFS as well.

Some of our projects were 32 bit, like Silverlight for example, that must be 32 bit, never 64 yet. However, our TFS server is 64 bit. In order to compile projects properly, the build definitions should specify either "Auto" (that runs 64 bit compilation as the TFS server is) or "X86" that enforces 32 bit compilation.

Those ones that are X86 started failing all of a sudden with the error mentioned above.

SOLUTION:

Apparently, there is another location of Cache folder as well: C:\Windows\SysWOW64\config\systemprofile\AppData\Local\Microsoft\Team Foundation\3.0\Cache

We deleted the contents of that folder, and everything started working properly.

BTW: it has nothing to do with the /m switch. We tried it as well, but it did not help.

解决方案

I had the same issue after a low disk space warning.

Deleting/renaming the file C:\Users\user.name\AppData\Local\Microsoft\Team Foundation\4.0\Cache\VersionControl.config solved the issue in my case.

这篇关于TFS 2010-VersionControl.config无效,无法加载的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆