Solved

How to reduce the size of SQL Server log files

Posted on 2014-07-30
2
172 Views
Last Modified: 2014-08-03
How to reduce the size of MS SQL Server log files. I have an example where the .mdf file is 168Mb, but the .ldf file is 3Gb. I also have another where the .ldf is 189Gb.
0
Comment
Question by:BishopsWaltham
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 143

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 500 total points
ID: 40228530
please read up this article first for a full understanding of why the log files are getting large, followed by how to keep them "small" in normal time and how to perform a one-shot shrinking:
http://www.experts-exchange.com/Database/MS-SQL-Server/A_11077-How-to-shrink-a-bloated-log-file.html

NOTE: do not perform regular (like daily) shrinks of the database or log files, this would just be waste of IO and slow down your db operations during the day
0
 
LVL 25

Expert Comment

by:Mohammed Khawaja
ID: 40228690
Best practice is to backup your DB and then the TLOGs and ensure to select the option "truncate at checkpoint" in your backup software.  This way logs will be flushed after successful backup.
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Problem: Windows 32bit running out of paging space. Solution: Add additional page files on separate partitions. Background: By default Windows creates only one page file on the partition you install Windows on. You may know that the maximu…
Hello, As I have seen there a lot of requests regarding monitoring and reporting for exchange 2007 / 2010 / 2013 I have decided to post some thoughts together and link to articles that have helped me. Of course a lot of information you can get…
Michael from AdRem Software outlines event notifications and Automatic Corrective Actions in network monitoring. Automatic Corrective Actions are scripts, which can automatically run upon discovery of a certain undesirable condition in your network.…
If you’ve ever visited a web page and noticed a cool font that you really liked the look of, but couldn’t figure out which font it was so that you could use it for your own work, then this video is for you! In this Micro Tutorial, you'll learn yo…
Suggested Courses

622 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