My TfsVersionControl database has grown to 40 + GB. We recently made a TFS Destroy in a folder tree that should have cleared at least 10 GB, but instead it had no effect.
When I look at tables in TfsVersionControl, I am primarily shocked to see that there are no foreign keys in the database. Running a few queries, I see that orphanhood is happening:
- tbl_Content has 13.9 GB of records that do not have an associated tbl_File record
- tbl_File and tbl_Content have 2.4 GB that do not have an associated tbl_Namespace record
The cleanup work seems to be done nightly (prc_DeleteUnusedContent), and running it against the database manually does not remove the orphans. I see in the log for cleaning work that it failed 3/16, which is the morning after I destroyed a large amount of data. The error occurred due to the complete transaction log.
Could this error be the reason that I was left with all these lost screens that cannot be removed? How can I permanently destroy this unnecessary content?
source share