TFS 2010 中 witadmin 操作的日志在哪里? [英] Where are logs for witadmin actions in TFS 2010?
问题描述
从 Visual Studio 2010 命令行运行 witadmin 命令时,此操作记录在 TFS 2010 中的何处?一个示例命令是:
When running the witadmin command from the Visual Studio 2010 Command Line, where is this action logged in TFS 2010? An example command would be:
C:>witadmin exportwitd -collection:http://server:8080/tfs/projectcollection -p:TeamProject -n:Bug -f:c:\Bug.xml
C:>witadmin exportwitd -collection:http://server:8080/tfs/projectcollection -p:TeamProject -n:Bug -f:c:\Bug.xml
推荐答案
一种方法是查询收集数据库中的命令日志.注意:通常建议不要直接查询数据库,因为架构没有记录/支持并且可能在未来版本中更改.
One way to do this would be to query the command log in the collection database. Note: it's generally recommended not to query the database directly, since the schema is not documented/supported and could change in a future release.
select * from tbl_Command with (nolock) where useragent LIKE 'Team Foundation (witadmin.exe%'
'exportwitd' 命令将显示为 Command = 'GetMetadata'.但这也是 Visual Studio 在您连接到 TFS 时发出的相同命令,因此您需要在用户代理上进行过滤.
A 'exportwitd' command will show up as Command = 'GetMetadata'. But that is also the same command that Visual Studio makes when you connect to TFS, so you'll need to filter on the user agent.
'importwitd' 命令将显示为 Command = 'Update'
A 'importwitd' command will show up as Command = 'Update'
这篇关于TFS 2010 中 witadmin 操作的日志在哪里?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!