• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 565
  • Last Modified:

sql LDB (log) is groing to several Gb


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
Carlos-jm
Asked:
Carlos-jm
2 Solutions
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
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
 
nmcdermaidCommented:
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
 
arbertCommented:
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
 
Carlos-jmAuthor Commented:
Thank you
I'll try your sugestions.
I'll post results after.

Carlos
0

Featured Post

Upgrade your Question Security!

Add Premium security features to your question to ensure its privacy or anonymity. Learn more about your ability to control Question Security today.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now