1. Stop the project collection (i.e., DefaultCollection) from TFS Admin Console
  2. Detach the project collection from TFS Admin Console
  3. Detach the project collection database (i.e., tfs_defaulcollection) from SSMS (SQL Server Management Studio)
  4. Backup the project collection database from SSMS
  5. Shrink the project collection database  – Task -> shrink File -> shrink Database
  6. Clean/Delete unwanted records from the database
  7. Re-shrink the database again (see step 5)
  8. Attach the database (restore if you want to move it to a different server)
  9. Attach the project collection from TFS Admin Consol
  10. Start the project collection from TFS Admin Console
Advertisements