Solved

SQL server 2005: Big LDF file

Posted on 2013-05-15
4
564 Views
Last Modified: 2013-05-16
Hi there,
I have a SQL server 2005 and I have a LDF file over 50Go.
How does it clean it ? Is it risks ?
Thanks,
Regards,
Simlip
0
Comment
Question by:simlip
4 Comments
 
LVL 25

Assisted Solution

by:jogos
jogos earned 125 total points
Comment Utility
See in options of your db what recovery model is.

Most likely
If it is FULL you must take a transactionlog backup (that will take that full size) .  
Or simpler because you don't take transactionlog backups (to have a point in time restore) then you don't need a FULL-model so if you change it in recovery model SIMPLE then the transactions in the LDF will be released and the file stops from growing.
0
 
LVL 10

Assisted Solution

by:sqlservr
sqlservr earned 125 total points
Comment Utility
If your databases  Recovery mode is in Full Recovery mode then you have to make practice of  taking Transaction log backup.
if your database is in SIMPLE recovery mode then check for open transaction
to check open transaction run
DBCC OPENTRAN In the selected databases.
0
 
LVL 68

Accepted Solution

by:
Qlemo earned 125 total points
Comment Utility
The difference between Full/Bulk-logged recovery and Simple is that Simple holds transactions in the LDF only as long as needed (written completely into the MDF).
If the MDF gets lost, and you need recovery, you will have only the DB backup itself to do that. If you back your DB up once a day, you will have a DB backup which is at most 24 hours old.

Full/Bulk-logged however does not remove transactions from the LDF files, unless you perform a transaction log backup, as mentioned above. This mode makes sense if you need a more accurate backup, and can't or don't want to perform a frequent DB backup. Common schedule is e.g. DB backup once a day, and transaction log backups every few hours.
If the MDF file gets corrupt or lost, recovery is still possible up to the last transaction log backup, and if the LDF files are still intact, even to the most recent point in time.

For small DBs you usually do not want to care about transacton log backups, and Simple Recovery mode is your best choice in combination with a daily DB backup.
0
 
LVL 25

Assisted Solution

by:Lee Savidge
Lee Savidge earned 125 total points
Comment Utility
0

Featured Post

6 Surprising Benefits of Threat Intelligence

All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

Join & Write a Comment

Suggested Solutions

When you hear the word proxy, you may become apprehensive. This article will help you to understand Proxy and when it is useful. Let's talk Proxy for SQL Server. (Not in terms of Internet access.) Typically, you'll run into this type of problem w…
Ever wondered why sometimes your SQL Server is slow or unresponsive with connections spiking up but by the time you go in, all is well? The following article will show you how to install and configure a SQL job that will send you email alerts includ…
Familiarize people with the process of utilizing SQL Server functions from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Microsoft Ac…
Using examples as well as descriptions, and references to Books Online, show the documentation available for date manipulation functions and by using a select few of these functions, show how date based data can be manipulated with these functions.

763 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now