SQL Server Q&A

As a software engineer, I focus on .NET, especially asp.net, C#, WCF and so on, and I am also very interested in Search Engine Optimization.

Entries Tagged ‘replication’

Error message when you use the Configure Web Synchronization Wizard to configure the virtual directory against a server that is running IIS 7.0: “IIS was not found on the Web Server. Please speci …

Symptoms
You run the Configure Web Synchronization Wizard for a merge replication. When you configure the virtual directory against a server that is running Internet Information Services (IIS) 7.0, you receive the following error message:

IIS was not found on the Web Server. Please specify a computer name that has IIS installed.Note IIS 7.0 is a component of Windows Vista and of Windows Server 2008.
Resolution
This problem occurs because the Configure Web Synchronization Wizard cannot recognize IIS 7.0.

BUG: Error 18456 when trying to configure publishing using a remote distributor

Symptoms
The following error message is returned when you attempt to configure publishing using a remote distributor if the password required for the publisher to establish an administrative link with the distributor isNULL:

SQL Server Enterprise Manager could not configure ‘<Distributor_name>’ as the Distributor for ‘<Publisher_name>’.
Error 18456: Login failed for user ‘distributor_admin’.
Resolution
Configure the publisher as a trusted publisher to the distributor so that a password is not required to establish the administrative link between the publisher and the distributor. To change the security settings for the publisher, follow these steps:On the Tools menu, select Replication.On the Publisher tab, highlight your publisher in the list, and then click the ellipsis (…) next to that publisher.In the Replication Agents on the Distribution Log into the Publisher section, select the By impersonating the SQL Server Agent account on ‘{ServerName}’ (trusted connection) check box.
-or-Do not use a login that has a NULL password for establishing the administrative link between the publisher and the distributor. The administrative link password can be set in Enterprise Manager. To do this, follow these steps: On the Tools menu, select Replication.On the Distributor tab, under the Administrative link password section, enter your password in the password and confirm password fields.
Note We recommend that you use a strong password in this step.

FIX: Merge System Tables not Dropped When Restoring Merge-Published DB Over Non-published DB Across Servers

Symptoms
When restoring the backup of a database, which is enabled for Transactional and Merge Replication (Sysdatabases.Category = 5), to a non-published database on a different server, the merge replication system tables are not dropped and the user tables on the destination server’s database cannot be dropped. If the backup is restored on the same server (different database), then the restore works fine and the replication information is removed.
Also, the restore works fine across servers when the source database is enabled either for Transactional or Merge Replication only (Sysdatabases.Category = 1 OR 4).
Resolution
To work around this problem, you can either:Enable the source database for Transactional or Merge Replication alone (Sysdatabases.Category = 1 OR 4).
-or-Drop the merge system tables using the DROP TABLE syntax.NOTE: Contact Microsoft Product Support Services if you need to drop the user tables and are unable to do so.

FIX: Merge Agent Fails with a “The remote procedure call failed and did not execute” Error

Symptoms
The merge agent fails with the following error message:

The remote procedure call failed and did not executeThe task reports the preceding remote procedure call (RPC) failure in its history, which can be misleading because there are not any other connectivity problems. The merge agent runs into a handled exception with the following stack, as seen in the replication exception log file:

The Exception Stack Dump follows:
ntdll77f67546RtlpWaitForCriticalSection
ntdll41d70871RtlEnterCriticalSection
replrec41d68839CReconcilerHistory::AddMessage
replrec41d666c8CDatabaseReconciler::LogProgressMessage
replrec41d66362CDatabaseReconciler::ProcTombstones
replrec41d65449CDatabaseReconciler::MoveChangesToDest
replrec00403819CDatabaseReconciler::Reconcile
replmerg004038e2CReconcilerTask::Reconcile
replmerg00407af8AgentRun
replmerg08ec83ecAgentMain

Resolution
The RPC failed message is the result of a exception with the merge agent. Replmerg.exe fails while inserting generation history, generating an exception when completely filling the allocated memory buffer. This causes an out of space situation and the required null termination character cannot be added, subsequently causing the access violation.

Description of two approaches for a disaster recovery plan for transactional replication

Symptoms
This article discusses two alternative approaches to a disaster recovery plan for transactional replication. This article contains more information about the following:Problems in the approach for the disaster recovery plan that is mentioned in SQL Server Books Online.Two alternative approaches to a disaster recovery plan.Step-by-step procedure to set up a disaster recovery plan for the two alternative approaches.Step-by-step procedure to recover the replication databases for the two alternative approaches.
Resolution
In SQL Server Books Online, the “Strategies for backing up and restoring transactional replication” topic discusses the disaster recovery plan for transactional replication. However, the approach that is mentioned in SQL Server Books Online may not satisfy the requirement of minimum latency. This article discusses two alternative approaches that can be used to set up a disaster recovery plan for databases that are involved in transactional replication. The approaches that are discussed in this article can be used to recover the replication databases from a failure situation, such as a hardware failure.