How to shrink SQL Server transaction logs

0 Likes

Problem:

How to shrink SQL Server transaction logs

Resolution:

  • Product Name: StarTeam
  • Product Version: All
  • Product Component: Database
  • Platform/OS Version: All Supported OS

Description:
Sometimes SQL Server transaction logs reach a very large size for the StarTeam database.




Answer/Solution:
To do this, you need a tool to execute sql queries on your StarTeam database (preferably Query Analyzer). Execute "BACKUP LOG pubs TO pubslogbackup", where "pubs" is the database name, in order to make a backup of the transaction log. Then execute "DBCC SHRINKFILE(pubs_log,2)", where "pubs_log" is the name of the log file and 2 is the target size of the log file in MBs. This will shrink the log file to the desired size.




Author: Levi Bowman

Old KB# 28562
Comment List
Related
Recommended