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


Replication causes SQL Server to run 100% CPU (Proc_mergereplicationcleanup) & merge clan up job


Replication causes SQL Server to run 100% CPU (Proc_mergereplicationcleanup) & merge clan up job

Author
Message
AHWB
AHWB
SSC-Enthusiastic
SSC-Enthusiastic (108 reputation)SSC-Enthusiastic (108 reputation)SSC-Enthusiastic (108 reputation)SSC-Enthusiastic (108 reputation)SSC-Enthusiastic (108 reputation)SSC-Enthusiastic (108 reputation)SSC-Enthusiastic (108 reputation)SSC-Enthusiastic (108 reputation)

Group: General Forum Members
Points: 108 Visits: 91
I have been investigating a problem where SQL 2005 Merge replication causes the subscriptions server CPU to run at 100%. The publication/distribution servers CPU is ok.

When stopping/disable the replication job the subscriptions CPU drops from 100% to a 1-5% hence replication is causing a problem.

I trid to reinitialise and validate the subscription choosing to create a new snapshot and then run the replication job but this made no difference.

when viewing replication monitor no replication was in progress, nor were there any errors.

I ran profiler and the ‘sp_MSenumgenerations90’ (runs Proc_mergereplicationcleanup) appear lots. After a google search which pointed me in the direction of the SQL ‘merge clan up job’ and also talked about ‘subscription expiration’ within the general properties of the publication.

Within the properties of my publication the subscription expiration was set to
• Subscription never expire.
rather than the default
• Subscriptions expire and mau be dropped if not synchronised in the follow interval, which is 14 days by default.

I changed my subscription to the default thinking this might be causing some sort of issue.

I then looked at the ‘merge clan up job ‘ and viewed the history which showed the job had been running ok once a month and usually takes under a minute to complete. The last successful run was the beginning of this month, 1st September.

The problem with 100% CPU was discovered at the weekend 11/12th September. I manually ran this job and it took 24 minutes to complete.
After it completed I started replication and the problem appears to have been resolved, CPU spiked a little as you would expect for an initial replication merge sync then settled.

My question is does running, NEVER EXPIRE causes this problem and should any other jobs be required and can it cause problems with the merge cleanup job and make it not run correctly?
Jamie-2229
Jamie-2229
Hall of Fame
Hall of Fame (3.1K reputation)Hall of Fame (3.1K reputation)Hall of Fame (3.1K reputation)Hall of Fame (3.1K reputation)Hall of Fame (3.1K reputation)Hall of Fame (3.1K reputation)Hall of Fame (3.1K reputation)Hall of Fame (3.1K reputation)

Group: General Forum Members
Points: 3142 Visits: 838
http://www.mssqltips.com/sqlservertip/1823/troubleshooting-slow-sql-server-replication-issue-due-to-distributor-database-growth/

Seems to be working but I am using 2008

Jamie
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