Applies ToSQL Server 2008 R2 Enterprise SQL Server 2008 R2 Standard SQL Server 2008 R2 Web SQL Server 2008 R2 Workgroup SQL Server 2008 Developer SQL Server 2008 Enterprise SQL Server 2008 Standard SQL Server 2008 Web SQL Server 2008 Workgroup Microsoft SQL Server 2005 Enterprise Edition Microsoft SQL Server 2005 Standard Edition Microsoft SQL Server 2005 Workgroup Edition Microsoft SQL Server 2005 Service Pack 3 Microsoft SQL Server 2005 Service Pack 4

Symptoms

Consider the following scenario:

  • You change a statement of a stored procedure that is used on a merge publication in Microsoft SQL Server 2005, in Microsoft SQL Server 2008, or in Microsoft SQL Server 2008 R2.

  • The stored procedure contains more than 4,000 characters.

  • You run the merge agent (Replmerg.exe) to enumerate the changes.

In this scenario, Replmerg.exe crashes. Additionally, an error message that resembles the following is logged in the Application log:

Log Name: ApplicationSource: Application ErrorDate: <Date>Event ID: 1000Task Category: (100)Level: ErrorKeywords: ClassicUser: N/AComputer: <Computer Name>Description:Faulting application name: replmerg.exe, version: 2007.100.4000.0, time stamp: 0x4c92ec51Faulting module name: ntdll.dll, version: 6.1.7600.16695, time stamp: 0x4cc7b325Exception code: 0xc0000374Fault offset: 0x00000000000c6ab2Faulting process id: 0x1454Faulting application start time: 0x01cbe4c4fc508bacFaulting application path: D:\Program Files\Microsoft SQL Server\100\COM\replmerg.exeFaulting module path: D:\Windows\SYSTEM32\ntdll.dllReport Id: 8811b864-50b8-11e0-90ff-000ffee506a7Log Name: ApplicationSource: Windows Error ReportingDate: <Date>Event ID: 1001Task Category: NoneLevel: InformationKeywords: ClassicUser: N/AComputer: <Computer Name>Description:Fault bucket , type 0Event Name: APPCRASHResponse: Not availableCab Id: 0Problem signature:P1: replmerg.exeP2: 2007.100.4000.0P3: 4c92ec51P4: StackHash_e266P5: 6.1.7600.16695P6: 4cc7b325P7: c0000374P8: 00000000000c6ab2P9: P10: Attached files:These files may be available here:D:\ProgramData\Microsoft\Windows\WER\ReportArchive\AppCrash_replmerg.exe_43c274c4abed59ae9c49f7a88c2cc6da29bd54_8fd3d3caAnalysis symbol: Rechecking for solution: 0Report Id: 8811b864-50b8-11e0-90ff-000ffee506a7Report Status: 0

Cause

This issue occurs because of heap corruption when Replmerg.exe enumerates the statement changes.

Resolution

Cumulative update information

SQL Server 2008 Service Pack 3

The fix for this issue was first released in Cumulative Update 1 for SQL Server 2008 Service Pack 3. For more information about this cumulative update package, click the following article number to view the article in the Microsoft Knowledge Base:

2617146 Cumulative update package 1 for SQL Server 2008 Service Pack 3Note Because the builds are cumulative, each new fix release contains all the hotfixes and all the security fixes that were included with the previous SQL Server 2008 fix release. Microsoft recommends that you consider applying the most recent fix release that contains this hotfix. For more information, click the following article number to view the article in the Microsoft Knowledge Base:

2629969 The SQL Server 2008 builds that were released after SQL Server 2008 Service Pack 3 was released Microsoft SQL Server 2008 hotfixes are created for specific SQL Server service packs. You must apply a SQL Server 2008 Service Pack 3 hotfix to an installation of SQL Server 2008 Service Pack 3. By default, any hotfix that is provided in a SQL Server service pack is included in the next SQL Server service pack.

SQL Server 2008 Service Pack 2

The fix for this issue was first released in Cumulative Update 5 for SQL Server 2008 Service Pack 2. For more information about this cumulative update package, click the following article number to view the article in the Microsoft Knowledge Base:

2555408 Cumulative update package 5 for SQL Server 2008 Service Pack 2Note Because the builds are cumulative, each new fix release contains all the hotfixes and all the security fixes that were included with the previous SQL Server 2008 fix release. Microsoft recommends that you consider applying the most recent fix release that contains this hotfix. For more information, click the following article number to view the article in the Microsoft Knowledge Base:

2402659 The SQL Server 2008 builds that were released after SQL Server 2008 Service Pack 2 was released Microsoft SQL Server 2008 hotfixes are created for specific SQL Server service packs. You must apply a SQL Server 2008 Service Pack 2 hotfix to an installation of SQL Server 2008 Service Pack 2. By default, any hotfix that is provided in a SQL Server service pack is included in the next SQL Server service pack.

