Solved

What happens if the Log file properties Automatically grow box is unchecked and the log file runs out of space?

Posted on 2007-11-19
5
308 Views
Last Modified: 2008-02-01
Hi,
We just recently found that a database which only needs a simple recovery model had been using a full recovery model and we shrank the log file from 6Gig to 11MB.  Very good news, and useful to know.  A couple of other questions - though - so I don't become overconfident.
1) what information does the log file contain for a simple recovery model that is used for a database that is backed up every night?  A process each day "refreshes" the records in the database - deletes all today and imports and adds all of the next day.  I would assume that this daily activity adds info to the log file - doesn't it?  
2) we used the DBCC Shrinkfile command to shrink the size of the log file to 10MB.  That was not scientific, just a guess - and then we unchecked the box that says "Automatically Grow File" - was that wise or not?  What is the potential impact of having that box unchecked?  Could that cause our daily "refresh" to fail?  Would it just stop importing rows and we'd never know the difference?

thank you.
0
Comment
Question by:wendelina
  • 2
  • 2
5 Comments
 
LVL 16

Expert Comment

by:SQL_SERVER_DBA
ID: 20314782
you probably want to let it grow larger than 10 mb, some action queries can ecompass alot of growth, simple recovery with shrink the log for you if need be.
0
 
LVL 142

Expert Comment

by:Guy Hengel [angelIII / a3]
ID: 20314827
>1) what information does the log file contain for a simple recovery model
the same as for full recovery model. the "only" difference is that in simply recovery mode, the log entries are automatically marked as "overwritable". in full recovery mode, a log entry will only made overwritable upon transaction log backup (or full backup)

>I would assume that this daily activity adds info to the log file - doesn't it?  
yes

>2) we used the DBCC Shrinkfile command to shrink the size of the log file to 10MB.  That was not scientific,
indeed, but not important. the log file will grow eventually grow during that daily import, but once it has grown to the size needed, it will not grow again (of course assuming that the database remains in simple recovery mode).

> Could that cause our daily "refresh" to fail?  
it is possible, if the disk system, upon request of growing the file, could not fullfil that request fast enough.
however, that can only happen if the file is already quite large, the disk system too busy with other requests etc ...


0
 

Author Comment

by:wendelina
ID: 20314885
And would that be accomplished using the auto-shrink setting in the options tab?
0
 

Author Comment

by:wendelina
ID: 20314933
I guess simply put - should I REcheck that option to Automatically Grow the Log file - to avoid any future "gotchas"?  I certainly don't want to swing from one extreme (huge log that grows forever) to the other (tiny log that isn't large enough to sustain the daily log activity).
thanks
0
 
LVL 142

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 250 total points
ID: 20314986
>And would that be accomplished using the auto-shrink setting in the options tab?
leave that setting out. you should "never" use that, as it usually means less performance.



>should I REcheck that option to Automatically Grow the Log file
you should keep that checked on the log file... because if ever the log file cannot grow, any updateing change would be failing
0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Sql server insert 13 29
SQL - Update field defined as Text 6 16
SQL Count issue 24 15
abs operation in sql server 15 14
Slowly Changing Dimension Transformation component in data task flow is very useful for us to manage and control how data changes in SSIS.
For both online and offline retail, the cross-channel business is the most recent pattern in the B2C trade space.
Via a live example, show how to extract insert data into a SQL Server database table using the Import/Export option and Bulk Insert.
Using examples as well as descriptions, and references to Books Online, show the documentation available for datatypes, explain the available data types and show how data can be passed into and out of variables.

770 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