I restored the publishing database in a replication configuration. Now an getting the error below on th publisher to distribubor stage. the distributor to subscriber step is okay

Stephen Waigi 20 Reputation points
2023-12-28T07:21:50.42+00:00

Error messages:

The process could not execute 'sp_repldone/sp_replcounters' on 'OAFPRIMARY01'. (Source: MSSQL_REPL, Error number: MSSQL_REPL20011)

Get help: http://help/MSSQL_REPL20011

The specified LSN {000117ad:000d1937:0044} for repldone log scan is not a replicated commit record. (Source: MSSQLServer, Error number: 18769)

Get help: http://help/18769

The process could not set the last distributed transaction. (Source: MSSQL_REPL, Error number: MSSQL_REPL22017)

Get help: http://help/MSSQL_REPL22017

The process could not execute 'sp_repldone/sp_replcounters' on 'OAFPRIMARY01'. (Source: MSSQL_REPL, Error number: MSSQL_REPL22037)

Get help: http://help/MSSQL_REPL22037

Azure SQL Database
SQL Server | Other
{count} votes

1 answer

Sort by: Most helpful
  1. SSingh-MSFT 16,371 Reputation points Moderator
    2023-12-28T10:06:38.1633333+00:00

    Hi Stephen Waigi •,

    Welcome to Microsoft Q&A forum.

    As I understand, you are trying to restore a publishing database in a replication configuration. Now an getting the error when publisher to distributor stage. the distributor to subscriber step is okay.

    Please enable logging and let us know the details of the error if appears there:

    https://learn.microsoft.com/en-us/sql/relational-databases/replication/troubleshoot-tran-repl-errors?view=sql-server-ver16#enable-verbose-logging-on-any-agent

    Check if solutions mentioned here could help in your case:

    https://www.sqlservercentral.com/forums/topic/help-replication-issue-the-process-could-not-execute-sp_repldonesp_replcounters

    Please share more details about the steps you follow so that we can help better.

    Thanks

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.