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


Why is my transaction log full?


Why is my transaction log full?

Author
Message
GilaMonster
GilaMonster
SSC Guru
SSC Guru (223K reputation)SSC Guru (223K reputation)SSC Guru (223K reputation)SSC Guru (223K reputation)SSC Guru (223K reputation)SSC Guru (223K reputation)SSC Guru (223K reputation)SSC Guru (223K reputation)

Group: General Forum Members
Points: 223099 Visits: 46294
As you identified, the cause of the log being full is the active backup. The checkDB errors are all a result of the log being full, nothing else.

You need to identify why the backups are running so much longer than usual. Immediate thought - IO subsystem contention.

Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

We walk in the dark places no others will enter
We stand on the bridge and no one may pass


Scott D. Jacobson
Scott D. Jacobson
Ten Centuries
Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)

Group: General Forum Members
Points: 1322 Visits: 1020
Forgot to mention the tlog growth from the start as I was pretty sure that was also an issue. The log file growth was set to 10 % and the free space on the drive was about 10% of the entire drive. Obviously that's an issue. Changed that to 10 MB and am running another backup.


Gail, I think it's a combination of issues. I think they deleted a backup file that was still in progress. Is there any way to stop this backup operation that the sys.databases table thinks is still in progress?

Correction: The backup failed b/c the tlog ran out of space 2 days ago. There is no backup run Sunday night/Monday morning. Then a backup attempted to run this morning with the previous backup showing as still active in sys.databases. Ugh what a mess.
Scott D. Jacobson
Scott D. Jacobson
Ten Centuries
Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)

Group: General Forum Members
Points: 1322 Visits: 1020
I guess the question still is:

Is there any way to stop this backup operation that the sys.databases table thinks is still in progress?


A previous job was stopped and a job that followed that failed. It appears that SQL Server thinks the stopped job is still running. I can see no other indication of this other than ACTIVE_BACKUP_OR_RESTORE as the log_wait_reuse_desc in sys.databases. Even the location of the backup files is empty.
GilaMonster
GilaMonster
SSC Guru
SSC Guru (223K reputation)SSC Guru (223K reputation)SSC Guru (223K reputation)SSC Guru (223K reputation)SSC Guru (223K reputation)SSC Guru (223K reputation)SSC Guru (223K reputation)SSC Guru (223K reputation)

Group: General Forum Members
Points: 223099 Visits: 46294
New thread please. The discussion thread of an article is not the best place for a problem that isn't directly related to the article.

Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

We walk in the dark places no others will enter
We stand on the bridge and no one may pass


Sean Pearce
Sean Pearce
SSCarpal Tunnel
SSCarpal Tunnel (4K reputation)SSCarpal Tunnel (4K reputation)SSCarpal Tunnel (4K reputation)SSCarpal Tunnel (4K reputation)SSCarpal Tunnel (4K reputation)SSCarpal Tunnel (4K reputation)SSCarpal Tunnel (4K reputation)SSCarpal Tunnel (4K reputation)

Group: General Forum Members
Points: 4032 Visits: 3436
Hi Gail,

Can I please ask a quick question. In your article you say the following:

Log backup

The log backup wait reason will never appear in Simple Recovery.


Now I do agree this is a valid statement, however:

SELECT  database_id,
recovery_model_desc,
log_reuse_wait_desc
FROM sys.databases
WHERE log_reuse_wait_desc <> 'NOTHING'



database_id recovery_model_desc log_reuse_wait_desc
46 SIMPLE LOG_BACKUP

Why would I be seeing this?

Thanks



The SQL Guy @ blogspot

@SeanPearceSQL

About Me
GilaMonster
GilaMonster
SSC Guru
SSC Guru (223K reputation)SSC Guru (223K reputation)SSC Guru (223K reputation)SSC Guru (223K reputation)SSC Guru (223K reputation)SSC Guru (223K reputation)SSC Guru (223K reputation)SSC Guru (223K reputation)

Group: General Forum Members
Points: 223099 Visits: 46294
Has the DB just been switched from full or bulk-logged recovery? If so, run a checkpoint, sys.databases is not updated immediately, hence you can get 'log backup' occurring for a very short period after the DB has been switched to simple recovery model.

Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

We walk in the dark places no others will enter
We stand on the bridge and no one may pass


Robert Davis
Robert Davis
SSCertifiable
SSCertifiable (6.6K reputation)SSCertifiable (6.6K reputation)SSCertifiable (6.6K reputation)SSCertifiable (6.6K reputation)SSCertifiable (6.6K reputation)SSCertifiable (6.6K reputation)SSCertifiable (6.6K reputation)SSCertifiable (6.6K reputation)

Group: General Forum Members
Points: 6598 Visits: 1632
Artoo22 (11/22/2012)


Log backup

The log backup wait reason will never appear in Simple Recovery.


Now I do agree this is a valid statement, however:


Actually, that's not an accurate statement. This column records the reason the log file could not be truncated the last time it tried to do so. In simple recovery model, this means that it gets updated, if there is a reason, when a checkpoint occurs.

For example:





My blog: SQL Soldier
Twitter: @SQLSoldier
My book: Pro SQL Server 2008 Mirroring
Microsoft Certified Master, SQL Server MVP
Database Engineer at BlueMountain Capital Management
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