Solved

Transaction log

Posted on 2007-03-26
5
419 Views
Last Modified: 2012-06-27
How do I limit the size of a transaction log? How do I configure what happens when that size is reached? Is there an option that allows me to push out the eldest transaction, as the most recent comes in?

Thanks,

Christo Fourie.
0
Comment
Question by:idsafs
5 Comments
 
LVL 68

Expert Comment

by:Qlemo
ID: 18798494
* Limit size: DB properties -> Files, look for type = log, on the right there shoukld be a button to change the size limit.

* you cannot configure the reaction if max log file size is reached. The DBMS will reject any changing SQL command till space is freed in the log, or the size limit is removed.

* When DB recovery mode is "Simple", the transaction log space is freed as soon as possible. All other recovery models require you to backup the transaction log to free space.
0
 
LVL 7

Expert Comment

by:badbearontour
ID: 18798516
Hi,

Microsoft SQL Server Mananger
right mouse click on your database
Select Files in the popup database properties
Look at the grid and you will see the auto growth columns clcik on the button at the end of the box and on the log row, you will see your options

There is no option for a circular log, that would endanger you to not being able to recover a database! but you can grow a log at a certain rate or cap it at a size, but beware if the log fills up the database will stop

BB
0
 
LVL 8

Expert Comment

by:Julianva
ID: 18798517
You can limit the size using enterprise manager (sql 2000) or management studio(sql 2005)

right click on the database - chose properties - then chose transaction log - you will see the radio button to limit the size of the log file.

No there is no option to push out the oldest transaction.
you can truncate the entire log file.
you can also set the database to use simple or bullk logged recovery modes - so that sql server does not log every transaction. To do this you need to determine if at any time you will need to recover the database to a point in time.



0
 
LVL 1

Author Comment

by:idsafs
ID: 18798823
Hi.

Thanks for your replies! I misunderstood my superior. !The transaction log is not the problem, but this :

What our issue is is that the tempdb fills up as we go along Basically, from what I understand, the tempdb is created new each time the server starts, this then grows as things are done in any active db.  It is this growing that we need to restrict, nothing to do with the active/production db.

Any ideas?
0
 
LVL 8

Accepted Solution

by:
Julianva earned 500 total points
ID: 18799560
where is you tempdb database files situated.  you can move the temp db to a drive that has enough space to accomodate the growth of tempdb and leave the growth option to unrestricted..

You can also create a maintenance job to truncate the tempdb and shrink it.
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Sql query 12 65
Change variables in SQL table 6 68
execute a MS SQL script as a schedule SQL job 72 98
Problem with SqlConnection 5 115
by Mark Wills PIVOT is a great facility and solves many an EAV (Entity - Attribute - Value) type transformation where we need the information held as data within a column to become columns in their own right. Now, in some cases that is relatively…
Introduction: When running hybrid database environments, you often need to query some data from a remote db of any type, while being connected to your MS SQL Server database. Problems start when you try to combine that with some "user input" pass…
It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…

758 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

20 Experts available now in Live!

Get 1:1 Help Now