SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


What Is Filling Up The Transaction Log


What Is Filling Up The Transaction Log

Author
Message
SQL Scripts Manager dev team
SQL Scripts Manager dev team
Grasshopper
Grasshopper (12 reputation)Grasshopper (12 reputation)Grasshopper (12 reputation)Grasshopper (12 reputation)Grasshopper (12 reputation)Grasshopper (12 reputation)Grasshopper (12 reputation)Grasshopper (12 reputation)

Group: General Forum Members
Points: 12 Visits: 3
Comments posted to this topic are about the item What Is Filling Up The Transaction Log
nhughes
nhughes
Forum Newbie
Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)Forum Newbie (4 reputation)

Group: General Forum Members
Points: 4 Visits: 75
I'd suggest that the code for [Log Used %] be changed to:

, CAST(CAST(CAST(lu.cntr_value AS FLOAT) / CAST(ls.cntr_value AS FLOAT) AS DECIMAL(18, 4)) * 100 AS DECIMAL(18, 2)) AS [Log Used %]

This gives you an additional 2 digits before doing your left shift so you don't always end up with results .00.



Preet_S
Preet_S
Old Hand
Old Hand (350 reputation)Old Hand (350 reputation)Old Hand (350 reputation)Old Hand (350 reputation)Old Hand (350 reputation)Old Hand (350 reputation)Old Hand (350 reputation)Old Hand (350 reputation)

Group: General Forum Members
Points: 350 Visits: 240
Title was full of promise, but we need more.
Ideally, we want to be able to determine what statements caused the log to grow so suddenly (and who issued the statements) and we want to do this automatically, not by running a query. i.e. at the time there is "excessive log file growth" alert the DBA providing a list of user-statements currently executing.
The tools and DMVs are out there but unfortunately do not provide a full picture (who, what, when, sql statements running). I think Profiler comes to the closest (Events "Log File Auto Grow" & "SQL:BatchCompleted") but even that involves monitoring and examining, not automatically alerting.
DBA_Learner
DBA_Learner
Old Hand
Old Hand (395 reputation)Old Hand (395 reputation)Old Hand (395 reputation)Old Hand (395 reputation)Old Hand (395 reputation)Old Hand (395 reputation)Old Hand (395 reputation)Old Hand (395 reputation)

Group: General Forum Members
Points: 395 Visits: 450
I have a scenario here:

On my TEMPDB, the log reuse wait description shows " Active_transaction".
Then I checked DBCC OPENTRAN('tempdb') . I got message showing there are no open transactions. Then I also queried:
select * from sys.dm_tran_active_transactions

I see some four 6 worktables. I don't know about these tables. Now how can I change my tempdb state to "Nothing".
DBA_Learner
DBA_Learner
Old Hand
Old Hand (395 reputation)Old Hand (395 reputation)Old Hand (395 reputation)Old Hand (395 reputation)Old Hand (395 reputation)Old Hand (395 reputation)Old Hand (395 reputation)Old Hand (395 reputation)

Group: General Forum Members
Points: 395 Visits: 450
When I restarted the server, tempdb - logreuse wait description showing 'Nothing'. So, is this the only way we need to do?
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search