[Last Call] Learn about multicloud storage options and how to improve your company's cloud strategy. Register Now

x
?
Solved

sql LDB (log) is groing to several Gb

Posted on 2004-09-15
4
Medium Priority
?
560 Views
Last Modified: 2008-02-01

Hi everyone,

I've got a application working with SQL MSDE an four databases.
OS is 2003 small Business server
I've four workstations

My problem is thar the LDB (log) files in 8 working days as gone from several Kb to 17 Gb that's right GigaBytes.

What can be causing this ?????????

Can someone help, please.

Thank you,

Carlos
0
Comment
Question by:Carlos-jm
[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
4 Comments
 
LVL 143

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 1200 total points
ID: 12062820
Disable the Autogrow option from the Transaction log file(s), and/or set the Max Size for the transaction log file(s).
Additionally, if your database contains non-critical data, if there is no backup or data can be easily recreated, then set the database RECOVERY MODEL to simple.
Otherwise, have the recovery model to full (or bulk-logged if needed), and perform full and transaction log backups regulary (full once per day/week, transaction log every 1,4 or 12 hours ) depending on the size and disaster recovery plan you implement.
To reduce your explosed log file, please search EE for the same problem SHRINK TRANSACTION LOG FILE, you will get tons of same requests.
Cheers
0
 
LVL 30

Assisted Solution

by:nmcdermaid
nmcdermaid earned 800 total points
ID: 12062849
The log file records all the transactions that take place in your database. If there are a lot of inserts/deletes/updates going on, or for example you are importing lots of data, the log file will grow.

It usually shrinks automatically again over time, (under various circumstances).

A couple of database options that effects this file are the recovery model and the auto shrink setting

to find out what this is, issue this SQL to the database (or scratch around in Enterprise Manager and use that):

SELECT DATABASEPROPERTYEX('<your database name>','recovery')

(You would expect to see it return 'SIMPLE' as this is the default setting for MSDE)

SELECT DATABASEPROPERTYEX('<your database name>','IsAutoShrink')

(You would expect to see it return 1 as this is the default setting)


If these setting are at their default, then we need to look elsewhere for the reason.


To summarise, lots of data alterations make the log grow, various complicated things make the log automatically shrink again... we can get into the complicated things after you reteive those settings.


There are lots of questions about log files on this newsgroup so if you have the capability, you should search the newsgroup too.
0
 
LVL 34

Expert Comment

by:arbert
ID: 12066332
Personally, I wouldn't set the log file to not "Auto Grow".  You could find yourself out of logspace one day and your database "suspect"....

Other than that, I agree with what angellIII has said above....Put a good backup strategy in place and schedule DBCC SHRINKFILE on your logs...
0
 

Author Comment

by:Carlos-jm
ID: 12070059
Thank you
I'll try your sugestions.
I'll post results after.

Carlos
0

Featured Post

Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

Question has a verified solution.

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

Ready to get certified? Check out some courses that help you prepare for third-party exams.
One of the most important things in an application is the query performance. This article intends to give you good tips to improve the performance of your queries.
Via a live example, show how to extract information from SQL Server on Database, Connection and Server properties
Via a live example, show how to setup several different housekeeping processes for a SQL Server.

650 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