Symptoms
Replication fails with one of the following errors on the Snapshot Agent or Merge Agent (see Monitoring replication earlier in this document):
Replication fails with one of the following errors on the Snapshot Agent or Merge Agent (see Monitoring replication earlier in this document):
By using SQL Server Enterprise Manager or SQL Server Management Studio, verify that the Replication Agent credentials are set properly. The following conditions must be met:
For information on how to view or modify the credentials that the Snapshot Agent and Merge Agents use to connect to the Publisher and Subscribers, see Modifying Replication Agent credentials earlier in this document.
When promoting SQL Server to Publisher, or adding it as a Subscriber to the existing Publisher, the operation fails with the following error: “An alias cannot be used for replication. Use the name of the SQL Server instance.”
This error may be due to one of the following reasons:
To isolate and resolve this problem, run the following two queries on the SQL Server instance affected by this issue. Copy these queries “as is,” without making any substitutions for the servername parameter:
select @@servername
select serverproperty('servername')
If select @@servername returns a non-null value that is different from the value returned by the second query, execute the following SQL script:
exec sp_dropserver 'oldname', 'droplogins'
exec sp_addserver 'newname', 'local'
In this script, replace:
If select @@servername returns NULL, execute the following SQL script:
exec sp_addserver 'newname', 'local'
In this script, replace newname with the value returned by select serverproperty('servername').
For these changes to take effect, you must restart SQL Server. You can restart SQL Server by using SQL Server Configuration Manager:
The Administration Service must be configured to identify SQL Server by computer name, rather than using a client alias. Otherwise, when attempting to make SQL Server the Publisher or a Subscriber, you encounter the error “An alias cannot be used for replication. Use the name of the SQL Server instance.”
To avoid this problem, you may need to reinstall the Administration Service. When installing the Administration Service, use the following syntax to identify SQL Server:
In this syntax:
© ALL RIGHTS RESERVED. Termini di utilizzo Privacy Cookie Preference Center