SQL Server 2008 Service Pack 1

The fix for this issue was first released in Cumulative Update 15 for SQL Server 2008 Service Pack 1. For more information about this cumulative update package, click the following article number to view the article in the Microsoft Knowledge Base:

2555406 Cumulative update package 15 for SQL Server 2008 Service Pack 1Note Because the builds are cumulative, each new fix release contains all the hotfixes and all the security fixes that were included with the previous SQL Server 2008 fix release. Microsoft recommends that you consider applying the most recent fix release that contains this hotfix. For more information, click the following article number to view the article in the Microsoft Knowledge Base:

970365 The SQL Server 2008 builds that were released after SQL Server 2008 Service Pack 1 was released Microsoft SQL Server 2008 hotfixes are created for specific SQL Server service packs. You must apply a SQL Server 2008 Service Pack 1 hotfix to an installation of SQL Server 2008 Service Pack 1. By default, any hotfix that is provided in a SQL Server service pack is included in the next SQL Server service pack.

SQL Server 2008 R2 Service Pack 1

The fix for this issue was first released in Cumulative Update 1 for SQL Server 2008 R2 Service Pack 1. For more information about how to obtain this cumulative update package, click the following article number to view the article in the Microsoft Knowledge Base:

2544793 Cumulative Update package 1 for SQL Server 2008 R2 Service Pack 1Note Because the builds are cumulative, each new fix release contains all the hotfixes and all the security fixes that were included with the previous SQL Server 2008 R2 fix release. We recommend that you consider applying the most recent fix release that contains this hotfix. For more information, click the following article number to view the article in the Microsoft Knowledge Base:

2567616 The SQL Server 2008 R2 builds that were released after SQL Server 2008 R2 Service Pack 1 was released

SQL Server 2008 R2

The fix for this issue was first released in Cumulative Update 8. For more information about how to obtain this cumulative update package for SQL Server 2008 R2, click the following article number to view the article in the Microsoft Knowledge Base:

2534352 Cumulative Update package 8 for SQL Server 2008 R2 Note Because the builds are cumulative, each new fix release contains all the hotfixes and all the security fixes that were included with the previous SQL Server 2008 R2 fix release. We recommend that you consider applying the most recent fix release that contains this hotfix. For more information, click the following article number to view the article in the Microsoft Knowledge Base:

981356 The SQL Server 2008 R2 builds that were released after SQL Server 2008 R2 was released

SQL Server 2005

Hotfix information

A supported hotfix is now available from Microsoft. However, it is intended to correct only the problem that this article describes. Apply it only to systems that are experiencing this specific problem.To resolve this problem, contact Microsoft Customer Support Services to obtain the hotfix. For a complete list of Microsoft Customer Support Services telephone numbers and information about support costs, visit the following Microsoft website:

http://support.microsoft.com/contactus/?ws=supportNote In special cases, charges that are ordinarily incurred for support calls may be canceled if a Microsoft Support Professional determines that a specific update will resolve your problem. The usual support costs will apply to additional support questions and issues that do not qualify for the specific update in question.

Prerequisites

To apply this hotfix, you must have SQL Server 2005 Service Pack 4 (SP4) installed.

Restart requirement

You may have to restart the computer after you apply this hotfix.

Hotfix replacement information

This hotfix does not replace a previously released hotfix.

File information

The English version of this hotfix has the file attributes (or later file attributes) that are listed in the following table. The dates and times for these files are listed in Coordinated Universal Time (UTC). When you view the file information, it is converted to local time. To find the difference between UTC and local time, use the Time Zone tab in the Date and Time item in Control Panel.

For all supported x86-based versions of SQL Server 2005 Database Engine

File name

File version

File size

Date

Time

Platform

Replprov.dll

2005.90.5268.0

551,776

21-Apr-11

22:46

x86

For all supported x64-based versions of SQL Server 2005 Database Engine

File name

File version

File size

Date

Time

Platform

Replprov.dll

2005.90.5268.0

751,968

21-Apr-11

22:43

x64

For all supported IA-64–based versions of SQL Server 2005 Database Engine

File name

File version

File size

Date

Time

Platform

Replprov.dll

2005.90.5268.0

1,629,536

22-Apr-11

0:55

IA-64

Status

Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.

References

For more information about the replication merge agent, visit the following MSDN website:

General information about the replication merge agent

Need more help?

Want more options?

Explore subscription benefits, browse training courses, learn how to secure your device, and more.

Communities help you ask and answer questions, give feedback, and hear from experts with rich knowledge.