I recently inherited the responsibility of administering a TFS instance but I have no previous experience. The database for the Team Project seems to have grown abnormally large during the last 6 months, and reading up on everything I can find has helped me (I think) to identify the culprit, but I don't know what to do. Any help would be appreciated.
I've run the queries that are widely available such as this one:
SELECT TOP 3 o.name, SUM(reserved_page_count) * 8.0 / 1024 SizeInMB, SUM(CASE WHEN p.index_id <= 1 THEN p.row_count ELSE 0 END) Row_Count FROM sys.dm_db_partition_stats p JOIN sys.objects o ON p.object_id = o.object_id GROUP BY o.name ORDER BY SUM(reserved_page_count) DESC
To find this:
name SizeInMB Row_Count tbl_Content 313489.765625 10090278 tbl_Version 33400.828125 27518951 tbl_AggregateMap 10638.539062 32955145
And this other query too:
SELECT Owner = CASE WHEN OwnerId = 0 THEN 'Generic' WHEN OwnerId = 1 THEN 'VersionControl' WHEN OwnerId = 2 THEN 'WorkItemTracking' WHEN OwnerId = 3 THEN 'TeamBuild' WHEN OwnerId = 4 THEN 'TeamTest' WHEN OwnerId = 5 THEN 'Servicing' WHEN OwnerId = 6 THEN 'UnitTest' WHEN OwnerId = 7 THEN 'WebAccess' WHEN OwnerId = 8 THEN 'ProcessTemplate' WHEN OwnerId = 9 THEN 'StrongBox' WHEN OwnerId = 10 THEN 'FileContainer' WHEN OwnerId = 11 THEN 'CodeSense' WHEN OwnerId = 12 THEN 'Profile' WHEN OwnerId = 13 THEN 'Aad' WHEN OwnerId = 14 THEN 'Gallery' WHEN OwnerId = 15 THEN 'BlobStore' WHEN OwnerId = 255 THEN 'PendingDeletion' END, SUM(CompressedLength) / 1024.0 / 1024.0 AS BlobSizeInMB FROM tbl_FileReference AS r JOIN tbl_FileMetadata AS m ON r.ResourceId = m.ResourceId AND r.PartitionId = m.PartitionId WHERE r.PartitionId = 1 GROUP BY OwnerId ORDER BY 2 DESC
Owner BlobSizeInMB CodeSense 264426.749071121093 VersionControl 8728.462930678710 TeamTest 477.505887984375 ProcessTemplate 2.953623771484 FileContainer 0.024445533203
And while VersionControl = 8GB seems completely ok given our code, CodeSense is crazy large. I have not found info about that feature anywhere, or how to disable it. Please help!
PS: If it's related to the CodeLens feature in VS, we're not using it either.