Less Than Dot is a community of passionate IT professionals and enthusiasts dedicated to sharing technical knowledge, experience, and assistance. Inside you will find reference materials, interesting technical discussions, and expert tips and commentary. Once you register for an account you will have immediate access to the forums and all past articles and commentaries.
Forum Search
Forum Statistics
UsersTotal Post History
- Posts:
- 45705
- Topics:
- 9398
7-Day Post History
- New Posts:
- 342
- New Topics:
- 80
- Active Topics:
- 90
Our newest member
Other
-
FAQ
All times are UTC [ DST ]
Google Ads
Database Mirroring Error SQL 2005
2 posts • Page 1 of 1
Please wait...
Database Mirroring Error SQL 2005
You may encounter the following errors in you log file while mirroring databases in SQL 2005 SP2 or earlier
These errors are terminal to database mirroring. You will need to re-create database mirroring from a fresh backup.
The error message states you should run DBCC CHECKDB to check the database for errors. However, you can NOT run DBCC CHECKDB on a database that is currently in a restoring state. Which is the case with the partner db of a mirror.
The root cause of the error is the use of sp_getappLock and sp_releaseapplock in the principal db. The lock is not properlly released by sp_releaseapplock and the mirror db can not apply the mirror transaction. You may want to check you database objects for the use of those system procedures.
Microsoft recommends not using sp_getapplock and sp_releaseapplock if it can be helped. These system procedures will lock the code so it can only run concurrently.
Microsoft states that the error is fixed in CU8 and SP3.
http://support.microsoft.com/kb/953625/LN/
Message
Error: 17066, Severity: 16, State: 1.
SQL Server Assertion: File: <loglock.cpp>, line=818 Failed Assertion = 'result == LCK_OK'. This error may be timing-related. If the error persists after rerunning the statement, use DBCC CHECKDB to check the database for structural integrity, or restart the server to ensure in-memory data structures are not corrupted.
Error: 3624, Severity: 20, State: 1.
A system assertion check has failed. Check the SQL Server error log for details. Typically, an assertion failure is caused by a software bug or data corruption. To check for database corruption, consider running DBCC CHECKDB. If you agreed to send dumps to Microsoft during setup, a mini dump will be sent to Microsoft. An update might be available from Microsoft in the latest Service Pack or in a QFE from Technical Support.
These errors are terminal to database mirroring. You will need to re-create database mirroring from a fresh backup.
The error message states you should run DBCC CHECKDB to check the database for errors. However, you can NOT run DBCC CHECKDB on a database that is currently in a restoring state. Which is the case with the partner db of a mirror.
The root cause of the error is the use of sp_getappLock and sp_releaseapplock in the principal db. The lock is not properlly released by sp_releaseapplock and the mirror db can not apply the mirror transaction. You may want to check you database objects for the use of those system procedures.
Microsoft recommends not using sp_getapplock and sp_releaseapplock if it can be helped. These system procedures will lock the code so it can only run concurrently.
Microsoft states that the error is fixed in CU8 and SP3.
http://support.microsoft.com/kb/953625/LN/
50002736 953625 http://support.microsoft.com/kb/953625/LN/
FIX: Error message when SQL Server 2005 synchronizes a mirrored database: "Expression: result == LCK_OK"
--Paul
--If at first you don't succeed destroy all evidence that you tried.
--If at first you don't succeed destroy all evidence that you tried.
-

ptheriault - LTD Admin

-

- Posts: 545
- Joined: Thu Oct 11, 2007 6:28 pm
- Location: Warwick, RI
Re: Database Mirroring Error SQL 2005
People would use sp_getapplock to create a kind of singleton object in SQL Server...I have never seen it in code
Denis The SQL Menace
SQL Server Code,Tips and Tricks, Performance Tuning
SQL Blog
Personal and/or non database related blog
SQL Server Code,Tips and Tricks, Performance Tuning
SQL Blog
Personal and/or non database related blog
o
o
o @..@
(----)
( )--( )
o0..0o
-

SQLDenis - LTD Admin

-










- Posts: 11780
- Joined: Wed Oct 10, 2007 6:43 pm
- Location: Princeton, New Jersey, USA,World, Solar System, Milky Way, Universe and Beyond
2 posts • Page 1 of 1


LTD Social Sitings
Note: Watch for social icons on posts by your favorite authors to follow their postings on these and other social sites.