SQL Server 2008 R2 SP2 Breaks Merge Replication - by JCNC

Status : 

  Won't Fix<br /><br />
		Due to several factors the product team decided to focus its efforts on other items.<br /><br />
		A more detailed explanation for the resolution of this particular item may have been provided in the comments section.

Sign in
to vote
ID 773281 Comments
Status Closed Workarounds
Type Bug Repros 0
Opened 12/3/2012 5:51:16 AM
Access Restriction Public


After installing SQL SERVER 2008 R2 SP2 on the subscriber server, merge replication between subscriber and distributer errors out with message "Another merge agent for the subscription or subscriptions is running, or the server is working on a previous request by the same agent".  In running a profiler trace on the distributor, it seems that the process on the distributer executes sys.sp_getapplock to acquire the lock 7:[Publication_Name\](B39a8334) twice...the first time, the lock is acquired and never released, the 2nd time this occurs, a Lock:Timeout occurs, throwing the error "Another merge agent for the sbuscription..." error is thrown.

Because this made no sense, I uninstalled SP2 to see if it was due to SP2.  By uninstalling SQL SERVER 2008 R2 SP2, the subscriber is able to connect to the distributor without any issues.  I then installed SQL SERVER 2008 R2 SP1 to confirm that replication will still work, which it does.  I then installed SP2 on top of the SP1 instance and replication is broken again.  I rolled the instance back to SP1, and replication works again.

What is in the subscriber that is causing the distributor to try to acquire the lock for the subscription twice, which is causing the replication to fail?

We do not want to re-create the subscription to the distributor because that will mean re-initialization of all our customers down stream.
Sign in to post a comment.
Posted by Microsoft on 12/4/2012 at 10:12 AM
thanks for taking the time to share your feedback, this is really important to us.
We will investigate the issue and get back to you.

Best regards
Jean-Yves Devant 
Program Manager Servicing and Lifecycle Experience of High Availability Technologies in SQL Server
Program Manager SQL Server Replication, Change Data Capture, Change Tracking