Link to home
Start Free TrialLog in
Avatar of churchhousetrust
churchhousetrust

asked on

SQL Server 2005 massive ldb file

Hi

We have 2x Test Databases that are not used very often, however both of these DB's (both on seperate SQL servers) have huge ldf files - 1x @ 102gb and the other at 180gb.  I have ran a shrink on the 180gb to reduce it down to 160 but do not know how else to reduce it anymore.

ideas?

thanks
ASKER CERTIFIED SOLUTION
Avatar of Lee
Lee
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
hi churchhousetrust,


 The database cannot be made smaller than the minimum size of the database. The minimum size is the size specified when the database was originally created, or the last explicit size set by using a file-size-changing operation, such as DBCC SHRINKFILE. For example, if a database was originally created with a size of 10 MB and grew to 100 MB, the smallest size the database could be reduced to is 10 MB, even if all the data in the database has been deleted.

Please Check this article:

http://technet.microsoft.com/en-us/library/ms189035.aspx

Thanks
below given script may be useful, try using your database name and log file name.
ALTER DATABASE AdventureWorks 
SET RECOVERY SIMPLE;
GO
 
DBCC SHRINKFILE('AdventureWorks_Log', 1)
 
ALTER DATABASE AdventureWorks 
SET RECOVERY FULL;
GO

Open in new window